File tree 1 file changed +16
-11
lines changed
performance/stan_stan_bench
1 file changed +16
-11
lines changed Original file line number Diff line number Diff line change @@ -331,18 +331,23 @@ func main() {
331
331
}
332
332
333
333
if ! direct {
334
- log .Printf ("Waiting for acks to return to replicator before we shut it down" )
335
- go func () {
336
- stop := time .Now ().Add (10 * time .Second )
337
- ticker := time .NewTicker (500 * time .Millisecond )
338
- for t := range ticker .C {
339
- if t .After (stop ) {
340
- repTimeout <- true
341
- break
334
+
335
+ if ! repOnly {
336
+ log .Printf ("Waiting for acks to return to replicator before we shut it down, timeout of %d seconds" , 10 )
337
+ go func () {
338
+ stop := time .Now ().Add (10 * time .Second )
339
+ ticker := time .NewTicker (500 * time .Millisecond )
340
+ for t := range ticker .C {
341
+ if t .After (stop ) {
342
+ repTimeout <- true
343
+ break
344
+ }
342
345
}
343
- }
344
- ticker .Stop ()
345
- }()
346
+ ticker .Stop ()
347
+ }()
348
+ } else {
349
+ log .Printf ("Waiting for acks to replicator without timeout" )
350
+ }
346
351
347
352
repwg .Wait ()
348
353
You can’t perform that action at this time.
0 commit comments