-
Notifications
You must be signed in to change notification settings - Fork 817
SOLR-18159 Add metrics for system memory #4209
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
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
151beba
SOLR-18159 Add metrics for jvm_system_memory_free_bytes and jvm_syste…
janhoy 50599e0
SOLR-18159 Fix ECJ lint, review feedback on physical memory metrics
janhoy 5a25f12
Shorten changelog after feedback
janhoy a74cbb3
SOLR-18159 Merge system memory gauges into one with state=total|free …
janhoy 96cb83e
Review feedback - move constant
janhoy de26780
Add Matthew to changelog
janhoy File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| title: Add new metric jvm_system_memory_bytes | ||
| type: added | ||
| authors: | ||
| - name: Jan Høydahl | ||
| url: https://home.apache.org/phonebook.html?uid=janhoy | ||
| - name: Matthew Biscocho | ||
| links: | ||
| - name: SOLR-18159 | ||
| url: https://issues.apache.org/jira/browse/SOLR-18159 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I didn't know the prometheus writer would actually transform these delimited by dots in to underscores. But since we are _ for everything else, then make these underscores.
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.
Yea, it's different styles. The otel standard is dot separated, so I think we should stick with dots in the metric registry, and only switch to underscores when we cross a prometheus boundary (such as our metrics endpoint, and on the prometheus-write side of OTEL-collector.
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.
Aw man wish I had done dot separated back then. I should have been more careful. Oh well. Maybe in Solr 11 I will just move the delimiters to dot separated to actually get to that otel standard.
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.
As our only external interface in 10.0.0 is the
/solr/admin/metricsendpoint, it would not be a breaking change to switch to dot separated in 10.1. Who would notice? I hope we can get OTLP export working in 10.1 once that is out of the bag, there would be no way back...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.
Oh, well, I managed to enable OTLP export of metrics, I thought it was not possible. So guess changing from underscore to dot in 10.1 would be a break, unless we classify it as a bug or a BETA feature..

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.
I'm +1 to break OTLP back-compat in 10.1 if we think this is the right direction.
Uh oh!
There was an error while loading. Please reload this page.
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.
I'd rather comply with OTEL standards than with prometheus conventions since I see a clear trend in pushing metrics to other systems than prometheus.
Note: I tried in another system to push dot separated metric names directly into prometheus, and while it worked, it is not pleasant to work with in prometheus/grafana, as you often need to escape things all the time, e.g. write
{"foo.bar.baz"}rather than justfoo_bar_baz. So it will be a model where internal representation and OTLP wire-format uses dot syntax, and when you cross the boundary to prometheus, it gets converted to underscore syntax.