use of org.olat.core.commons.services.jmx.JMXManager in project OpenOLAT by OpenOLAT.
the class DatabaseStatsManager method getConnectionInfos.
public DatabaseConnectionVO getConnectionInfos() {
DatabaseConnectionVO vo = new DatabaseConnectionVO();
vo.setActiveConnectionCount(0);
vo.setCurrentConnectionCount(0);
try {
JMXManager jmxManager = CoreSpringFactory.getImpl(JMXManager.class);
MBeanServer mBeanServer = jmxManager.getMBeanServer();
boolean found = searchHikariDataSources(mBeanServer, vo) || searchTomcatDataSources(mBeanServer, vo) || searchC3P0DataSources(mBeanServer, vo);
if (log.isDebug()) {
log.debug("MBean for datasource found: " + found);
}
} catch (Exception e) {
log.error("", e);
}
return vo;
}
use of org.olat.core.commons.services.jmx.JMXManager in project openolat by klemens.
the class DatabaseStatsManager method getConnectionInfos.
public DatabaseConnectionVO getConnectionInfos() {
DatabaseConnectionVO vo = new DatabaseConnectionVO();
vo.setActiveConnectionCount(0);
vo.setCurrentConnectionCount(0);
try {
JMXManager jmxManager = CoreSpringFactory.getImpl(JMXManager.class);
MBeanServer mBeanServer = jmxManager.getMBeanServer();
boolean found = searchHikariDataSources(mBeanServer, vo) || searchTomcatDataSources(mBeanServer, vo) || searchC3P0DataSources(mBeanServer, vo);
if (log.isDebug()) {
log.debug("MBean for datasource found: " + found);
}
} catch (Exception e) {
log.error("", e);
}
return vo;
}
Aggregations