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
3.7 HTTP Caching fixes #8318
3.7 HTTP Caching fixes #8318
Conversation
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.
One set of amends, but disabling caching in admin and Security/ping
makes sense
control/HTTPCacheControl.php
Outdated
@@ -358,8 +358,6 @@ public function privateCache($force = false) | |||
// Update the directives | |||
$this->setDirective('private'); | |||
$this->removeDirective('public'); | |||
$this->removeDirective('no-cache'); | |||
$this->removeDirective('no-store'); |
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.
Upon reflection I think these should stay. Reading through the docblock this looks like the intended behaviour, I just think I was thrown off by the method name - maybe enablePrivateCache()
and enablePublicCache()
would be more descriptive names?
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.
ok - I'm on the fence about this too and I think the likelihood of users making manually disabling caching and then calling privateCache()
is low.
I'll remove this change and we can see how it goes without it.
9a5fa5c
to
362c2f3
Compare
Original author: @dhensby Forward port from 3.7 fix at silverstripe#8318
Original author: @dhensby Forward port from 3.7 fix at silverstripe/silverstripe-framework#8318
Original author: @dhensby Forward port from 3.7 fix at silverstripe#8318
Original author: @dhensby Forward port from 3.7 fix at silverstripe/silverstripe-framework#8318
We should do a 3.7 release soon with this fix in |
It is imminent |
Fixes #8289
LeftAndMain
will disable HTTP CachingStopsprivateCache
from removing current state (disabled, etc).