-
Notifications
You must be signed in to change notification settings - Fork 15
Add Prometheus labels for Cardano build info display #646
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
Label l -> trace ("renderSamples " <> T.unpack l) $ | ||
if "{" `T.isPrefixOf` l | ||
then renderLabel sk l | ||
else renderNamedValue sk (byteString $ encodeUtf8 l) | ||
_ -> mempty |
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.
Please remove debug code.
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.
Okay, sorry
Label l -> if isFloat l | ||
then renderNamedValue sk (byteString $ encodeUtf8 l) | ||
else mempty | ||
Label l -> trace ("renderSamples " <> T.unpack l) $ |
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.
What happened to the mempty
result when isFloat
is False
? We should leave that behaviour unchanged.
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.
Okay I revert it (so the secret treasures will never be seen :)
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.
Looks good to me
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.
LGTM thanks @jutaro
This pull request enhances the Cardano build info display by adding support for Prometheus labels. By incorporating Prometheus labels into the build info metrics, we improve monitoring and observability capabilities for Cardano nodes.
This is a restricted solution, which allows metrics with labels only with a value of 1.