Commit 0fef53b 1 parent f955bce commit 0fef53b Copy full SHA for 0fef53b
File tree 2 files changed +8
-5
lines changed
2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -9,10 +9,12 @@ $ brew install timeout-checker
9
9
server side:
10
10
```
11
11
$ checker-api -wait 5 -port 8081
12
- 2021/11/19 16:37:06 recieved
13
- 2021/11/19 16:37:11 returned
14
- 2021/11/19 16:37:14 recieved
15
- 2021/11/19 16:37:19 returned
12
+ 2021/11/22 15:21:30 wait 3 second
13
+ 2021/11/22 15:21:30 received
14
+ 2021/11/22 15:21:33 returned
15
+ 2021/11/22 15:21:42 wait 3 second
16
+ 2021/11/22 15:21:42 received
17
+ 2021/11/22 15:21:45 returned
16
18
```
17
19
18
20
client side:
Original file line number Diff line number Diff line change @@ -15,7 +15,8 @@ type Wait struct {
15
15
}
16
16
17
17
func (wait * Wait ) healthcheck (w http.ResponseWriter , r * http.Request ) {
18
- log .Println ("recieved" )
18
+ log .Printf ("wait %d second" , wait .time )
19
+ log .Println ("received" )
19
20
time .Sleep (time .Duration (wait .time ) * time .Second )
20
21
21
22
w .WriteHeader (http .StatusOK )
You can’t perform that action at this time.
0 commit comments