mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
Merge pull request #3873 from yichengq/func-long-timeout
tools/etcd-tester: extend timeout for stresser
This commit is contained in:
@@ -75,7 +75,7 @@ func (s *stresser) Stress() error {
|
||||
for i := 0; i < s.N; i++ {
|
||||
go func() {
|
||||
for {
|
||||
setctx, setcancel := context.WithTimeout(ctx, time.Second)
|
||||
setctx, setcancel := context.WithTimeout(ctx, client.DefaultRequestTimeout)
|
||||
key := fmt.Sprintf("foo%d", rand.Intn(s.KeySuffixRange))
|
||||
_, err := kv.Set(setctx, key, randStr(s.KeySize), nil)
|
||||
setcancel()
|
||||
|
||||
Reference in New Issue
Block a user