myzhan / boomer

A better load generator for locust, written in golang.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Boomer panics if the spawn rate is smaller than number of boomers connected to master

fizyk opened this issue · comments

Describe the bug
If the number of workers is bigger than the user spawn rate on the master node, then some workers will panic and exit

To Reproduce
Steps to reproduce the behavior:

  1. Start locust master
  2. build a boomer worker out of example
  3. connect 4 boomer workers to master
  4. start test on master, select 50 users and between 1 to 3 users spawn rate

Expected behavior
Workers won't panic

Screenshots
worker_2 | panic: close of nil channel
worker_2 |
worker_2 | goroutine 23 [running]:
worker_2 | github.com/myzhan/boomer.(*runner).stop(0xc0000b2340)
worker_2 | /go/pkg/mod/github.com/myzhan/boomer@v1.6.1-0.20211029022911-e3671f206d48/runner.go:218 +0x51
worker_2 | github.com/myzhan/boomer.(*slaveRunner).onMessage(0xc0000b2340, {0x6ef1c0, 0xc000182870})
worker_2 | /go/pkg/mod/github.com/myzhan/boomer@v1.6.1-0.20211029022911-e3671f206d48/runner.go:394 +0x58a
worker_2 | github.com/myzhan/boomer.(*slaveRunner).startListener.func1()
worker_2 | /go/pkg/mod/github.com/myzhan/boomer@v1.6.1-0.20211029022911-e3671f206d48/runner.go:426 +0x37
worker_2 | created by github.com/myzhan/boomer.(*slaveRunner).startListener
worker_2 | /go/pkg/mod/github.com/myzhan/boomer@v1.6.1-0.20211029022911-e3671f206d48/runner.go:422 +0x5b

Environment (please complete the following information):

  • OS: Ubuntu though workers are running on docker scratch, built on alpine.
  • Go Version: 1.17

Additional context
I've set up a cluster using docker-compose based on the locust samples, and embed workers inside a scratch based dockerimage, then starting them using docker-compose

Yes, it's a known issue and has been fixed after #139 is merged. Please update boomer.