masaruhoshi / uptimerobot-prometheus-exporter

A Golang Prometheus exporter for UptimeRobot monitors.
MIT License
33 stars 13 forks source link

paginated responses #37

Open krzee opened 1 year ago

krzee commented 1 year ago

My uptimerobot monitor has 243 servers, but i only ingest 50 of them. This seems to be due to pagination. Do I need to do something to support pagination? Is it a bug?

krzee commented 1 year ago

When I hit the API by hand i see: {"stat":"ok","pagination":{"offset":0,"limit":50,"total":243}, but when I look at logs from the exporter scraping I see: level=info msg="Response from UptimeRobot API%!(EXTRA *api.XMLMonitors=&{{{ pagination} 0 0 0}

masaruhoshi commented 1 year ago

Hi @krzee. Thanks for the feedback. I actually have refactored a few parts of the exporter that I plan to have merged soon. It includes expanding the pagination support. I'll mark this issue when I have the PR ready for review