From bc0974c434084201a2bc97f4fe903cc7320733ed Mon Sep 17 00:00:00 2001 From: Matthias Wachs Date: Tue, 23 Oct 2012 15:11:42 +0000 Subject: timeout stats --- src/transport/plugin_transport_udp.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/transport/plugin_transport_udp.c') diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c index 0b858a51f..41eab290b 100644 --- a/src/transport/plugin_transport_udp.c +++ b/src/transport/plugin_transport_udp.c @@ -2197,6 +2197,12 @@ remove_timeout_messages_and_select (struct UDP_MessageWrapper *head, GNUNET_STATISTICS_update (plugin->env->stats, "# UDP, total, messages, sent, timeout", 1, GNUNET_NO); + GNUNET_STATISTICS_update (plugin->env->stats, + "# UDP, unfragmented msgs, messages, sent, timeout", + 1, GNUNET_NO); + GNUNET_STATISTICS_update (plugin->env->stats, + "# UDP, unfragmented msgs, bytes, sent, timeout", + udpw->payload_size, GNUNET_NO); /* Not fragmented message */ LOG (GNUNET_ERROR_TYPE_DEBUG, "Message for peer `%s' with size %u timed out\n", @@ -2219,6 +2225,13 @@ remove_timeout_messages_and_select (struct UDP_MessageWrapper *head, "Fragment for message for peer `%s' with size %u timed out\n", GNUNET_i2s(&udpw->session->target), udpw->frag_ctx->payload_size); + + GNUNET_STATISTICS_update (plugin->env->stats, + "# UDP, fragmented msgs, messages, sent, timeout", + 1, GNUNET_NO); + GNUNET_STATISTICS_update (plugin->env->stats, + "# UDP, fragmented msgs, bytes, sent, timeout", + udpw->frag_ctx->payload_size, GNUNET_NO); /* Remove fragmented message due to timeout */ fragmented_message_done (udpw->frag_ctx, GNUNET_SYSERR); break; -- cgit v1.2.3