Commit 07ecdce
Record published-object stats for non-live publish modes
Publisher::stats() returned zeros for objects/groups/bytes whenever the
publish path went through the batch/file flow (publish, publish_file,
publish_stream) because record_published_object() was only invoked from
publish_live. Other paths funnel through serve_subscriptions /
forward_published_tracks, which are free functions and had no access to
the MoqtSession's stats.
Pass a PublishedObjectSink std::function through those helpers; the
MoqtSession callers bind it to record_published_object so every served
object — whether emitted from the live loop or the batch loop —
contributes to publish_stats_, and stats() reflects work-in-progress for
all four publish APIs.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 957d5cd commit 07ecdce
2 files changed
Lines changed: 29 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
217 | 217 | | |
218 | 218 | | |
219 | 219 | | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
220 | 229 | | |
221 | 230 | | |
222 | 231 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1347 | 1347 | | |
1348 | 1348 | | |
1349 | 1349 | | |
| 1350 | + | |
| 1351 | + | |
1350 | 1352 | | |
| 1353 | + | |
1351 | 1354 | | |
1352 | 1355 | | |
1353 | 1356 | | |
| |||
1872 | 1875 | | |
1873 | 1876 | | |
1874 | 1877 | | |
| 1878 | + | |
| 1879 | + | |
| 1880 | + | |
| 1881 | + | |
| 1882 | + | |
| 1883 | + | |
| 1884 | + | |
| 1885 | + | |
1875 | 1886 | | |
1876 | 1887 | | |
1877 | 1888 | | |
| |||
1964 | 1975 | | |
1965 | 1976 | | |
1966 | 1977 | | |
| 1978 | + | |
1967 | 1979 | | |
1968 | 1980 | | |
1969 | 1981 | | |
| |||
2139 | 2151 | | |
2140 | 2152 | | |
2141 | 2153 | | |
| 2154 | + | |
2142 | 2155 | | |
2143 | 2156 | | |
2144 | 2157 | | |
| |||
2498 | 2511 | | |
2499 | 2512 | | |
2500 | 2513 | | |
| 2514 | + | |
| 2515 | + | |
| 2516 | + | |
| 2517 | + | |
2501 | 2518 | | |
2502 | 2519 | | |
2503 | 2520 | | |
| 2521 | + | |
2504 | 2522 | | |
2505 | 2523 | | |
2506 | 2524 | | |
| |||
2540 | 2558 | | |
2541 | 2559 | | |
2542 | 2560 | | |
| 2561 | + | |
2543 | 2562 | | |
2544 | 2563 | | |
2545 | 2564 | | |
| |||
2564 | 2583 | | |
2565 | 2584 | | |
2566 | 2585 | | |
| 2586 | + | |
2567 | 2587 | | |
2568 | 2588 | | |
2569 | 2589 | | |
| |||
0 commit comments