-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[HttpKernel] Move duplicated logic from Esi/Ssi to an AbstractSurrogate #18833
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
Conversation
6b3835c
to
fb6860c
Compare
1e8040d
to
cd802cf
Compare
cd802cf
to
e24b1bd
Compare
throw $e; | ||
} | ||
} | ||
// remove SSI/1.0 from the Surrogate-Control header |
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.
Comment looks wrong.
Fabbot fixes Move duplicated logic from Esi/Ssi::process in AbstractSurrogate::removeFromControl Fabbot fixes Fix comment
e24b1bd
to
c5dc50d
Compare
Thank you @chalasr. |
…AbstractSurrogate (chalasr) This PR was merged into the 3.2-dev branch. Discussion ---------- [HttpKernel] Move duplicated logic from Esi/Ssi to an AbstractSurrogate | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations?| no | Tests pass? | yes | Fixed tickets | n/a | License | MIT | Doc PR | n/a Commits ------- c5dc50d Move duplicated logic from Esi/Ssi to an AbstractSurrogate
* @author Fabien Potencier <fabien@symfony.com> | ||
* @author Robin Chalas <robin.chalas@gmail.com> | ||
*/ | ||
abstract class AbstractSurrogate implements SurrogateInterface |
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.
this should be either marked as @internal
or the PR is a new feature in contrast to the PR header (which means a use-case should be given).
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.
@Tobion I marked it as a new feature in the header (as made in the merge commit) & added a description.
This moves the not-specific logic from the Esi/Ssi classes into an abstract class that they extend.
This class (
AbstractSurrogate
) can be extended by any class implementing a Surrogate-Capability to the Request+Response instances, as Esi/Ssi do for ESI/SSI capabilities.