Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-6595

CheckToursDBTest failed while updating sequence value on disk

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 10.11.1.1
    • Fix Version/s: 10.10.2.1, 10.11.1.1
    • Component/s: SQL
    • Labels:
      None
    • Urgency:
      Blocker
    • Bug behavior facts:
      Regression Test Failure

      Description

      I saw a failure in CheckToursDBTest while running the demo test suite on trunk. It was reported as an ArrayIndexOutOfBoundsException. The ArrayIndexOutOfBoundsException happened during cleanup and shadowed the original exception. The original exception in derby.log looked like this:

      ERROR XSTA2: A transaction was already active, when attempt was made to make another transaction active.
      	at org.apache.derby.iapi.error.StandardException.newException(StandardException.java:290)
      	at org.apache.derby.iapi.error.StandardException.newException(StandardException.java:285)
      	at org.apache.derby.impl.store.raw.xact.XactFactory.pushTransactionContext(XactFactory.java:766)
      	at org.apache.derby.impl.store.raw.xact.XactFactory.startCommonTransaction(XactFactory.java:293)
      	at org.apache.derby.impl.store.raw.xact.XactFactory.startNestedUpdateUserTransaction(XactFactory.java:350)
      	at org.apache.derby.impl.store.raw.RawStore.startNestedUpdateUserTransaction(RawStore.java:460)
      	at org.apache.derby.impl.store.access.RAMTransaction.startNestedUserTransaction(RAMTransaction.java:2326)
      	at org.apache.derby.impl.sql.catalog.SequenceUpdater.updateCurrentValueOnDisk(SequenceUpdater.java:486)
      	at org.apache.derby.impl.sql.catalog.SequenceUpdater.clean(SequenceUpdater.java:218)
      	at org.apache.derby.impl.sql.catalog.SequenceUpdater.clearIdentity(SequenceUpdater.java:257)
      	at org.apache.derby.impl.services.cache.ConcurrentCache.removeEntry(ConcurrentCache.java:167)
      	at org.apache.derby.impl.services.cache.ConcurrentCache.ageOut(ConcurrentCache.java:583)
      	at org.apache.derby.impl.sql.catalog.DataDictionaryImpl.clearSequenceCaches(DataDictionaryImpl.java:8968)
      	at org.apache.derby.impl.sql.catalog.DataDictionaryImpl.clearCaches(DataDictionaryImpl.java:8951)
      	at org.apache.derby.impl.sql.catalog.DataDictionaryImpl.clearCaches(DataDictionaryImpl.java:8937)
      	at org.apache.derby.impl.sql.catalog.DataDictionaryImpl.doneReading(DataDictionaryImpl.java:1184)
      	at org.apache.derby.impl.sql.GenericStatement.prepMinion(GenericStatement.java:519)
      	at org.apache.derby.impl.sql.GenericStatement.prepareStorable(GenericStatement.java:687)
      	at org.apache.derby.iapi.sql.dictionary.SPSDescriptor.compileStatement(SPSDescriptor.java:373)
      	at org.apache.derby.iapi.sql.dictionary.SPSDescriptor.prepareAndRelease(SPSDescriptor.java:264)
      	at org.apache.derby.iapi.sql.dictionary.SPSDescriptor.getPreparedStatement(SPSDescriptor.java:739)
      	at org.apache.derby.iapi.sql.dictionary.SPSDescriptor.getPreparedStatement(SPSDescriptor.java:655)
      	at org.apache.derby.impl.sql.execute.GenericTriggerExecutor.executeSPS(GenericTriggerExecutor.java:171)
      	at org.apache.derby.impl.sql.execute.GenericTriggerExecutor.executeWhenClauseAndAction(GenericTriggerExecutor.java:346)
      	at org.apache.derby.impl.sql.execute.RowTriggerExecutor.fireTrigger(RowTriggerExecutor.java:113)
      	at org.apache.derby.impl.sql.execute.TriggerEventActivator.notifyEvent(TriggerEventActivator.java:272)
      	at org.apache.derby.impl.sql.execute.UpdateResultSet.fireAfterTriggers(UpdateResultSet.java:831)
      	at org.apache.derby.impl.sql.execute.UpdateResultSet.open(UpdateResultSet.java:282)
      	at org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(GenericPreparedStatement.java:470)
      	at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java:349)
      	at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1338)
      	at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:704)
      	at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:631)
      	at org.apache.derbyTesting.functionTests.tests.demo.CheckToursDBTest.doUpdate(CheckToursDBTest.java:163)
      	at org.apache.derbyTesting.functionTests.tests.demo.CheckToursDBTest.testToursDB(CheckToursDBTest.java:108)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:483)
      	at junit.framework.TestCase.runTest(TestCase.java:168)
      	at junit.framework.TestCase.runBare(TestCase.java:134)
      	at org.apache.derbyTesting.junit.BaseTestCase.runBare(BaseTestCase.java:118)
      	at org.apache.derbyTesting.junit.BaseJDBCTestCase.runBareOverridable(BaseJDBCTestCase.java:440)
      	at org.apache.derbyTesting.junit.BaseJDBCTestCase.runBare(BaseJDBCTestCase.java:457)
      	at junit.framework.TestResult$1.protect(TestResult.java:110)
      	at junit.framework.TestResult.runProtected(TestResult.java:128)
      	at junit.framework.TestResult.run(TestResult.java:113)
      	at junit.framework.TestCase.run(TestCase.java:124)
      	at junit.framework.TestSuite.runTest(TestSuite.java:232)
      	at junit.framework.TestSuite.run(TestSuite.java:227)
      	at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
      	at junit.extensions.TestSetup$1.protect(TestSetup.java:23)
      	at junit.framework.TestResult.runProtected(TestResult.java:128)
      	at junit.extensions.TestSetup.run(TestSetup.java:27)
      	at junit.framework.TestSuite.runTest(TestSuite.java:232)
      	at junit.framework.TestSuite.run(TestSuite.java:227)
      	at junit.framework.TestSuite.runTest(TestSuite.java:232)
      	at junit.framework.TestSuite.run(TestSuite.java:227)
      	at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:518)
      	at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.launch(JUnitTestRunner.java:1052)
      	at org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:906)
      

        Attachments

        1. error-stacktrace.txt
          5 kB
          Knut Anders Hatlen
        2. derby-6595-01-aa-dontClearSequenceCache.diff
          0.7 kB
          Rick Hillegas
        3. derby.log
          24 kB
          Knut Anders Hatlen

          Issue Links

            Activity

              People

              • Assignee:
                rhillegas Rick Hillegas
                Reporter:
                knutanders Knut Anders Hatlen
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: