[
https://issues.apache.org/jira/browse/DERBY-6692?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14088012#comment-14088012
]
Rick Hillegas commented on DERBY-6692:
--------------------------------------
Tests ran cleanly for me on derby-6692-01-ab-withTests.diff except for the
following error in RuntimeInfoTest. That test runs cleanly for me standalone.
The test is in the derbynet suite. I created a slimmed down version of the
master JUnit suite (All.java), including only the tests up through the derbynet
suite. I ran that mini-suite 5 times but did not see the error. I intend to
check in this patch and see if the heisenbug can be tripped by the full
platform tests.
{noformat}
There was 1 failure:
1)
testRunTests(org.apache.derbyTesting.functionTests.tests.derbynet.RuntimeInfoTest)junit.framework.ComparisonFailure:
Output doesn't match expected:<...--------
Session # :[8
-------------------------------------------------------------
# Connection Threads : 4
# Active Sessions : 1]
# Waiting Sessions...> but was:<...--------
Session # :[5
Database :singleUse/oneuse4
User :APP
# Statements:2
Prepared Statement Information:
Stmt ID SQLText
------------- -----------
null
null
Session # :8
-------------------------------------------------------------
# Connection Threads : 4
# Active Sessions : 2]
# Waiting Sessions...>
at
org.apache.derbyTesting.functionTests.tests.derbynet.RuntimeInfoTest.x_testRuntimeInfoAfterConnClose(RuntimeInfoTest.java:192)
at
org.apache.derbyTesting.functionTests.tests.derbynet.RuntimeInfoTest.testRunTests(RuntimeInfoTest.java:97)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
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.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
at junit.extensions.TestSetup.run(TestSetup.java:25)
at
org.apache.derbyTesting.junit.BaseTestSetup.run(BaseTestSetup.java:57)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
at junit.extensions.TestSetup.run(TestSetup.java:25)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
at junit.extensions.TestSetup.run(TestSetup.java:25)
at
org.apache.derbyTesting.junit.BaseTestSetup.run(BaseTestSetup.java:57)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
at junit.extensions.TestSetup.run(TestSetup.java:25)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
at junit.extensions.TestSetup.run(TestSetup.java:25)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:21)
at junit.extensions.TestSetup.run(TestSetup.java:25)
FAILURES!!!
Tests run: 19211, Failures: 1, Errors: 0
{noformat}
> Self-deadlock when inserting row with identity column in soft-upgraded
> database
> -------------------------------------------------------------------------------
>
> Key: DERBY-6692
> URL: https://issues.apache.org/jira/browse/DERBY-6692
> Project: Derby
> Issue Type: Bug
> Components: SQL
> Affects Versions: 10.11.1.1
> Reporter: Knut Anders Hatlen
> Assignee: Rick Hillegas
> Attachments: derby-6692-01-aa-handleSelfDeadlock.diff,
> derby-6692-01-ab-withTests.diff
>
>
> Create a database called "wombat" with Derby 10.10.2.0.
> Then, in the same directory, execute the following code using the 10.11.1.0
> release candidate:
> {code}
> Connection c = DriverManager.getConnection("jdbc:derby:wombat");
> c.setAutoCommit(false);
> Statement s = c.createStatement();
> s.execute("create table t(i int generated always as identity)");
> s.execute("insert into t values (default)");
> c.rollback();
> {code}
> The INSERT statement will fail with a self-deadlock:
> {noformat}
> Exception in thread "main" java.sql.SQLTransactionRollbackException:
> Self-deadlock.
> at
> org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
> at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown
> Source)
> at
> org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown
> Source)
> at
> org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown
> Source)
> at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown
> Source)
> at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown
> Source)
> at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown
> Source)
> at org.apache.derby.impl.jdbc.EmbedStatement.execute(Unknown Source)
> at org.apache.derby.impl.jdbc.EmbedStatement.execute(Unknown Source)
> at Kladd.main(Kladd.java:12)
> Caused by: ERROR 40XL2: Self-deadlock.
> at org.apache.derby.iapi.error.StandardException.newException(Unknown
> Source)
> at org.apache.derby.iapi.error.StandardException.newException(Unknown
> Source)
> at
> org.apache.derby.impl.services.locks.ConcurrentLockSet.lockObject(Unknown
> Source)
> at org.apache.derby.impl.services.locks.AbstractPool.lockObject(Unknown
> Source)
> at
> org.apache.derby.impl.services.locks.ConcurrentPool.lockObject(Unknown Source)
> at
> org.apache.derby.impl.store.raw.xact.RowLocking3.lockRecordForWrite(Unknown
> Source)
> at
> org.apache.derby.impl.store.access.conglomerate.OpenConglomerate.lockPositionForWrite(Unknown
> Source)
> at
> org.apache.derby.impl.store.access.conglomerate.GenericConglomerateController.fetch(Unknown
> Source)
> at
> org.apache.derby.impl.sql.catalog.DataDictionaryImpl.getSetAutoincrementValue(Unknown
> Source)
> at
> org.apache.derby.impl.sql.execute.InsertResultSet.getOldStyleIdentityValue(Unknown
> Source)
> at
> org.apache.derby.impl.sql.execute.InsertResultSet.getSetAutoincrementValue(Unknown
> Source)
> at
> org.apache.derby.impl.sql.execute.BaseActivation.getSetAutoincrementValue(Unknown
> Source)
> at
> org.apache.derby.exe.acaaeec04ex0147xab31x1ccax000007dedc900.e0(Unknown
> Source)
> at org.apache.derby.impl.services.reflect.DirectCall.invoke(Unknown
> Source)
> at
> org.apache.derby.impl.sql.execute.RowResultSet.getNextRowCore(Unknown Source)
> at
> org.apache.derby.impl.sql.execute.DMLWriteResultSet.getNextRowCore(Unknown
> Source)
> at
> org.apache.derby.impl.sql.execute.InsertResultSet.getNextRowCore(Unknown
> Source)
> at org.apache.derby.impl.sql.execute.InsertResultSet.open(Unknown
> Source)
> at
> org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(Unknown Source)
> at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown
> Source)
> ... 4 more
> {noformat}
--
This message was sent by Atlassian JIRA
(v6.2#6252)