1 Reply Latest reply on Jan 19, 2010 4:23 AM by Jay SenSharma MiddlewareMagic

    java.sql.SQLException: Connection has been administratively disabled. Try

    747357
      Hi All,

      I am getting the below exception

      Connection has been administratively destroyed. Reconnect.: Connection has been administratively destroy

      ed. Reconnect.

      java.sql.SQLException: Connection has been administratively destroyed. Reconnect.

      at weblogic.jdbc.common.internal.ConnectionEnv.checkIfEnabled(ConnectionEnv.java:779)

      at weblogic.jdbc.wrapper.PoolConnection.checkConnection(PoolConnection.java:57)

      at weblogic.jdbc.wrapper.Statement.checkStatement(Statement.java:256)

      at weblogic.jdbc.wrapper.Statement.preInvocationHandler(Statement.java:104)

      at weblogic.jdbc.wrapper.CallableStatement_oracle_jdbc_driver_T4CCallableStatement.getInt(Unknown Source)

      Please advice
        • 1. Re: java.sql.SQLException: Connection has been administratively disabled. Try
          Jay SenSharma MiddlewareMagic
          Hi,

          Your application should be doing something like this:

          myTopJDBCMethod() {

          Connection conn = null;
          try {
          conn = myDS.getConnection(); // test-on-reserve ensures it's working at this instant
          ...do all the JDBC work...

          if the DBMS goes down while you are in this block
          the connection you have will be dead. WebLogic
          will not replace it automatically. You must close it and
          start whatever you wanted to do, all over again,
          ideally just calling this method again when/if appropriate

          } catch (Exception ouch) {
          }
          finally {
          if (conn != null) try {conn.close();} catch (Exception ignore) {}
          }
          }

          Yes, absolutely, any call to getConnection() after the DBMS is
          back up should get a new good connection. Please open an official
          support case and we will be eager to fix anything that behaves differently.
          Show your pool config.

          --------------------------
          Pointers From *"Joe Weistein"*
          Please refer to: http://forums.oracle.com/forums/thread.jspa?threadID=975757&tstart=0


          Thanks
          Jay SenSharma
          http://jaysensharma.wordpress.com (WebLogic Wonders Are Here)

          Edited by: Jay SenSharma on Jan 19, 2010 9:52 AM