Re: Question on why sun.management MBeans are not exported?

2023-09-07 Thread mandy . chung
What we're referring to is to remove sun.management.Hotspot*, the internal MBeans which are never exposed and registered in the platform MBeanServer.   The internal metrics in HotSpot VM should be retained as they are exposed through other ways like jstat, GC logs, etc. Mandy On 9/6/23 11:27

Re: Question on why sun.management MBeans are not exported?

2023-09-06 Thread Kirk Pepperdine
Hi, It would be a shame to lose these metrics because many of them have been very useful over time and some would be even more useful with some modifications. For example, the CPU breakouts found in GC logs has been incredibly useful as a proxy measure in helping sort out other issues in system

Re: Question on why sun.management MBeans are not exported?

2023-09-06 Thread Alan Bateman
On 06/09/2023 16:17, Volker Simonis wrote: : I'm familiar with JEP 260. But wouldn't you agree that an "encapsulated" monitoring API is an oxymoron? A monitoring API is by design intended for external usage and completely useless to the platform itself. There's no single usage of the "sun.managem

Re: Question on why sun.management MBeans are not exported?

2023-09-06 Thread mandy . chung
On 9/6/23 8:17 AM, Volker Simonis wrote: Anyway, if you classify the MBeans in "sun.management" as non-critical internal APIs (with respect to JEP 260) but without any "internal" usage, than we should really remove them, right, because an internal API without any internal usage doesn't make any

Re: Question on why sun.management MBeans are not exported?

2023-09-06 Thread Volker Simonis
On Wed, Sep 6, 2023 at 3:47 PM Alan Bateman wrote: > > On 06/09/2023 14:02, Volker Simonis wrote: > > : > > > > I wonder why "sun.management" was encapsulated in the first place? I > > understand that it is not an "officially supported" API, but I find it > > still quite useful. > sun.management.*

Re: Question on why sun.management MBeans are not exported?

2023-09-06 Thread Alan Bateman
On 06/09/2023 14:02, Volker Simonis wrote: : I wonder why "sun.management" was encapsulated in the first place? I understand that it is not an "officially supported" API, but I find it still quite useful. sun.management.* is JDK internal so not something for code outside the JDK to use directly

Question on why sun.management MBeans are not exported?

2023-09-06 Thread Volker Simonis
Hi, I recently looked for an easy way to get the CPU time spent by JIT-compiler and GC threads in Java (e.g exported by IBM J9's JvmCpuMonitorMXBean [0]). An easy way to achieve this is in OpenJDK is by using the "sun.management.HotspotInternal" MBean which exports the "sun.management:type=Hotspot