[RAPTOR-18976] feat(workload): start a stopped workload - #765
Conversation
|
🎫 Jira: |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit e443264. Configure here.
e443264 to
e8dd2f9
Compare
e8dd2f9 to
3e03970
Compare
3e03970 to
9edd3b8
Compare
|
/approve-smoke-tests |
2367cfc to
3e21be6
Compare
|
/approve-smoke-tests |
ff5b246 to
c47fad2
Compare
🧑🏫 Coached Review — PR #765Verdict: Approve. Clean, well-tested addition that correctly routes a stopped workload through a single How this fits in the
|
🔒 Security Review — PR #765 (STRIDE)Result: No exploitable security findings. What was checked
Key observations
|
|
lgtm, approve. one net-new thing plus a couple of notes. the only start-path on bugbot's "misleading stopped-drift refusal" - think that's already handled? +1 to aj on the verifyCredentials move. one nuance on top of his reword: on a stopped-with-drift or build-mode workload with a bad cred, it now surfaces the credential error instead of |
`up` means make the file true, and a workload the file describes exactly but which is switched off is not true yet. It was refused with ErrNotWired; it is now one POST and a wait. The plan already understood this case, reporting the run as "started" and refusing to call a stopped workload up to date, so this is the apply catching up with what was printed. Stopped leaves the list of undeployable states, which is now only the states that are genuinely not a starting point: gone, terminated, errored, still settling. Stopped never belonged with them; it is one call away from running. The start branch is checked before the roll refusal so a workload the file agrees with gets deployed rather than turned away. When the file asks for more than a start, the refusal wins and nothing is started: bringing the workload up on the version it was stopped on and then reporting a failure leaves the user worse off than refusing did, with a running workload they did not ask for on code they did not deploy. Nothing is written back and nothing is compiled on this path, because nothing is being changed. The workload keeps the artifact it was stopped on, which is the version this run just confirmed the file still describes. --detach and --lock behave as they do on a create, since both are about what happens after the workload is asked to run, not about how it was asked.
Nine fixes from the review of the start path. Suspended is the one status reducing to StateStopped that cannot be started: the platform no-ops the request, so `up` posted it and then polled for a transition that was never coming, until the timeout. Live now carries the platform's own status so the apply can tell the three apart. Interrupted still starts. --detach reported the status the workload had just been asked to leave, so the envelope said stopped beside an action of started. The acknowledgement was discarded too, which is the only place the platform says it did nothing. --lock re-locked an artifact that was already locked, which on this path is one an earlier run locked rather than one this run minted. Credentials are verified before starting as well: a start is when the container resolves them, so one deleted while the workload was off failed minutes later as a container that would not come up. In the tests, the start seam was installed with swap rather than force, so a stopped fixture without a start fake called the real API. State.Deployable is gone. It answered the opposite of what the apply does and had no caller but the test pinning it. RAPTOR-18976
c47fad2 to
b51c50d
Compare
|
the lock-on-start test from yesterday still isn't in here. |
chasdr
left a comment
There was a problem hiding this comment.
reviewed at current head. detailed notes are in the comment above.

Sixth of the
dr workload upstack, on top of #764.What
upmeans make the file true, and a workload the file describes exactly but which is switched off is not true yet. It was refused withErrNotWired; it is now one POST and a wait.The plan already understood this case — it reports the run as
startedand refuses to call a stopped workload up to date — so this is the apply catching up with what was already being printed.Decisions worth a look
--detachand--lockbehave as they do on a create, since both are about what happens after the workload is asked to run, not about how it was asked.Test plan
task test— no new failurestask lint— clean on all three GOOS targetsMade with Cursor