File tree Expand file tree Collapse file tree 3 files changed +9
-6
lines changed Expand file tree Collapse file tree 3 files changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,8 @@ name = "debug-client"
7
7
retry = 10
8
8
# the key used in SHA256-HMAC authentication
9
9
key = " keyusedforhmac"
10
+ # retry interval
11
+ retry-interval = 10
10
12
11
13
# Set corresponding item to false if you don't want to enable some test
12
14
[api ]
Original file line number Diff line number Diff line change 1
1
package main
2
2
3
3
type ConfigConn struct {
4
- Remote string `toml:"remote"`
5
- Name string `toml:"name"`
6
- Key string `toml:"key"`
7
- Retry uint32 `toml:"retry"`
4
+ Remote string `toml:"remote"`
5
+ Name string `toml:"name"`
6
+ Key string `toml:"key"`
7
+ Retry uint32 `toml:"retry"`
8
+ Interval uint64 `toml:"retry-interval"`
8
9
}
9
10
10
11
type ConfigAPI struct {
@@ -24,6 +25,7 @@ func (r *Config) SetDefault() {
24
25
r .Conn .Remote = "ws://127.0.0.1:8080"
25
26
r .Conn .Name = "debug-client"
26
27
r .Conn .Retry = 10
28
+ r .Conn .Interval = 10
27
29
28
30
r .API .Resolve = true
29
31
r .API .Ping = true
Original file line number Diff line number Diff line change @@ -327,7 +327,6 @@ func main() {
327
327
}
328
328
icmp .GetICMPManager ().Flush ()
329
329
330
- time .Sleep (time .Second )
330
+ time .Sleep (time .Duration ( config . Conn . Interval ) * time . Second )
331
331
}
332
-
333
332
}
You can’t perform that action at this time.
0 commit comments