From 688578a44d3e54ad14ef040d49d2be6d3a8d7a45 Mon Sep 17 00:00:00 2001 From: Julius Bünger Date: Thu, 30 Aug 2018 16:09:12 +0200 Subject: Keep track of pending liveliness checks with statistics --- src/rps/gnunet-service-rps.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/rps') diff --git a/src/rps/gnunet-service-rps.c b/src/rps/gnunet-service-rps.c index 98e57a38e..a830bfa29 100644 --- a/src/rps/gnunet-service-rps.c +++ b/src/rps/gnunet-service-rps.c @@ -835,6 +835,10 @@ check_peer_live (struct PeerContext *peer_ctx) mq_liveliness_check_successful, peer_ctx); GNUNET_MQ_send (mq, ev); + GNUNET_STATISTICS_update (stats, + "# pending liveliness checks", + 1, + GNUNET_NO); } @@ -2973,6 +2977,10 @@ handle_peer_check (void *cls, LOG (GNUNET_ERROR_TYPE_DEBUG, "Received CHECK_LIVE (%s)\n", GNUNET_i2s (peer)); + GNUNET_STATISTICS_update (stats, + "# pending liveliness checks", + -1, + GNUNET_NO); GNUNET_CADET_receive_done (channel_ctx->channel); } -- cgit v1.2.3