]
Dan Berindei updated ISPN-11076:
--------------------------------
Status: Pull Request Sent (was: Open)
Git Pull Request:
The test is failing so seldom because the lock is only released asynchronously when the
originator is not the primary owner. The primary owner can change from the originator to
another node when a backup is killed, but most of the time it remains the same.
ParticipantFailsAfterPrepareTest.testNonOriginatorFailsAfterPrepare
random failures
-----------------------------------------------------------------------------------
Key: ISPN-11076
URL:
https://issues.redhat.com/browse/ISPN-11076
Project: Infinispan
Issue Type: Bug
Components: Core, Test Suite
Affects Versions: 10.1.0.CR1
Reporter: Dan Berindei
Assignee: Dan Berindei
Priority: Major
Labels: testsuite_stability
Fix For: 10.1.0.Final
The test checks that all locks are released properly after a tx participant is killed,
but doesn't consider the fact that {{TxCompletionNotificationCommand}} is invoked
asynchronously.
{noformat}
00:55:29,005 TRACE (testng-Test:[]) [DefaultLockManager] Lock
key=MagicKey{745/083A744A/71@Test-NodeA-51773} for owner=GlobalTx:Test-NodeA-51773:9335.
timeout=10000 (MILLISECONDS)
00:55:29,177 TRACE (remote-thread-Test-NodeB-p22871-t2:[]) [DefaultLockManager] Lock
key=MagicKey{745/083A744A/71@Test-NodeA-51773} for owner=GlobalTx:Test-NodeA-51773:9335.
timeout=10000 (MILLISECONDS)
00:55:29,178 TRACE (jgroups-8,Test-NodeA-51773:[]) [DefaultLockManager] Release locks for
keys=[MagicKey{745/083A744A/71@Test-NodeA-51773}]. owner=GlobalTx:Test-NodeA-51773:9335
00:55:29,179 TRACE (testng-Test:[]) [JGroupsTransport] Test-NodeA-51773 sending command
to [Test-NodeD-59848, Test-NodeA-51773, Test-NodeB-24298, Test-NodeC-43307]:
TxCompletionNotificationCommand{ xid=null, internalId=0, topologyId=18,
gtx=GlobalTx:Test-NodeA-51773:9335, cacheName=Test}
00:55:29,184 TRACE (remote-thread-Test-NodeD-p22929-t2:[]) [DefaultLockManager] Release
locks for keys=[]. owner=GlobalTx:Test-NodeA-51773:9335
00:55:29,184 TRACE (remote-thread-Test-NodeB-p22871-t2:[]) [DefaultLockManager] Release
locks for keys=[MagicKey{745/083A744A/71@Test-NodeA-51773}].
owner=GlobalTx:Test-NodeA-51773:9335
00:55:29,186 ERROR (testng-Test:[]) [TestSuiteProgress] Test failed:
org.infinispan.tx.ParticipantFailsAfterPrepareTest.testNonOriginatorFailsAfterPrepare
java.lang.AssertionError: expected [0] but found [1]
at org.testng.Assert.fail(Assert.java:96) ~[testng-6.14.3.jar:?]
at org.testng.Assert.failNotEquals(Assert.java:776) ~[testng-6.14.3.jar:?]
at org.testng.Assert.assertEqualsImpl(Assert.java:137) ~[testng-6.14.3.jar:?]
at org.testng.Assert.assertEquals(Assert.java:118) ~[testng-6.14.3.jar:?]
at org.testng.Assert.assertEquals(Assert.java:652) ~[testng-6.14.3.jar:?]
at org.testng.Assert.assertEquals(Assert.java:662) ~[testng-6.14.3.jar:?]
at
org.infinispan.tx.ParticipantFailsAfterPrepareTest.testNonOriginatorFailsAfterPrepare(ParticipantFailsAfterPrepareTest.java:90)
~[test-classes/:?]
{noformat}