pjcalvo / locust-influxdb-listener

LocustIO base project with a custom influxDB listener.
MIT License
26 stars 20 forks source link

#2 add response status code as tag on request failure events #3

Closed tyge68 closed 3 years ago

tyge68 commented 3 years ago

Adding code so that when a request failure is received it will check if the exception is an HTTPError (which should be the case most of the time).

then it add in that case a tag 'code' with the response status code information.

pjcalvo commented 3 years ago

Are u using the dashboard provided in the example? If so, can u please update it so that new users can also make use if this new field.?

https://github.com/hoodoo-digital/locust-influxdb-listener/blob/main/example/locust-grafana-dashboard.json

tyge68 commented 3 years ago

@pjcalvo I am not using it actually as it is, but it's pretty simple to use as the idea is to tag with the error code, so one can do anything with it. In my case I used a gauge to display the 500 and 503 error ratio against total number of requests. But one can also like to simply have a bar charts or any other charts with it.

pjcalvo commented 3 years ago

I will manually release the new version in the next days. Thanks for ccontributing.