docs(buglog): bug-1905 fixed in 8ac637ad; log bug-1908 (kill lost before worker registers job)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
8ac637ad36
commit
7d6a6e6043
3 changed files with 103 additions and 15 deletions
|
|
@ -1,8 +1,8 @@
|
|||
---
|
||||
id: "bug-1905"
|
||||
status: "open"
|
||||
status_updated: "2026-10-01"
|
||||
status_note: "newly logged"
|
||||
status: "fixed"
|
||||
status_updated: "2026-10-02"
|
||||
status_note: ""
|
||||
component: "worker"
|
||||
severity: "wrong-result"
|
||||
timestamp: "2026-10-01T14:32:18Z"
|
||||
|
|
@ -11,6 +11,7 @@ occurrences: 1
|
|||
files: ["src/worker/src/controller_connector.c", "src/worker/src/xcecd_dbus_manager.c"]
|
||||
tags: ["virtual-cluster", "job-control", "kill"]
|
||||
related: []
|
||||
fix_commits: ["8ac637ad"]
|
||||
---
|
||||
|
||||
# bug-1905: xcecd_virtual ignores kill of a running job: job keeps RUN until its sleep time elapses
|
||||
|
|
@ -45,15 +46,15 @@ ctrl-1: on_job_finish job finish jobid 1-0-1790864259-0 exit code 0
|
|||
- Evidence: /home/claude/tmp/bug-1905/kill-trace.log
|
||||
|
||||
## Root cause
|
||||
TODO: required for fixed/partial
|
||||
`dbus_workers_update()` (`src/worker/src/xcecd_dbus_manager.c`) decided a virtual job's end inside the branches of `get_systemd_job_exit_code()`: the `== 0` branch checked the sleep timer and then `killed_signal`, but the `< 0` branch checked only the timer. A virtual job has no systemd unit, and without a system bus (this container: `Failed to connect to system bus`) the call returns -1, so the kill recorded by the job-control handler (`controller_connector.c`, `worker->killed_signal`) was never acted on; the job stayed RUN and ended DONE with exit 0 when its sleep time elapsed. (Even on the `== 0` path the timer was checked before the kill.)
|
||||
|
||||
## Fix
|
||||
TODO: required for fixed/partial
|
||||
In `VIRTUAL_CLUSTER` builds the loop decides a running job's end before asking systemd: `killed_signal != 0` ends it as `WORKER_EXITED` with exit code 128 + signal; otherwise it is `WORKER_DONE` once its sleep time is up. The two partial virtual copies inside the exit-code branches were removed; real-worker behaviour is unchanged.
|
||||
|
||||
## Verification
|
||||
- Test: TODO: name + file; RED before the fix, GREEN after
|
||||
- Suites: TODO: suite results and build profile
|
||||
- Live: TODO: soak/deploy run, or n/a and why
|
||||
- Test: `test_killed_running_job_exits_without_systemd` (and the guard `test_unkilled_running_job_keeps_running`) in `src/worker/testsuite/test_dbus_workers_update.c`; RED before the fix (no status update, `Expected 1 Was 0`), GREEN after
|
||||
- Suites: worker meson suite 14/14 OK (asan, src/build.jai)
|
||||
- Live: xce-deploy-ha + xcecli, kill sent after the worker logged the jobs running: `plain2` and `arr2[2]` went RUN -> EXIT within 6 s, `arr2[1]`/`arr2[3]` stayed RUN (/home/claude/tmp/bug-1905/fixed-run.log). A kill sent within ~a few seconds of dispatch, before the worker has registered the job, is still lost ("Failed to find worker") -- a separate defect shared with the real worker, see References (bug-1908)
|
||||
|
||||
## References
|
||||
- Related: none
|
||||
- Related: bug-1908 (kill lost when sent before the worker registers the job)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue