The code snippet allows to monitor weblogic properties from a standalone code by fetching the MBean servers used by Weblogic. It allows you to monitor key elements such as Threads, JDBC Connections used, EJB, Java Heap etc. The code shows some of these MBean servers.
// JDBConnections JDBCConnectionPoolRuntimeMBean mbeanJDBCConnectionPoolRuntime; mbeanSet = home.getMBeansByType("JDBCConnectionPoolRuntime"); mbeanIterator = mbeanSet.iterator(); while (mbeanIterator.hasNext()) { mbeanJDBCConnectionPoolRuntime = (JDBCConnectionPoolRuntimeMBean) mbeanIterator .next(); String poolName = mbeanJDBCConnectionPoolRuntime.getName(); ShowInfoJDBCRuntime(mbeanJDBCConnectionPoolRuntime); }