Get ratelimiting metrics to influxDB

I plan to get ratelimiting metrics to influxDB and show in Grafana, and would also like to set alert when the live count reaching 80% of the limit.

I tried statsd plugin, but it does not collect this kind of data.

Could someone provide a detailed suggestion on how this can be achived? Thanks.

You can write a custom plugin which runs after the rate-limit plugin.
You will need to inspect the rate-limit headers that are injected in the response sent to the client, and push those using statsd to influxdb.

Please have a look a the source of existing statsd plugin on how to achieve this.

Thanks for the reply.
Yes, I was doing something last week, exactly the same as what you said :slight_smile:


© 2018 Kong Inc.    Terms  •  Privacy  •  FAQ