aboutsummaryrefslogtreecommitdiff
path: root/src/feature/stats
diff options
context:
space:
mode:
authorGeorge Kadianakis <desnacked@riseup.net>2020-11-03 19:19:02 +0200
committerGeorge Kadianakis <desnacked@riseup.net>2020-11-03 19:19:02 +0200
commit0812ecd517af406aa82e5a5deddbbe799e9d8b49 (patch)
tree96bf577afa9c9985ea7ee8128a6ef26a147aa74b /src/feature/stats
parent810183aaf17aa23eb68260038345cb540a856f75 (diff)
downloadtor-0812ecd517af406aa82e5a5deddbbe799e9d8b49.tar.gz
tor-0812ecd517af406aa82e5a5deddbbe799e9d8b49.zip
Add more docs about the HSv3 stat collection period.
Diffstat (limited to 'src/feature/stats')
-rw-r--r--src/feature/stats/rephist.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/feature/stats/rephist.c b/src/feature/stats/rephist.c
index e0d8669cba..1501e46b14 100644
--- a/src/feature/stats/rephist.c
+++ b/src/feature/stats/rephist.c
@@ -1868,8 +1868,11 @@ rep_hist_reset_hs_v3_stats(time_t now)
/** Return true if it's a good time to collect v3 stats.
*
* v3 stats have a strict stats collection period (from 12:00UTC to 12:00UTC
- * on the real network) and hence we don't want to collect statistics if it's
- * not yet the time to do so.
+ * on the real network). We don't want to collect statistics if (for example)
+ * we just booted and it's 03:00UTC; we will wait until 12:00UTC before we
+ * start collecting statistics to make sure that the final result represents
+ * the whole collection period. This behavior is controlled by
+ * rep_hist_hs_stats_init().
*/
MOCK_IMPL(STATIC bool,
should_collect_v3_stats,(void))