-
Notifications
You must be signed in to change notification settings - Fork 234
Don't hit the reader if cache is fresh #412
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
Don't hit the reader if cache is fresh #412
Conversation
The PHPStan failure is unrelated. |
|
#413 fixes the build issue (by not analyzing that file) |
320c01c
to
b5c257b
Compare
And we're green. 🎉 |
Thanks @derrabus! |
I have an issue on API Platform since that change. It looks like
Check the stacktrace by adding in
Maybe that a fix should be done in mongodb-odm? Let me know if I can help further. |
@soyuka can you please create a new issue? I fail to see the relationship between what this PR fixed, the issue you reported in the comment, and the PR that linked to this. |
I confirm that reverting this patch fixes the problem in API Platform. |
Thanks for confirming @dunglas! We'll take another look. |
@dunglas unfortunately I can't find the time to investigate this issue. Would you be able to create a minimal reproducer for us to start our investigation with? Thanks! |
Spotted while working on symfony/symfony#41230.
In debug mode, the
PsrCachedReader
hits the wrapped reader although the cache is still fresh. This happens because the cache items that stores the modification date is not written initially. This PR attempts to fix this problem.