public void setup(final ApplicationContext appContext, final IClusterModel clusterModel, final String persistenceUnit) { this.appContext = appContext; this.clusterModel = clusterModel; this.persistenceUnit = persistenceUnit; this.beanProvider = new HibernateStatsMBeanProvider(clusterModel, persistenceUnit); this.beanProvider.addNotificationListener(this); try { statsBeanObjectName = HibernateStatsUtils.getHibernateStatsBeanName(persistenceUnit); statsBeanPattern = new ObjectName(statsBeanObjectName.getCanonicalName() + ",*"); } catch (Exception e) { throw new RuntimeException(e); } setLayout(new BorderLayout()); add(createRegionTablePanel()); revalidate(); repaint(); clusterModel.addPropertyChangeListener(clusterListener = new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }
public void setup(final ApplicationContext appContext, final IClusterModel clusterModel, final String persistenceUnit) { this.appContext = appContext; this.clusterModel = clusterModel; this.persistenceUnit = persistenceUnit; this.beanProvider = new HibernateStatsMBeanProvider(clusterModel, persistenceUnit); this.beanProvider.addNotificationListener(this); try { statsBeanObjectName = HibernateStatsUtils.getHibernateStatsBeanName(persistenceUnit); } catch (Exception e) { throw new RuntimeException(e); } setLayout(new BorderLayout()); add(createRegionTablePanel()); revalidate(); repaint(); clusterModel.addPropertyChangeListener(clusterListener = new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }
public void setup(final ApplicationContext appContext, final IClusterModel clusterModel, final String persistenceUnit) { this.appContext = appContext; this.clusterModel = clusterModel; this.persistenceUnit = persistenceUnit; this.beanProvider = new HibernateStatsMBeanProvider(clusterModel, persistenceUnit); this.beanProvider.addNotificationListener(this); try { statsBeanObjectName = HibernateStatsUtils.getHibernateStatsBeanName(persistenceUnit); statsBeanPattern = new ObjectName(statsBeanObjectName.getCanonicalName() + ",*"); } catch (Exception e) { throw new RuntimeException(e); } setLayout(new BorderLayout()); add(createRegionTablePanel()); revalidate(); repaint(); clusterModel.addPropertyChangeListener(clusterListener = new ClusterListener(clusterModel)); if (clusterModel.isReady()) { init(); } }
@Override public void tearDown() { if (!tornDown.compareAndSet(false, true)) { return; } beanProvider.removeNotificationListener(this); clusterModel.removePropertyChangeListener(clusterListener); clusterListener.tearDown(); synchronized (this) { appContext = null; clusterModel = null; clusterListener = null; regionTable = null; regionTableModel.clear(); regionTableModel = null; refreshRegionsButton = null; beanProvider = null; } super.tearDown(); } }
@Override public void tearDown() { if (!tornDown.compareAndSet(false, true)) { return; } beanProvider.removeNotificationListener(this); clusterModel.removePropertyChangeListener(clusterListener); clusterListener.tearDown(); synchronized (this) { appContext = null; clusterModel = null; clusterListener = null; regionTable = null; regionTableModel.clear(); regionTableModel = null; refreshRegionsButton = null; beanProvider = null; } super.tearDown(); } }
@Override public void tearDown() { if (!tornDown.compareAndSet(false, true)) { return; } beanProvider.removeNotificationListener(this); clusterModel.removePropertyChangeListener(clusterListener); clusterListener.tearDown(); synchronized (this) { appContext = null; clusterModel = null; clusterListener = null; regionTable = null; regionTableModel.clear(); regionTableModel = null; refreshRegionsButton = null; beanProvider = null; } super.tearDown(); } }