Move video call and stream diagnostics to module categories

This commit is contained in:
evgeny committed 2026-10-18 15:06:16 +02:00
1 parent 28826e050c
commit 81de8747e2
3 files changed
+5 -5

No files matched your search

+2 -2
View File
@@ -239,7 +239,7 @@ static void flush(struct call_video_transport *v) {
f->offset += f->length;
if (f->offset == f->size) {
if (f->pts_us % 1000000 < 34000)
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG,
DEBUG_DEBUG(DEBUG_CATEGORY_CALL,
"video timing stage=send call=%llu frame=%llu pts=%lld boot_us=%llu bytes=%u queue_age_us=%llu budget_yields=%u",
(unsigned long long)f->call_id, (unsigned long long)f->frame_id, (long long)f->pts_us,
(unsigned long long)get_time_us(), f->size, (unsigned long long)((get_time_tb() - head->started_tb) * 100),
@@ -510,7 +510,7 @@ static void receive(struct ETCP_CONN *conn, struct ll_entry *entry) {
int result = call_video_receiver_push(v->receiver, &f, get_time_us(), &complete);
if (result == 1) {
if (complete.pts_us % 1000000 < 34000)
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "video timing stage=receive call=%llu frame=%llu pts=%lld boot_us=%llu bytes=%u",
DEBUG_DEBUG(DEBUG_CATEGORY_CALL, "video timing stage=receive call=%llu frame=%llu pts=%lld boot_us=%llu bytes=%u",
(unsigned long long)id, (unsigned long long)complete.frame_id, (long long)complete.pts_us,
(unsigned long long)get_time_us(), complete.size);
v->received_generation = complete.format.generation; v->ops.frame(v->arg, &complete);
+1 -1
View File
@@ -969,7 +969,7 @@ static void transport_changed(struct ETCP_CONN *conn, int status, void *arg) {
if (status != ETCP_CONN_STATUS_REINIT || net->stopping) return;
struct stream_peer *p = peer_find(net, conn->peer_node_id);
if (p) {
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "stream transport REINIT peer=%llx up=%d local_epoch=%llx peer_epoch=%llx control_queued=%d",
DEBUG_DEBUG(DEBUG_CATEGORY_STREAM, "stream transport REINIT peer=%llx up=%d local_epoch=%llx peer_epoch=%llx control_queued=%d",
(unsigned long long)p->node_id, p->up, (unsigned long long)p->own_epoch,
(unsigned long long)p->other_epoch, p->control->count);
peer_reset(p, STREAM_REASON_TRANSPORT, STREAM_RESET_ROTATE | STREAM_RESET_KEEP_PENDING, NULL);
+2 -2
View File
@@ -587,7 +587,7 @@ void stream_optimizer_tick(struct stream_optimizer *o, struct STREAM_HANDLE *h,
/* Пока нет первого блока, раз в секунду показываем причину ожидания каждого поставщика. */
if (!local.anchored && now >= o->diagnostic_ms) {
o->diagnostic_ms = now + STREAM_PROBE_PERIOD_MS;
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "stream bootstrap waits group=%llx source=%llx epoch=%llx candidates=%u probes=%u"
DEBUG_DEBUG(DEBUG_CATEGORY_STREAM, "stream bootstrap waits group=%llx source=%llx epoch=%llx candidates=%u probes=%u"
" subflows=%u cycle=%llu cycle_age_ms=%llu",
(unsigned long long)o->descriptor.group_id, (unsigned long long)o->descriptor.source_node_id,
(unsigned long long)o->descriptor.source_epoch, o->info.candidates, o->info.probes_active, o->info.subflows,
@@ -595,7 +595,7 @@ void stream_optimizer_tick(struct stream_optimizer *o, struct STREAM_HANDLE *h,
for (struct stream_supplier *s = o->suppliers; s; s = s->next) {
struct stream_receive_info probe = {0};
if (s->probe) stream_receive_get_info(s->probe, &probe);
DEBUG_DEBUG(DEBUG_CATEGORY_DEBUG, "stream bootstrap supplier source=%llx peer=%llx online=%d compatible=%d source_peer=%d"
DEBUG_TRACE(DEBUG_CATEGORY_STREAM, "stream bootstrap supplier source=%llx peer=%llx online=%d compatible=%d source_peer=%d"
" cycle=%llu failures=%u retry_in_ms=%llu probe=%d sub=%u state=%d info_ready=%d reason=%d",
(unsigned long long)o->descriptor.source_node_id, (unsigned long long)s->node, s->online, s->compatible, s->source,
(unsigned long long)s->cycle, s->failures, (unsigned long long)(s->retry_ms > now ? s->retry_ms - now : 0),