Skip to content

Commit 77c4c78

Browse files
committed
Increase default statvalidity from 1d to 7d
1 parent f3bd5f0 commit 77c4c78

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ func parseConfig() *Config {
3232
flag.BoolVar(&conf.SvrConf.ParallelDial, "paralleldial", true, "Try parallelly dial up IPs of a host.")
3333
flag.StringVar(&conf.SvrConf.Proxies, "proxies", "", "Upstream proxy urls: [Scheme://]Host:Port[,[Scheme://]Host:Port][...], omitting scheme adopts all supported schemes (http, socks5, socks4a).")
3434
flag.StringVar(&conf.SvrConf.ProxyProbeURL, "proxyprobeurl", "https://www.google.com", "Used to probe if a proxy works.")
35-
flag.DurationVar(&conf.StatValidity, "statvalidity", 24*time.Hour, "Validity of a stat.")
35+
flag.DurationVar(&conf.StatValidity, "statvalidity", 168*time.Hour, "Validity of a stat.")
3636
flag.StringVar(&conf.StatFile, "statfile", "stat.json", "File records direct connection quality (EWMA of the last 10).")
3737
flag.StringVar(&conf.Blocked, "blocked", "blocked", "File of blocked domains (suffix) or IPs (prefix), that go proxied directly. Do 1 direct try, if no proxy.")
3838
flag.StringVar(&conf.Direct, "direct", "direct", "File of direct domains (suffix) or IPs (prefix), that won't go proxied. Direct > Blocked.")

readme.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ wikipedia.org
6666

6767
## 统计 Vs 隐私
6868

69-
`pd` 存储主机最近 24h`-statvalidity` 的默认值) 的动态统计数据,包括 "host/IP:port"、最近 10 次连接的 EWMA、访问计数和时间。这是动态调度算法必需的。
69+
`pd` 存储主机最近 7 天`-statvalidity` 的默认值) 的动态统计数据,包括 "host/IP:port"、最近 10 次连接的 EWMA、访问计数和时间。这是动态调度算法必需的。
7070

7171
你可以用 `-statfile` 将结果保存为 `nul`。但是,这样就只能冷重启。
7272

@@ -144,7 +144,7 @@ Sites/Pathes restricted (blocked) by the servers self are not detectable.
144144

145145
## Statistics Vs Privacy
146146

147-
`pd` stores dynamic statistics of hosts for the last 24h (`-statvalidity` default), including "host/IP:port" pairs, EWMA of the last 10 connections, visit count, and the last visit time. It is required to implement the dynamic dispatching.
147+
`pd` stores dynamic statistics of hosts for the last 7d (`-statvalidity` default), including "host/IP:port" pairs, EWMA of the last 10 connections, visit count, and the last visit time. It is required to implement the dynamic dispatching.
148148

149149
You can use `-statfile` to save them to `nul`. But that will lead to a cold restart.
150150

0 commit comments

Comments
 (0)