-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle invalidation of currently processed archives correctly #22392
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sgiehl
added
Bug
For errors / faults / flaws / inconsistencies etc.
Major
Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
labels
Jul 15, 2024
sgiehl
force-pushed
the
inprogressinvalidation
branch
from
July 16, 2024 13:01
90808ff
to
7806cd6
Compare
tests/PHPUnit/Integration/DataAccess/ArchiveInvalidatorTest.php
Outdated
Show resolved
Hide resolved
michalkleiner
approved these changes
Jul 16, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code changes make sense to me. I've left some minor code suggestions but it'd be ok if not accepted, too.
Co-authored-by: Michal Kleiner <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Bug
For errors / faults / flaws / inconsistencies etc.
Major
Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Needs Review
PRs that need a code review
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description:
When a period is being invalidated for whatever reason, we currently update all existing archives to the state INVALIDATED. Invalidated archives may still be used for reporting until new archives were built.
Updating archives to invalidated currently is also done for archives that are still in progress. In progress archives aren't considered for the reporting. So updating them to invalidated while they are still processed currently has the effect, that unfinished archives might be used for reporting, causing report data to disappear, for reports that were not yet processed for this archive. Once the archiving is finished those archives are updated to OK, causing them to get final again, even if they had been marked as invalidated in between.
This PR fixes the behavior by introducing a new state to mark in progress archives invalidated. This new state won't be considered for reporting, but when the archiving finished, the status will be updated to INVALIDATED instead of OK.
Refs DEV-18289
Review