Expand description
Worker runtime: boot the loader, watch the config, exit on signals.
Structs§
- Worker
Handle - Handle exposed as the
workerservice so plugins can stop or restart the process (upstream’sctx.loader.exit/ full-reload protocol).
Constants§
- EXIT_
BOOT - Exit code reporting that the loader never came up (bad config, unreadable file); the daemon exits non-zero instead of masking it.
- EXIT_
QUIT - Exit code telling the daemon to quit without restarting.
- EXIT_
RESTART - Exit code asking the daemon for a hot restart.
Functions§
- run
- Run the worker process: load dotenv, boot the loader (with dynamic
plugin directories, if any), watch the entry file and the plugin
directories, and block until a signal (or a
workerservice call) exits the process. Never returns.