[ 
https://issues.apache.org/jira/browse/DERBY-4273?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12724820#action_12724820
 ] 

Knut Anders Hatlen commented on DERBY-4273:
-------------------------------------------

It looks like some other test is reducing the lock timeouts without resetting 
them, so derby.locks.waitTimeout is 3 seconds, not the expected 60 seconds, 
when the test is run as part of suites.All. I think ResultSetMiscTest and/or 
SetTransactionIsolationTest is the culprit.

> A lock could not be obtained within the time requested error in 
> testBTreeForwardScan_fetchRows_resumeAfterWait_nonUnique_split
> ------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: DERBY-4273
>                 URL: https://issues.apache.org/jira/browse/DERBY-4273
>             Project: Derby
>          Issue Type: Bug
>          Components: Regression Test Failure, Test
>    Affects Versions: 10.5.1.2
>            Reporter: Mamta A. Satoor
>            Assignee: Knut Anders Hatlen
>             Fix For: 10.5.1.2, 10.6.0.0
>
>         Attachments: d4273.diff
>
>
> I recently merged changes for DERBY-3926 into 10.5.1.2 codeline (revision 
> 784809) and I ran the junit tests on the merged code. The tests finished with 
> one "A lock could not be obtained within the time requested". Knut suggested 
> that I open a new jira entry for this issue. Copying his comment from 
> DERBY-2991 here "Yes, that test was added for DERBY-2991.. It requires some 
> coordination between two threads, so my first guess would be that there is a 
> timing issue in the test. Please file a separate JIRA issue for this failure. 
> Thanks. "
> Following is the stack track for the failure
> There was 1 error: 
> 1) 
> testBTreeForwardScan_fetchRows_resumeAfterWait_nonUnique_split(org.apache.derbyTesting.functionTests.tests.store.IndexSplitDeadlockTest)java.sql.SQLException:
>  A lock could not be obtained within the time requested 
>         at 
> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(SQLExceptionFactory.java:45)
>  
>         at 
> org.apache.derby.impl.jdbc.Util.generateCsSQLException(Util.java:201) 
>         at 
> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(TransactionResourceImpl.java:391)
>  
>         at 
> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(TransactionResourceImpl.java:346)
>  
>         at 
> org.apache.derby.impl.jdbc.EmbedConnection.handleException(EmbedConnection.java:2201)
>  
>         at 
> org.apache.derby.impl.jdbc.ConnectionChild.handleException(ConnectionChild.java:81)
>  
>         at 
> org.apache.derby.impl.jdbc.EmbedResultSet.closeOnTransactionError(EmbedResultSet.java:4338)
>  
>         at 
> org.apache.derby.impl.jdbc.EmbedResultSet.movePosition(EmbedResultSet.java:467)
>  
>         at 
> org.apache.derby.impl.jdbc.EmbedResultSet.next(EmbedResultSet.java:371) 
>         at 
> org.apache.derbyTesting.functionTests.tests.store.IndexSplitDeadlockTest.testBTreeForwardScan_fetchRows_resumeAfterWait_nonUnique_split(IndexSplitDeadlockTest.java:489)
>  
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
>         at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79) 
>         at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>  
>         at 
> org.apache.derbyTesting.junit.BaseTestCase.runBare(BaseTestCase.java:106) 
>         at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22) 
>         at junit.extensions.TestSetup$1.protect(TestSetup.java:19) 
>         at junit.extensions.TestSetup.run(TestSetup.java:23) 
>         at 
> org.apache.derbyTesting.junit.BaseTestSetup.run(BaseTestSetup.java:57) 
>         at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22) 
>         at junit.extensions.TestSetup$1.protect(TestSetup.java:19) 
>         at junit.extensions.TestSetup.run(TestSetup.java:23) 
>         at 
> org.apache.derbyTesting.junit.BaseTestSetup.run(BaseTestSetup.java:57) 
> Caused by: ERROR 40XL1: A lock could not be obtained within the time 
> requested at 
> org.apache.derby.iapi.error.StandardException.newException(StandardException.java:276)
>  
>         at 
> org.apache.derby.impl.services.locks.ConcurrentLockSet.lockObject(ConcurrentLockSet.java:602)
>  
>         at 
> org.apache.derby.impl.services.locks.ConcurrentLockSet.zeroDurationLockObject(ConcurrentLockSet.java:855)
>  
>         at 
> org.apache.derby.impl.services.locks.AbstractPool.zeroDurationlockObject(AbstractPool.java:297)
>  
>         at 
> org.apache.derby.impl.store.raw.xact.RowLocking2nohold.lockRecordForRead(RowLocking2nohold.java:89)
>  
>         at 
> org.apache.derby.impl.store.access.heap.HeapController.lockRow(HeapController.java:520)
>  
>         at 
> org.apache.derby.impl.store.access.heap.HeapController.lockRow(HeapController.java:638)
>  
>         at 
> org.apache.derby.impl.store.access.btree.index.B2IRowLocking3.lockRowOnPage(B2IRowLocking3.java:309)
>  
>         at 
> org.apache.derby.impl.store.access.btree.index.B2IRowLocking3._lockScanRow(B2IRowLocking3.java:599)
>  
>         at 
> org.apache.derby.impl.store.access.btree.index.B2IRowLockingRR.lockScanRow(B2IRowLockingRR.java:105)
>  
>         at 
> org.apache.derby.impl.store.access.btree.BTreeForwardScan.fetchRows(BTreeForwardScan.java:305)
>  
>         at 
> org.apache.derby.impl.store.access.btree.BTreeScan.fetchNextGroup(BTreeScan.java:1585)
>  
>         at 
> org.apache.derby.impl.sql.execute.BulkTableScanResultSet.reloadArray(BulkTableScanResultSet.java:327)
>  
>         at 
> org.apache.derby.impl.sql.execute.BulkTableScanResultSet.getNextRowCore(BulkTableScanResultSet.java:282)
>  
>         at 
> org.apache.derby.impl.sql.execute.BasicNoPutResultSetImpl.getNextRow(BasicNoPutResultSetImpl.java:460)
>  
>         at 
> org.apache.derby.impl.jdbc.EmbedResultSet.movePosition(EmbedResultSet.java:427)
>  
>         ... 34 more 
> FAILURES!!! 
> Tests run: 9258, Failures: 0, Errors: 1 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to