SSLMate / certspotter

Certificate Transparency Log Monitor
https://sslmate.com/certspotter
Mozilla Public License 2.0
983 stars 84 forks source link

Monitoring statistics #79

Open AGWA opened 1 year ago

AGWA commented 1 year ago

It should be possible for users to see the current state of monitoring - e.g. which logs are being monitored, how recently they were contacted, what the backlog is

Maybe this could be provided by an optional HTTP server?

chayleaf commented 1 year ago

A /metrics endpoint for Prometheus would be the best option imo

AGWA commented 1 year ago

@chayleaf I don't have any experience with Prometheus. Could a metrics endpoint be implemented by outputting some JSON or some other simple format? How would Prometheus know how to interpret the data?

chayleaf commented 1 year ago

it looks like it got standardized as OpenMetrics. The spec is obviously quite wordy, a short overview is available here.

To make Prometheus scrape it, you just have to add the metrics endpoint to Prometheus config, and it will periodically dial it.

vt-alt commented 1 year ago

Prometheus metrics is good and modern way for a centralized monitoring, but just some stat into systemd journal would be as good when people don't run Prometheus.

ps. Just an example Prometheus metrics for our debuginfod instance: (how simple they look) https://debuginfod.altlinux.org/metrics https://debuginfod.elfutils.org/metrics

schildbach commented 1 year ago

Yes, I think some statistics printed to the log/stdout from time to time would already help a lot.

chayleaf commented 1 year ago

also gonna link this here