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

Better check whether report is cached #13902

Merged
merged 1 commit into from Jan 22, 2019
Merged

Better check whether report is cached #13902

merged 1 commit into from Jan 22, 2019

Conversation

tsteur
Copy link
Member

@tsteur tsteur commented Dec 21, 2018

refs #13883 and #13892

Checking for $cache->contains($lazyCacheId) and then $cache->fetch($lazyCacheId) can run into race conditions when the cache expires just in between. I reckon this might be the case for #13892 which we see happening like once a day or every other day.

We would possibly also need to check for other usages. Might not actually be an issue cause the transient is used in the lazy cache as well and it should keep the entry during the same request. It could come to this issue though the first time a cache entry is read.

refs #13883 and #13892

Checking for `$cache->contains($lazyCacheId)` and then `$cache->fetch($lazyCacheId)` can run into race conditions when the cache expires just in between. I reckon this might be the case for #13892 which we see happening like once a day or every other day.

We would possibly also need to check for other usages. Might not actually be an issue cause the transient is used in the lazy cache as well and it should keep the entry during the same request. It could come to this issue though the first time a cache entry is read.
@tsteur tsteur added not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org. Needs Review PRs that need a code review labels Dec 21, 2018
@tsteur tsteur added this to the 3.9.0 milestone Dec 21, 2018
@diosmosis diosmosis merged commit 0ca1569 into 3.x-dev Jan 22, 2019
@diosmosis diosmosis deleted the 13892_2 branch January 22, 2019 05:17
@mattab mattab modified the milestones: 3.9.0, 3.8.1 Jan 22, 2019
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 not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants