Commit 6d7683d
Persist log records in KvStore for cross-process access
Replace the in-memory Map-based LogStore with a KvStore-backed
implementation so that logs produced by worker processes are visible
in the debug dashboard served by the web process.
LogStore.add() enqueues writes to a promise chain and exposes a
flush() method; route handlers call flush() before reading to
ensure all pending writes are visible. This avoids fromAsyncSink()
which was incompatible with configureSync().
The advanced overload now requires a kv option alongside the exporter.
The simplified overload shares the auto-created MemoryKvStore.
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 3147754 commit 6d7683d
3 files changed
Lines changed: 191 additions & 130 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
259 | 259 | | |
260 | 260 | | |
261 | 261 | | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
262 | 274 | | |
263 | 275 | | |
264 | 276 | | |
| |||
400 | 412 | | |
401 | 413 | | |
402 | 414 | | |
| 415 | + | |
403 | 416 | | |
404 | 417 | | |
405 | 418 | | |
| |||
431 | 444 | | |
432 | 445 | | |
433 | 446 | | |
434 | | - | |
| 447 | + | |
435 | 448 | | |
0 commit comments