Repository navigation
Description
Goal
An operator who starts the tracker and then stops it should get startup and shutdown logs that use one consistent message style, field names, and levels, and that include the facts needed to see what is running and whether it stopped cleanly.
Background
The Copilot review of PR #2382 (issue #2370, EPIC #1488 SI-15) found that the new UDP drain logs named the listener local_addr. The rest of the codebase mostly uses service_binding. The drain logs were renamed, but the older UDP receive-loop logs still say local_addr, because #2370 must not change existing log messages. The maintainer asked for a follow-up covering the whole lifecycle: run the tracker, read what it logs at startup, shut it down, read what it logs then, make everything coherent, and look for missing operator information.
A baseline capture (release build, development configuration with every service enabled, stopped with SIGTERM) shows, among other things:
- the listener identified as
local_addr,service_binding,address, andbind_address; - message prefixes mixing styles, such as
UDP TRACKER:next totorrust_tracker_lib::bootstrap::jobs::manager:; - internal
Debugoutput in span fields, such ascancellation_token=CancellationToken { is_cancelled: false }on every job startup line; - the same start reported two or three times (
Starting on,Started on,Started ...); - 26
INFOlines for metric registration, formatted withDebug; - eight startup
WARNlines when usage statistics are disabled; - four wordings for shutdown messages.
Scope
- Capture startup and shutdown logs with every service enabled, at
infoanddebug. - Inventory every lifecycle log line.
- Propose a lifecycle logging convention for maintainer approval.
- Apply it one component at a time.
- Add approved missing operator information, such as an effective configuration summary, version, deadlines, per-component stop outcomes, and the final process outcome.
- Fix or reclassify misleading lifecycle warnings.
Out of scope:
- per-request logs and the general level policy (Review how we use tracing levels #1166);
- metrics and output formats;
- shutdown behavior (EPIC Overhaul: Tracker Shutdown #1488).
Postponed
Start after EPIC #1488 (tracker shutdown overhaul) is complete. Its remaining subissues still change shutdown behavior and logs, so this work should start from the final shutdown design and a fresh baseline capture.
Specification
The full specification and the verbatim baseline log are in docs/issues/open/ in the review-tracker-lifecycle-logs folder for this issue. They are added by PR #2382.
Activity
docs(issues): add issue specification for torrust#2387
Merge #2382: fix(udp-server): [#2370] own and drain UDP request proce…
Merge #2391: chore(issues): archive closed issue #2370 spec
docs(issues): [torrust#2387] number the sub-issues of the lifecycle l…
docs(issues): [torrust#2387] add cookie_lifetime to the configuration…
docs(issues): [torrust#2387] quote the shutdown message that the new …
docs(issues): [torrust#2387] name the maintainer approval before a su…
docs(issues): [torrust#2387] list every decision of the convention su…
docs(issues): [torrust#2387] say that two targets, not three, already…
44 remaining items
docs(issues): [#2387] record order B′ and recheck the EPIC specs agai…
Merge #3024: docs(issues): [#2387] record order B′ and recheck the EP…
docs(issues): [torrust#2758] start torrust#2766 after torrust#2387 SI…
docs(issues): [#2993] record the overlap with EPIC #2387
Merge #3025: docs(issues): [#2993] record the overlap with EPIC #2387
Merge #3027: docs(issues): [#2758] start #2766 after #2387 SI-1 inste…
Merge #3032: docs(issues): [#3031] add specification for the statisti…
Merge #3043: fix(statistics): [#3031] stop warning for each event of …
Merge #3042: fix(secrets): [#2999] keep secrets out of errors, logs a…
Merge #3048: chore(issues): archive closed issue #3031 spec to docs/i…
Merge #3062: docs(issues): [#3060] spec for the UDP core DEBUG lines …
Merge #3078: fix(udp-core): [#3060] set the UDP TRACKER log target of…
docs(issues): [#2766] refresh the daemon JSON logging spec and record…
Merge #3081: docs(issues): refresh the daemon JSON logging spec and r…