Return-Path: X-Original-To: apmail-db-derby-commits-archive@www.apache.org Delivered-To: apmail-db-derby-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E0895FFC2 for ; Tue, 9 Apr 2013 20:48:37 +0000 (UTC) Received: (qmail 11267 invoked by uid 500); 9 Apr 2013 20:48:37 -0000 Delivered-To: apmail-db-derby-commits-archive@db.apache.org Received: (qmail 11220 invoked by uid 500); 9 Apr 2013 20:48:37 -0000 Mailing-List: contact derby-commits-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: "Derby Development" List-Id: Delivered-To: mailing list derby-commits@db.apache.org Received: (qmail 11213 invoked by uid 99); 9 Apr 2013 20:48:37 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Apr 2013 20:48:37 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Apr 2013 20:48:36 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id A01A72388A29; Tue, 9 Apr 2013 20:48:16 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1466225 - /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/InterruptResilienceTest.java Date: Tue, 09 Apr 2013 20:48:16 -0000 To: derby-commits@db.apache.org From: mikem@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130409204816.A01A72388A29@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: mikem Date: Tue Apr 9 20:48:16 2013 New Revision: 1466225 URL: http://svn.apache.org/r1466225 Log: DERBY-6122 - InterruptResilienceTest fails with: junit.framework.ComparisonFailure: Database shutdown expected:<[08006]> but was:<[XBDA0]> The core problem that led to this assert was that an attempt by the test to shutdown the database timed out with: Caused by: java.sql.SQLException: Login timeout exceeded. The test had set a 10 second timeout assuming that was large enough such that no timeout would be encountered, but failed a few times in public IBM lab nightly regression runs. Raising the number to 1000. Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/InterruptResilienceTest.java Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/InterruptResilienceTest.java URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/InterruptResilienceTest.java?rev=1466225&r1=1466224&r2=1466225&view=diff ============================================================================== --- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/InterruptResilienceTest.java (original) +++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/store/InterruptResilienceTest.java Tue Apr 9 20:48:16 2013 @@ -135,8 +135,23 @@ public class InterruptResilienceTest ext thisConf = TestConfiguration.getCurrent(); threadNo = 0; // counter for multiple threads tests - // test that we recover from login timeouts - DriverManager.setLoginTimeout( 10 ); + // DERBY-6122 + // + // Set a big enough timeout such that no fixture in this test encounters + // a timeout. The point is to force the Derby tests to exercise a new + // block of code added to Driver20 to handle interrupts raised during + // login attempts. As InterruptResilienceTest runs, interrupts are + // supposed to happen--although it's hard to force the exact timing of + // the interrupts. The login timeout added to this test is only + // supposed to test the following case: + // + // 1) An interrupt occurs within the time limit set + // by DriverManager.setLoginTimeout() + // + // 2) The new code added to Driver20 fields the interrupt and continues + // attempting to log in. + // + DriverManager.setLoginTimeout( 1000 ); allDone = false; // flag for threads to terminate }