Skip to content
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

Add runtime metrics for buffer pools #4876

Closed
mikelaspina opened this issue Dec 10, 2021 · 2 comments · Fixed by #6177
Closed

Add runtime metrics for buffer pools #4876

mikelaspina opened this issue Dec 10, 2021 · 2 comments · Fixed by #6177
Labels
contribution welcome Request makes sense, maintainers probably won't have time, contribution would be welcome enhancement New feature or request

Comments

@mikelaspina
Copy link

I'd like to have runtime metrics for buffer pool utilization similar to the existing metrics for memory pools. Data can be gathered from BufferPoolMXBean Something like the following.

runtime.jvm.buffer.pool {type="used",pool="direct"}
runtime.jvm.buffer.pool {type="max",pool="direct"}
runtime.jvm.buffer.pool {type="used",pool="mapped"}
runtime.jvm.buffer.pool {type="max",pool="mapped"}
runtime.jvm.buffer.count {pool="direct"}
runtime.jvm.buffer.count {pool="mapped"}
@mikelaspina mikelaspina added the enhancement New feature or request label Dec 10, 2021
@trask trask added the contribution welcome Request makes sense, maintainers probably won't have time, contribution would be welcome label Jan 19, 2022
@cuichenli
Copy link
Contributor

Hey @mikelaspina , I would like to work on this and had a look on how to make it. But I am a little bit confused on what to be watched.

From the BufferPoolMXBean document, we can only get the pool name, count, and memory. While in your example, you still have the type attributes.

So I'm wondering how can we get this type value or it was a mistake? Thanks!

@mikelaspina
Copy link
Author

I mapped BufferPoolMXBean.getMemoryUsed() to type=used and BufferPoolMxBean.getTotalCapacity() to type=max. But, in the spirit of #5718, my request should be revised to use separate metrics. Something like process.runtime.jvm.buffer.usage and process.runtime.jvm.buffer.max?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contribution welcome Request makes sense, maintainers probably won't have time, contribution would be welcome enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants