lucrib / locust_influx

Send information about locust requests to influxdb.
Apache License 2.0
19 stars 13 forks source link

Problems with locust 1.0.x #11

Open mglauche opened 4 years ago

mglauche commented 4 years ago

Hi,

with locust.io 1.0 somethings break, i managed to change the setup.py with: install_requires=[ 'locust>=1.0', 'influxdb>=5.2.2', ],

but loucst gives me: File "/home/ubuntu/locust/venv/lib/python3.6/site-packages/locust_influx-0.2.4-py3.6.egg/locust_influx/init.py", line 168, in expose_metrics TypeError: unsupported operand type(s) for +=: 'EventHook' and 'function'

Locust changed the event.py to "Eventook" from "EventHook()", which might explain the error, but why was that done?

stevenxuwoss commented 4 years ago

you should use add_listener or decorator as offical doc mentioned https://docs.locust.io/en/stable/extending-locust.html.

pjcalvo commented 3 years ago

@mglauche This changed a lot, I am working on a new pip package that you can use. For the mean time checkout my gist https://pypi.org/project/locust-influxdb-listener/