Implement Graceful Shutdown #33

Closed
opened 2026-04-26 15:22:35 -04:00 by dohertj2 · 2 comments
Owner

Source: $file
Milestone: $currentMilestone

Labels: area:worker, type:feature, priority:p0

Deliverables:

  • handle WorkerShutdown,
  • reject new commands,
  • let current command finish within timeout,
  • best-effort UnAdvise, RemoveItem, Unregister,
  • detach event handlers,
  • release COM object,
  • exit process.

Acceptance criteria:

  • cleanup order follows design,
  • cleanup failures are logged but do not hang shutdown,
  • gateway can kill after timeout,
  • worker exits with success on graceful shutdown.

Tests:

  • fake cleanup order,
  • cleanup failure,
  • command in progress,
  • shutdown timeout.
Source: $file Milestone: $currentMilestone Labels: `area:worker`, `type:feature`, `priority:p0` Deliverables: - handle `WorkerShutdown`, - reject new commands, - let current command finish within timeout, - best-effort `UnAdvise`, `RemoveItem`, `Unregister`, - detach event handlers, - release COM object, - exit process. Acceptance criteria: - cleanup order follows design, - cleanup failures are logged but do not hang shutdown, - gateway can kill after timeout, - worker exits with success on graceful shutdown. Tests: - fake cleanup order, - cleanup failure, - command in progress, - shutdown timeout.
dohertj2 added this to the mxaccess-worker-parity-slice milestone 2026-04-26 15:22:35 -04:00
dohertj2 added the area:workertype:featurepriority:p0 labels 2026-04-26 15:22:35 -04:00
dohertj2 added a new dependency 2026-04-26 15:28:39 -04:00
dohertj2 added a new dependency 2026-04-26 15:28:39 -04:00
dohertj2 added a new dependency 2026-04-26 15:28:39 -04:00
dohertj2 added a new dependency 2026-04-26 15:28:39 -04:00
dohertj2 added a new dependency 2026-04-26 15:28:39 -04:00
dohertj2 added a new dependency 2026-04-26 15:28:40 -04:00
Author
Owner

Worker 2 is taking this issue. Branch: agent-2/issue-33-implement-graceful-shutdown. Worktree: C:\Users\dohertj2\Desktop\mxaccessgw-agent-2.

Worker 2 is taking this issue. Branch: agent-2/issue-33-implement-graceful-shutdown. Worktree: C:\Users\dohertj2\Desktop\mxaccessgw-agent-2.
Author
Owner

Verified and merged by orchestrator in PR #88.

Implementation commit: d890efff068118295b0a158f921ef5d998abf811
Merge/update commit on branch: f7929cc0f8c19a40cd56a997f929937714d0cdfa
Merge commit: ec4e2f687e
Branch: agent-2/issue-33-implement-graceful-shutdown

Independent verification:

  • dotnet build src\MxGateway.sln
  • dotnet test src\MxGateway.Worker.Tests\MxGateway.Worker.Tests.csproj -p:Platform=x86 --no-build --filter "FullyQualifiedNameWorkerPipeSessionTests|FullyQualifiedNameWorkerPipeClientTests|FullyQualifiedNameStaCommandDispatcherTests|FullyQualifiedNameMxAccessCommandExecutorTests"
  • dotnet test src\MxGateway.sln --no-build

Result: all tests passed (29 targeted x86 worker tests; full suite 1 integration, 179 gateway, 114 worker).

Verified and merged by orchestrator in PR #88. Implementation commit: d890efff068118295b0a158f921ef5d998abf811 Merge/update commit on branch: f7929cc0f8c19a40cd56a997f929937714d0cdfa Merge commit: ec4e2f687e6f9a0fb94a155d3f3d411b9d7bb09b Branch: agent-2/issue-33-implement-graceful-shutdown Independent verification: - dotnet build src\MxGateway.sln - dotnet test src\MxGateway.Worker.Tests\MxGateway.Worker.Tests.csproj -p:Platform=x86 --no-build --filter "FullyQualifiedName~WorkerPipeSessionTests|FullyQualifiedName~WorkerPipeClientTests|FullyQualifiedName~StaCommandDispatcherTests|FullyQualifiedName~MxAccessCommandExecutorTests" - dotnet test src\MxGateway.sln --no-build Result: all tests passed (29 targeted x86 worker tests; full suite 1 integration, 179 gateway, 114 worker).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Reference: dohertj2/mxaccessgw#33