Skip to content

improve-usage-log

xqiu requested to merge itchyonion/snowflake:improve-usage-log into main

This is an attempt to address #40118 (closed). I opted for the first approach: wait some time before displaying the usage log. I added a new method WaitThenStart() to the task package because I thought this pattern is common enough. But I'm open to discussion if someone thinks it's just a one-off thing.

I tested my change by running the proxy binary locally and this is what I got:

% ./proxy -summary-interval 30m
2022/03/30 20:20:38 In the last 30m0s, there were 2 connections. Traffic Relayed ↑ 5 MB, ↓ 588 KB.

Merge request reports

Loading