Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[HttpFoundation] BC break for Cache-Control headers #25448

Closed
@dmaicher

Description

@dmaicher
Q A
Bug report? yes
Feature request? no
BC Break report? yes
RFC? no
Symfony version 3.4.1

Today I deployed an upgrade of my biggest app from symfony 3.3 to 3.4.1. So far so good but unfortunately there seems to be a BC break regarding some Cache-Control headers that are being sent now for some reason once a session is started.

This seems to be caused by this line https://github.com/symfony/symfony/pull/24878/files#diff-d29419a0d7043fce54a98005c26a82aaR36

I have some responses that are cached publicly in Varnish using some cache control headers being added to the response in the controller action:

    "cache-control" => array:1 [
      0 => "public, s-maxage=3600"
    ]

Those headers are now unfortunately useless and the final headers being received from the backend by Varnish are:

Cache-Control: max-age=0, private, must-revalidate, public, s-maxage=3600

cc @nicolas-grekas

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions