tag1consulting / goose

Load testing framework, inspired by Locust
https://tag1.com/goose
Apache License 2.0
807 stars 70 forks source link

Passing `--host=<HOST>` without `http://` prefix hangs the run in a confusing way #480

Closed dpc closed 2 years ago

dpc commented 2 years ago

I started testing my goose-based load testing tool, and immediately got confused

If I start it with --host=1.2.3.4:3000, it starts 3 users and hangs. No longer increases number of started users.

It was working locally, and lucky I've noticed that locally I was running with --host=http://127.0.0.1:1234. Adding http:// fixed my issue.

Kind of a nasty papercut, especially that I'm planning to make this tool available to other people, and I'm sure some of them will repeat this mistake.

jeremyandrews commented 2 years ago

I am unable to duplicate this. For example, if I specify just an IP address I correctly get an error:

Error: InvalidHost { host: "10.10.3.23", detail: "There was a failure parsing the host specified with --host.", parse_error: RelativeUrlWithoutBase }

I also tried adding a port, but again I get an error:

Error: InvalidHost { host: "10.10.3.23", detail: "There was a failure parsing the host specified with --host.", parse_error: RelativeUrlWithoutBase }

And using your made the precise IP/port you specified, again the same error:

Error: InvalidHost { host: "1.2.3.4:3000", detail: "There was a failure parsing the host specified with --host.", parse_error: RelativeUrlWithoutBase }
dpc commented 2 years ago

I don't get any error. Why would it be? I can see that couple of users are hatched, and then things hang. I am using goose 0.16.1.

dpc commented 2 years ago

Hmmm. I tried again and do get an error. I was working on the code whole today, but I'm 99.9% sure I was getting a hang yesterday, as I tried it multiple times to figure out what's going on.

dpc commented 2 years ago

I squashed some past commits, lost the logs, can't reproduce. :shrug: