From user-return-5637-apmail-geronimo-user-archive=geronimo.apache.org@geronimo.apache.org Tue Jan 16 21:56:58 2007 Return-Path: Delivered-To: apmail-geronimo-user-archive@www.apache.org Received: (qmail 41093 invoked from network); 16 Jan 2007 21:56:58 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 16 Jan 2007 21:56:58 -0000 Received: (qmail 54814 invoked by uid 500); 16 Jan 2007 21:57:03 -0000 Delivered-To: apmail-geronimo-user-archive@geronimo.apache.org Received: (qmail 54389 invoked by uid 500); 16 Jan 2007 21:57:02 -0000 Mailing-List: contact user-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: user@geronimo.apache.org List-Id: Delivered-To: mailing list user@geronimo.apache.org Received: (qmail 54378 invoked by uid 99); 16 Jan 2007 21:57:01 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Jan 2007 13:57:01 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of pavel.maximov@returnpath.net designates 66.238.230.81 as permitted sender) Received: from [66.238.230.81] (HELO webmail.returnpath.net) (66.238.230.81) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Jan 2007 13:56:52 -0800 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: quoted-printable Subject: Oracle JDBC connections timeout Date: Tue, 16 Jan 2007 16:56:31 -0500 Message-ID: <87956B476603A74FAEEC3CB6B4FE1E9724B03D@rpnyex01.rpcorp.local> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Oracle JDBC connections timeout Thread-Index: AccqsnKWlO2E0ejuQWiDyig++0WQ5wPBTfVg References: <4592ADB0.3070708@gmx.com> <206AB7E4-BCA9-48B2-BBF1-5D47CA92B150@gmail.com> From: "Pavel Maximov" To: X-Virus-Checked: Checked by ClamAV on apache.org Hello everybody, I'm not sure if the issue is related to the oracle driver or specific to geronimo, but here is what's happening. I have an oracle connection pool with the configuration below: So the oracle driver version I'm using is 10.2.0.2. I defined an error-page element in web.xml to redirect to a static error page when HTTP error code is 500. 500 /apperror.html The desired behavior for the application would be, in case database goes down, to generate an exception with HTTP error code 500, which will be caught by error page handler and the user will be redirected to a static error page. And it's working if you restart the app server when the connection is already down (I'm testing installing an iptables MAC-address based filter to reject packets, not to drop them, so it's not a TCP stack issue). /sbin/iptables -A INPUT -m mac --mac-source 00:0B:DB:E7:9D:1F -d 0/0 -j REJECT --reject-with icmp-host-prohibited However, when the app server is already running and DB connection goes down (iptables filter is installed) - the app is hanging instead of generating an exception within a reasonable timeout period. Any clues how to prevent this from happening? I need an app to generate an exception instead of hanging. Are there any hidden driver setting or deployment plan elements to configure this? This is happening on geronimo 1.1.1, and the app is using JDBC calls directly, without any ORM or caching. Thank you for any help with this, --Pavel. console.dbpool DevDBPool2 1.0 rar oracle oracle-thin 10.2.0.2 jar =20 javax.sql.DataSource DevDBPool2 xxxxxxxxx oracle.jdbc.OracleDriver xxxxxxxxx jdbc:oracle:thin:@devdb.pmd:1521:SPMDDB1 20 0 =20 5000 =20 10