[ 
https://issues.apache.org/jira/browse/IGNITE-22288?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Denis Chudov updated IGNITE-22288:
----------------------------------
    Description: 
{code:java}
[2024-05-20T10:02:21,361][INFO ][Test worker][ItTxResourcesVacuumTest] >>> 
Stopping test: 
ItTxResourcesVacuumTest#testCommitPartitionPrimaryChangesBeforeVacuum, 
displayName: testCommitPartitionPrimaryChangesBeforeVacuum(), cost: 11523ms.  
java.lang.NullPointerException  java.lang.NullPointerException
    at 
org.apache.ignite.internal.table.ItTxResourcesVacuumTest.checkValueReadOnly(ItTxResourcesVacuumTest.java:803)
    at 
org.apache.ignite.internal.table.ItTxResourcesVacuumTest.testCommitPartitionPrimaryChangesBeforeVacuum(ItTxResourcesVacuumTest.java:536)
    at java.base/java.lang.reflect.Method.invoke(Method.java:566) {code}
[https://ci.ignite.apache.org/buildConfiguration/ApacheIgnite3xGradle_Test_RunAllTests/8127603?hideProblemsFromDependencies=false&expandBuildDeploymentsSection=false&hideTestsFromDependencies=false&expandCode+Inspection=true&expandBuildChangesSection=true&expandBuildTestsSection=true&expandBuildProblemsSection=true]

The reason of failure is a bug in vacuum. Persistent tx state is vacuumized 
earlier than cleanup is completed, which causes tx recovery on RO tx with 
rollback outcome for RW tx that was committed and the abort of write intent.

Scenario: tx resource TTL is over, so we check the tx state meta (see
VolatileTxStateMetaStorage#vacuum() ). There is commitPartId (because it's 
commit partition), and we add the tx id to collection that should be passed to 
persistent vacuumizer. Persistent vacuumizer erases the persistent state only 
if we are on the commit partition primary replica, but it doesn't check the 
presense of cleanupCompletionTimestamp, as it should. As a result, it erases 
the persistent state before cleanupCompletionTimestamp appears.

  was:
{code:java}
[2024-05-20T10:02:21,361][INFO ][Test worker][ItTxResourcesVacuumTest] >>> 
Stopping test: 
ItTxResourcesVacuumTest#testCommitPartitionPrimaryChangesBeforeVacuum, 
displayName: testCommitPartitionPrimaryChangesBeforeVacuum(), cost: 11523ms.  
java.lang.NullPointerException  java.lang.NullPointerException
    at 
org.apache.ignite.internal.table.ItTxResourcesVacuumTest.checkValueReadOnly(ItTxResourcesVacuumTest.java:803)
    at 
org.apache.ignite.internal.table.ItTxResourcesVacuumTest.testCommitPartitionPrimaryChangesBeforeVacuum(ItTxResourcesVacuumTest.java:536)
    at java.base/java.lang.reflect.Method.invoke(Method.java:566) {code}
[https://ci.ignite.apache.org/buildConfiguration/ApacheIgnite3xGradle_Test_RunAllTests/8127603?hideProblemsFromDependencies=false&expandBuildDeploymentsSection=false&hideTestsFromDependencies=false&expandCode+Inspection=true&expandBuildChangesSection=true&expandBuildTestsSection=true&expandBuildProblemsSection=true]

The reason of failure is a bug in vacuum. Persistent tx state is vacuumized 
earlier than cleanup is completed, which causes tx recovery on RO tx with 
rollback outcome for RW tx that was committed and the abort of write intent.

Scenario: tx resource TTL is over, so we check the tx state meta (see
VolatileTxStateMetaStorage#vacuum() ). There is commitPartId (because it's 
commit partition), and we add the tx id to collection that should be passed to 
persistent vacuumizer. Persistent vacuumizer erases the persistent state only 
if we are on the commit partition primary replica, but it doesn't check the 
presense of cleanupCompletionTimestamp, as it should. As a result, it erases 
the persistent state.


> ItTxResourcesVacuumTest may fail with NPE
> -----------------------------------------
>
>                 Key: IGNITE-22288
>                 URL: https://issues.apache.org/jira/browse/IGNITE-22288
>             Project: Ignite
>          Issue Type: Bug
>            Reporter: Alexander Lapin
>            Priority: Major
>              Labels: ignite-3
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> {code:java}
> [2024-05-20T10:02:21,361][INFO ][Test worker][ItTxResourcesVacuumTest] >>> 
> Stopping test: 
> ItTxResourcesVacuumTest#testCommitPartitionPrimaryChangesBeforeVacuum, 
> displayName: testCommitPartitionPrimaryChangesBeforeVacuum(), cost: 11523ms.  
> java.lang.NullPointerException  java.lang.NullPointerException
>     at 
> org.apache.ignite.internal.table.ItTxResourcesVacuumTest.checkValueReadOnly(ItTxResourcesVacuumTest.java:803)
>     at 
> org.apache.ignite.internal.table.ItTxResourcesVacuumTest.testCommitPartitionPrimaryChangesBeforeVacuum(ItTxResourcesVacuumTest.java:536)
>     at java.base/java.lang.reflect.Method.invoke(Method.java:566) {code}
> [https://ci.ignite.apache.org/buildConfiguration/ApacheIgnite3xGradle_Test_RunAllTests/8127603?hideProblemsFromDependencies=false&expandBuildDeploymentsSection=false&hideTestsFromDependencies=false&expandCode+Inspection=true&expandBuildChangesSection=true&expandBuildTestsSection=true&expandBuildProblemsSection=true]
> The reason of failure is a bug in vacuum. Persistent tx state is vacuumized 
> earlier than cleanup is completed, which causes tx recovery on RO tx with 
> rollback outcome for RW tx that was committed and the abort of write intent.
> Scenario: tx resource TTL is over, so we check the tx state meta (see
> VolatileTxStateMetaStorage#vacuum() ). There is commitPartId (because it's 
> commit partition), and we add the tx id to collection that should be passed 
> to persistent vacuumizer. Persistent vacuumizer erases the persistent state 
> only if we are on the commit partition primary replica, but it doesn't check 
> the presense of cleanupCompletionTimestamp, as it should. As a result, it 
> erases the persistent state before cleanupCompletionTimestamp appears.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to