You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geode.apache.org by Shirish Deshmukh <sd...@pivotal.io> on 2015/08/04 08:18:56 UTC
Review Request 37066: Fix for GEODE-110
(DistributedTransactionDUnitTest.testPutAllWithTransactions failed with
CommitIncompleteException)
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37066/
-----------------------------------------------------------
Review request for geode and vivek bhaskar.
Repository: geode
Description
-------
In the context of distributed transactions, DistributedPutAllOperation.createPRMessages calls putAllData[i].setFakeEventID() to set event ID for each entry in put all op (called from DistTXStateProxyImplOnCoordinator.postPutAll->DistPeerTXStateStub.postPutAll->TXStateStub.postPutAll -> PartitionedTXRegionStub.postPutAll). However when the data node itself is a transaction coordinator,
createPRMessages is not called and the data is locally put by calling DistTXStateProxyImplOnCoordinator.postPutAll->DistTXStateOnCoordinator.postPutAll(). This call sequence does not call putAllData[i].setFakeEventID(). At the commit time when the coordinator sends TX events to secondaries, some of the events from different buckets had same event ID. This caused TXState.txPutEntry() to skip those events (assuming that the entry has been processed already) and therefore the test failed. The fix is to call putallOp.putAllData[i].setFakeEventID() in DistTXStateProxyImplOnCoordinator.postPutAll so that eventID is set for all entries. Similar fix is done for remove all.
Also enabled the assertion that was surrounded by logger.isDebugEnabled() call due to this issue
Fix is specific to Distributed TX (feature under development).
Diffs
-----
gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/DistTXStateProxyImplOnCoordinator.java 2f79605
gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/TXRegionState.java 67cb8c5
Diff: https://reviews.apache.org/r/37066/diff/
Testing
-------
./gradlew gemfire-core:integrationTest -DintegrationTest.single=*DistTX*JUnit*
./gradlew -DdistributedTest.single=DistTXDistributedTestSuite gemfire-core:distributedTest
100 runs DistributedTransactionDUnitTest successful
Thanks,
Shirish Deshmukh
Re: Review Request 37066: Fix for GEODE-110
(DistributedTransactionDUnitTest.testPutAllWithTransactions failed with
CommitIncompleteException)
Posted by vivek bhaskar <vi...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37066/#review94000
-----------------------------------------------------------
Ship it!
Ship It!
- vivek bhaskar
On Aug. 4, 2015, 6:18 a.m., Shirish Deshmukh wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/37066/
> -----------------------------------------------------------
>
> (Updated Aug. 4, 2015, 6:18 a.m.)
>
>
> Review request for geode and vivek bhaskar.
>
>
> Repository: geode
>
>
> Description
> -------
>
> In the context of distributed transactions, DistributedPutAllOperation.createPRMessages calls putAllData[i].setFakeEventID() to set event ID for each entry in put all op (called from DistTXStateProxyImplOnCoordinator.postPutAll->DistPeerTXStateStub.postPutAll->TXStateStub.postPutAll -> PartitionedTXRegionStub.postPutAll). However when the data node itself is a transaction coordinator,
> createPRMessages is not called and the data is locally put by calling DistTXStateProxyImplOnCoordinator.postPutAll->DistTXStateOnCoordinator.postPutAll(). This call sequence does not call putAllData[i].setFakeEventID(). At the commit time when the coordinator sends TX events to secondaries, some of the events from different buckets had same event ID. This caused TXState.txPutEntry() to skip those events (assuming that the entry has been processed already) and therefore the test failed. The fix is to call putallOp.putAllData[i].setFakeEventID() in DistTXStateProxyImplOnCoordinator.postPutAll so that eventID is set for all entries. Similar fix is done for remove all.
>
> Also enabled the assertion that was surrounded by logger.isDebugEnabled() call due to this issue
>
> Fix is specific to Distributed TX (feature under development).
>
>
> Diffs
> -----
>
> gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/DistTXStateProxyImplOnCoordinator.java 2f79605
> gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/TXRegionState.java 67cb8c5
>
> Diff: https://reviews.apache.org/r/37066/diff/
>
>
> Testing
> -------
>
> ./gradlew gemfire-core:integrationTest -DintegrationTest.single=*DistTX*JUnit*
> ./gradlew -DdistributedTest.single=DistTXDistributedTestSuite gemfire-core:distributedTest
> 100 runs DistributedTransactionDUnitTest successful
>
>
> Thanks,
>
> Shirish Deshmukh
>
>