gobench icon indicating copy to clipboard operation
gobench copied to clipboard

Doesn't stop after -t seconds on windows

Open AkosLukacs opened this issue 8 years ago • 6 comments

I get a not supported by windows message in the console after the desired timeout. CTRL-c stops it just fine, and the results are also displayed nicely.

The console output:

C:\dev\go\bin> ./gobench -u http://localhost/ -c 1500 -t 15
Dispatching 1500 clients
Waiting for results...
2016/05/26 15:47:42 not supported by windows

go version go1.6.2 windows/amd64

AkosLukacs avatar May 26 '16 13:05 AkosLukacs

The error message itself could also be clarified. From the message I have no clue what is not supported by windows. Please add that information, e.g. "-t option is not properly supported" or something like that.

ForNeVeR avatar Jan 05 '17 13:01 ForNeVeR

The same situation for go 32 windows/32 1.8.1

gobench>gobench.exe -c 1 -t 10 -u http://localhost:8105/about/ Dispatching 1 clients Waiting for results... 2017/04/19 22:12:38 not supported by windows

After break program by ^C, printed out next result:

Requests: 31 hits Successful requests: 0 hits Network failed: 0 hits Bad requests failed (!2xx): 31 hits Successful requests rate: 0 hits/sec Read throughput: 605 bytes/sec Write throughput: 196 bytes/sec Test time: 15 sec

mikowiec avatar Apr 19 '17 19:04 mikowiec

I had the same issue when I first downloaded and built. However, I think if you try and run via go run first the issue resolves itself;

go run gobench.go -u http://localhost/ -c 50 -r 10

See if that finishes after 10 seconds and if it does rebuild.

I personally don't think this is a bug with gobench.

stevebaldwin21 avatar Sep 18 '17 08:09 stevebaldwin21

Sending os.Interrupt via os.Process.Signal works on most platforms, but it does not work on Windows. See golang/go#6720

jarek-przygodzki avatar Jan 09 '18 13:01 jarek-przygodzki

shameless plug: https://github.com/istio/fortio also had issues on windows at first but should now work fine after eliminating trying to send signal to self

ldemailly avatar Jan 17 '18 06:01 ldemailly

for future comers, check #27

BoYanZh avatar Apr 19 '21 13:04 BoYanZh