[
https://issues.apache.org/jira/browse/IGNITE-17851?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Anton Vinogradov updated IGNITE-17851:
--------------------------------------
Description:
Currently {{PartitionUpdateCounterTrackingImpl#update()}} just returns false
when closing already closed gaps.
The result is ignored on non-rollback calls at
{{IgniteTxHandler#applyPartitionsUpdatesCounters()}}.
Such behaviour allows to reuse the same counter and this may lead to the hidden
inconsistency.
I've checked that {{PartitionUpdateCounterTrackingImpl#update()}} never returns
false on non-rollback call, using the Assertion.
{{PartitionUpdateCounterTrackingImpl#update()}} method should be refactored to
provide only-once closing guarantee or
{{IgniteTxHandler#applyPartitionsUpdatesCounters()}} shoud check the update
result for every the call (including non-rollback).
was:
Currently {{PartitionUpdateCounterTrackingImpl#update()}} just returns false
when closing already closed gap.
Such behaviour allows to reuse the same counter and may lead to the hidden
inconsistency.
It should be refactored to provide only-once closing guarantee.
According to the PR (I have checked the change at the TeamCity) none tests
fails on a explicit assertion added to the
{{IgniteTxHandler#applyPartitionsUpdatesCounters()}} which checks that
PartitionUpdateCounterTrackingImpl#update() never returns the false.
So, all we need it so refactor the method to avoid "false" returning.
BTW, it looks like after the refactoring we able to get rid of boolean return
at {{PartitionUpdateCounter#update()}} at all.
> TX cache update counter must deny already closed gaps re-closing instead of
> returning false
> -------------------------------------------------------------------------------------------
>
> Key: IGNITE-17851
> URL: https://issues.apache.org/jira/browse/IGNITE-17851
> Project: Ignite
> Issue Type: Sub-task
> Reporter: Anton Vinogradov
> Priority: Major
>
> Currently {{PartitionUpdateCounterTrackingImpl#update()}} just returns false
> when closing already closed gaps.
> The result is ignored on non-rollback calls at
> {{IgniteTxHandler#applyPartitionsUpdatesCounters()}}.
> Such behaviour allows to reuse the same counter and this may lead to the
> hidden inconsistency.
> I've checked that {{PartitionUpdateCounterTrackingImpl#update()}} never
> returns false on non-rollback call, using the Assertion.
> {{PartitionUpdateCounterTrackingImpl#update()}} method should be refactored
> to provide only-once closing guarantee or
> {{IgniteTxHandler#applyPartitionsUpdatesCounters()}} shoud check the update
> result for every the call (including non-rollback).
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)