Commit 4e40fbd
feat(observability): wire file logging + run_id correlation + startup banner
Phase G of v0.1.0 hardening (parallel-code-review items 6, 16):
- feat(analytics): attach `RollingFileAppender` (daily rotation,
JSON, INFO+) to the `Registry` alongside console and OTLP layers.
Previously the file layer existed in
`observability::logging::init_minimal_logging` but that function
was never invoked from main.rs, so `~/.jarvy/logs/jarvy.log` was
always empty and `jarvy ticket create` shipped a hollow log file
to support. One subscriber now owns all sinks (review #1).
- feat(analytics): drop hard-coded `LevelFilter::ERROR` on the OTLP
bridge; default to `info`, override via `JARVY_OTLP_LEVEL`.
`tool.installed`, `setup.inventory`, `hook.completed` events
actually export now (review #2).
- feat(setup_cmd): generate per-invocation `run_id` (uuid v7) and
hold an `info_span!("setup", run_id)` for the entire `run_setup`
call. Every event in the file log / OTLP backend now carries
`run_id` so support can stitch parallel install threads back
together (review #6).
- feat(setup_cmd): emit `setup.start` event with version, os, arch,
config_source (local/remote), config_path, ci_provider, jobs,
dry_run — the first five questions support asks. Was buried in
scattered `eprintln!`s before (review #11).
- feat(setup_cmd): rayon worker threads re-enter the parent setup
span via `parent_span.enter()` inside `pool.install`. Without
this, every event from a parallel-install worker was
span-orphaned in traces (review #7). Each tool gets its own
`install_tool` span keyed by name+version.
Outstanding from item 6 (deferred):
- Extending `tool_failed`/`hook_failed` signature with
pm/exit_code/stderr_redacted/os fields (touches every caller).
- Promoting these from warn to error.
Outstanding from item 16 (deferred):
- Reconciling `duration_ms` event field vs `with_unit("s")`
histogram to one canonical unit (touches ~5 telemetry events
and any consuming dashboards).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent b34c681 commit 4e40fbd
2 files changed
Lines changed: 111 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
12 | 13 | | |
13 | 14 | | |
| 15 | + | |
14 | 16 | | |
15 | 17 | | |
16 | 18 | | |
| |||
57 | 59 | | |
58 | 60 | | |
59 | 61 | | |
60 | | - | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
61 | 99 | | |
62 | 100 | | |
63 | 101 | | |
64 | 102 | | |
65 | 103 | | |
66 | 104 | | |
67 | 105 | | |
68 | | - | |
| 106 | + | |
69 | 107 | | |
70 | 108 | | |
71 | 109 | | |
| |||
85 | 123 | | |
86 | 124 | | |
87 | 125 | | |
| 126 | + | |
88 | 127 | | |
89 | 128 | | |
90 | 129 | | |
| |||
108 | 147 | | |
109 | 148 | | |
110 | 149 | | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
111 | 178 | | |
112 | 179 | | |
113 | 180 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
92 | 120 | | |
93 | 121 | | |
94 | 122 | | |
| |||
318 | 346 | | |
319 | 347 | | |
320 | 348 | | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
321 | 356 | | |
322 | 357 | | |
323 | 358 | | |
324 | 359 | | |
325 | 360 | | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
326 | 368 | | |
327 | 369 | | |
328 | 370 | | |
| |||
0 commit comments