Java Code Examples for org.apache.tomcat.jdbc.pool.ConnectionPool#getName()
The following examples show how to use
org.apache.tomcat.jdbc.pool.ConnectionPool#getName() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: DefaultConnectionState.java From dal with Apache License 2.0 | 6 votes |
@Override public void reset(ConnectionPool parent, PooledConnection con) { if (parent == null || con == null) return; try { boolean firstTime = isFirstTime.get(); if (!firstTime) return; isFirstTime.set(false); String connectionName = con.toString(); String url = con.getPoolProperties().getUrl(); String poolName = parent.getName(); String info = String.format("%s of url %s has been created for the first time,connection pool name:%s.", connectionName, url, poolName); logger.info(info); } catch (Throwable e) { } }
Example 2
Source File: SlowQueryReportJmx.java From Tomcat8-Source-Read with MIT License | 5 votes |
@Override public void reset(ConnectionPool parent, PooledConnection con) { super.reset(parent, con); if (parent!=null) { poolName = parent.getName(); pool = parent; registerJmx(); } }
Example 3
Source File: SlowQueryReportJmx.java From Tomcat7.0.67 with Apache License 2.0 | 5 votes |
@Override public void reset(ConnectionPool parent, PooledConnection con) { super.reset(parent, con); if (parent!=null) { poolName = parent.getName(); pool = parent; registerJmx(); } }
Example 4
Source File: DefaultConnectionState.java From dal with Apache License 2.0 | 5 votes |
@Override public void disconnected(ConnectionPool parent, PooledConnection con, boolean finalizing) { if (parent == null || con == null) return; try { String connectionName = con.toString(); String url = con.getPoolProperties().getUrl(); String poolName = parent.getName(); String info = String.format("%s of url %s has been destroyed,connection pool name:%s.", connectionName, url, poolName); logger.info(info); } catch (Throwable e) { } }
Example 5
Source File: SlowQueryReportJmx.java From tomcatsrc with Apache License 2.0 | 5 votes |
@Override public void reset(ConnectionPool parent, PooledConnection con) { super.reset(parent, con); if (parent!=null) { poolName = parent.getName(); pool = parent; registerJmx(); } }
Example 6
Source File: SlowQueryReportJmx.java From Tomcat8-Source-Read with MIT License | 4 votes |
@Override public void poolClosed(ConnectionPool pool) { this.poolName = pool.getName(); deregisterJmx(); super.poolClosed(pool); }
Example 7
Source File: SlowQueryReportJmx.java From Tomcat8-Source-Read with MIT License | 4 votes |
@Override public void poolStarted(ConnectionPool pool) { this.pool = pool; super.poolStarted(pool); this.poolName = pool.getName(); }
Example 8
Source File: SlowQueryReportJmx.java From Tomcat7.0.67 with Apache License 2.0 | 4 votes |
@Override public void poolClosed(ConnectionPool pool) { this.poolName = pool.getName(); deregisterJmx(); super.poolClosed(pool); }
Example 9
Source File: SlowQueryReportJmx.java From Tomcat7.0.67 with Apache License 2.0 | 4 votes |
@Override public void poolStarted(ConnectionPool pool) { this.pool = pool; super.poolStarted(pool); this.poolName = pool.getName(); }
Example 10
Source File: SlowQueryReportJmx.java From tomcatsrc with Apache License 2.0 | 4 votes |
@Override public void poolClosed(ConnectionPool pool) { this.poolName = pool.getName(); deregisterJmx(); super.poolClosed(pool); }
Example 11
Source File: SlowQueryReportJmx.java From tomcatsrc with Apache License 2.0 | 4 votes |
@Override public void poolStarted(ConnectionPool pool) { this.pool = pool; super.poolStarted(pool); this.poolName = pool.getName(); }