-
Notifications
You must be signed in to change notification settings - Fork 50
collectors: add close metrics #65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
2c879c5
to
09d7176
Compare
@carlaKC are you open to accepting this PR? |
Yes, looks like a nice change to have! Self assigned review, will get to it this week. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Happy with the addition of this metric, but I'd like to pair it with adding some panels to the provisioned grafana dash since I'd imagine most people will use the full docker-compose setup. Just pending channels by state and closed channels by close type will do I think.
09d7176
to
2dd486f
Compare
Panels added |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just noticed that we already have lnd_channels_pending_total
on the existing Channel Count
panel, so we don't actually need a new one, just to add status
label to it.
Otherwise happy with this!
2dd486f
to
c38d6f2
Compare
Hmm yes, I missed that. Merged dashboards. |
c38d6f2
to
68e4e01
Compare
Thanks for the PR, latest iteration looks good! |
This PR adds metrics so that a prometheus alert can be set up when a force-close happens. This is an event that unfortunately still seems to occur occasionally.
Example of an alert that becomes active if at least one channel was force-closed in the past 24 hours:
round(sum(delta(lnd_closed_channels_total{close_type="local_force"}[1d]) or delta(lnd_closed_channels_total{close_type="remote_force"}[1d]) or delta(lnd_channels_pending_total{state="pending_force_close"}[1d]))) > 0