Skip to content
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

core:archive when looking for other climulti processes, also make sure idSite is same #16992

Merged
merged 3 commits into from Dec 21, 2020

Conversation

diosmosis
Copy link
Member

@diosmosis diosmosis commented Dec 21, 2020

Description:

As title. This is in case there are multiple archivers running on the same machine, we can pick up climulti requests for other sites.

Review

  • Functional review done
  • Usability review done (is anything maybe unclear or think about anything that would cause people to reach out to support)
  • Security review done see checklist
  • Code review done
  • Tests were added if useful/possible
  • Reviewed for breaking changes
  • Developer changelog updated if needed
  • Documentation added if needed
  • Existing documentation updated if needed

@diosmosis diosmosis added the Needs Review PRs that need a code review label Dec 21, 2020
@diosmosis diosmosis added this to the 4.0.x milestone Dec 21, 2020
@diosmosis
Copy link
Member Author

FYI @tsteur

@@ -397,18 +397,25 @@ private function shouldSkipArchiveBecauseLowerPeriodOrSegmentIsInProgress(array
continue;
}

if (empty($archiveBeingProcessed['idSite'])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haven't had a deeper look at the code, but should it actually happen that idSite isn't set for an archiving process? If so wouldn't we need to check if idSite of both aren't empty here? 🤔

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a bit confusing, but here $archiveBeingProcessed are the parameters for a climulti:request, while $archiveToProcess is a row in archive_invalidations. So idSite might not be set in a climulti:request execution, but idsite will always be in $archiveToProcess.

@tsteur
Copy link
Member

tsteur commented Dec 21, 2020

Seems tests are passing @diosmosis . is it good to merge?

@diosmosis diosmosis merged commit 7591d39 into 4.x-dev Dec 21, 2020
@diosmosis diosmosis deleted the archive-climulti-detect-check-site branch December 21, 2020 17:30
@mattab mattab changed the title When looking for other climulti processes, also make sure idSite is same. core:archive when looking for other climulti processes, also make sure idSite is same Dec 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Review PRs that need a code review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants