10.5 Node Shutdown Behavior

Go To Top

Return to Node Implementation Pattern

A Node should support controlled shutdown. Shutdown should allow the Node to stop work, release resources, publish final status where possible, and exit with a meaningful result.

A representative shutdown sequence is:

  1. Receive a stop command, process signal, operator request, or script request.
  2. Publish Stopping status.
  3. Stop accepting new work where applicable.
  4. Complete, cancel, or safely abandon in-progress work according to the Node profile.
  5. Flush or close logs.
  6. Release DDS publishers, subscribers, and participants.
  7. Release other runtime resources.
  8. Publish Stopped status where the runtime context still permits it.
  9. Exit with a meaningful exit code.

Shutdown should distinguish controlled stop from failure. A Node that receives an expected stop command should not report Failed unless an error prevents controlled shutdown. A Node that crashes, loses a required dependency, cannot release resources safely, or exits unexpectedly should report or be recorded as Failed where possible.

The team should design shutdown behavior so that run scripts, stop scripts, containers, tests, and acceptance procedures can distinguish normal stop from abnormal termination.


© 2026 Dido Solutions, Inc. and Jackrabbit Consulting, Inc.