How to get jmap histogram programmatically?

∥☆過路亽.° 提交于 2019-11-29 12:14:19

问题


I would like to get the equivalent of the ouput of jmap -histo programmatically, from inside the monitored application. I see triggering a binary heap dump is possible through the HotSpot diagnostic bean, but I can't see how to get the histogram data. Is it possible ?


回答1:


It may be not the best example/code, but have a look at this

(I think it's only working on Hotspot JVMs)



来源:https://stackoverflow.com/questions/9417038/how-to-get-jmap-histogram-programmatically

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!