/** INTERNAL: Clears both implicit and explicit caches of OracleConnection */ public void clearOracleConnectionCache(Connection conn) { if (conn instanceof OracleConnection) { OracleConnection oracleConnection = (OracleConnection) conn; try { if (oracleConnection.getImplicitCachingEnabled()) { oracleConnection.purgeImplicitCache(); } } catch (SQLException ex) { // ignore } try { if (oracleConnection.getExplicitCachingEnabled()) { oracleConnection.purgeExplicitCache(); } } catch (SQLException ex) { // ignore } } }
public static void purgeImplicitCache(Connection conn) throws SQLException { OracleConnection oracleConn = unwrap(conn); oracleConn.purgeImplicitCache(); }