Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: When remote database used in DB Link is down, JDBC hangs

Re: When remote database used in DB Link is down, JDBC hangs

From: Dmitry Bogdanov <dima_at_ksf.kiev.ua>
Date: 10 Feb 2006 07:29:08 -0800
Message-ID: <1139585348.904706.36080@g47g2000cwa.googlegroups.com>


Well, it appeared that this is nothing to do with Tomcat. The following sequence
of calls causes the same symptoms:

        Statement stmt2 = cn.createStatement();
        ResultSet rs2 = stmt2.executeQuery("select 'x' from
dual_at_mylink");
        rs2.next();
        System.out.println(rs2.getString(1));
        rs2.close();
        stmt2.close();

// !!! do shutdown immediate to DB referenced by mylink, now
        stmt2 = cn.createStatement();
        rs2 = stmt2.executeQuery("select 'x' from dual_at_mylink"); // !!!
hangs forever
        rs2.next();
        System.out.println(rs2.getString(1));
        rs2.close();
        stmt2.close();

If I would create a new connection for the second set of statements (before
second stmt2 = ...), it will not hang, and I will get correct error:

java.sql.SQLException: ORA-02068: following severe error from MYLINK ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist

Looks like something to do with Oracle JDBC driver? Received on Fri Feb 10 2006 - 09:29:08 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US