public HibernateStatsMBeanProvider(final IClusterModel clusterModel, final String persistenceUnit) { this.clusterModel = clusterModel; this.currBean = nullBean; this.unregisterNotificationListener = new UnRegistrationNotificationListener(); try { templateName = new ObjectName(HibernateStatsUtils.STATS_BEAN_NAME_PREFIX + ",instance=" + persistenceUnit + ",*"); } catch (Exception e) { throw new RuntimeException(e); } clusterModel.addPropertyChangeListener(new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }
public HibernateStatsMBeanProvider(final IClusterModel clusterModel, final String persistenceUnit) { this.clusterModel = clusterModel; this.currBean = nullBean; this.unregisterNotificationListener = new UnRegistrationNotificationListener(); try { templateName = new ObjectName(HibernateStatsUtils.getHibernateStatsBeanName(persistenceUnit).getCanonicalName() + ",*"); } catch (Exception e) { throw new RuntimeException(e); } clusterModel.addPropertyChangeListener(new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }
public HibernateStatsMBeanProvider(final IClusterModel clusterModel, final String persistenceUnit) { this.clusterModel = clusterModel; this.currBean = nullBean; this.unregisterNotificationListener = new UnRegistrationNotificationListener(); try { templateName = new ObjectName(HibernateStatsUtils.getHibernateStatsBeanName(persistenceUnit).getCanonicalName() + ",*"); } catch (Exception e) { throw new RuntimeException(e); } clusterModel.addPropertyChangeListener(new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }