[hibernate-dev] Exposing Hibernate statistics via JMX

Steve Ebersole steve at hibernate.org
Tue Aug 12 09:15:29 EDT 2014


There is a general purpose approach for exposing things via JMX starting in
4.2.  The difficulty I always get myself into is trying to plan through the
classloading issues with JMX.  I think its easy enough in
the java.lang.management.ManagementFactory#getPlatformMBeanServer case.
 The concern is more embedded MBeanServer cases.  This came from
discussions with the JBoss JMX folks, as this is honestly outside my field
of expertise.

So long story short, we currently do not expose any MBeans ourselves.  I
simply provide the mechanism.  See org.hibernate.jmx.spi.JmxService


On Mon, Aug 4, 2014 at 3:30 AM, Gunnar Morling <gunnar at hibernate.org> wrote:

> Anyone with an idea of what's the recommended way of exposing Hibernate
> statistics via JMX as of 4.3?
>
> Thanks,
>
> --Gunnar
>
>
> 2014-07-31 14:02 GMT+02:00 Gunnar Morling <gunnar at hibernate.org>:
>
> > Steve, all,
> >
> > I've been asked about the Hibernate statistics functionality which used
> to
> > be accessible via JMX.
> >
> > There used to be StatisticsService which was an MBean and which one could
> > register with the JMX platform. This has been removed a while ago, and
> > there is the related issue HHH-6190 which still is open.
> >
> > Until this is resolved, what is the recommended strategy towards making
> > the statistics available via JMX? Should users create and export their
> own
> > MBean based on SessionFactory#getStatistics()? Or is there any other
> > replacement for StatisticsService?
> >
> > Thanks,
> >
> > --Gunnar
> >
> > [1] https://hibernate.atlassian.net/browse/HHH-6190
> >
> >
> _______________________________________________
> hibernate-dev mailing list
> hibernate-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/hibernate-dev
>


More information about the hibernate-dev mailing list