Commit Graph

31659 Commits

Author SHA1 Message Date
Florent Olivaud
a85d5b01f7 Fix Predis client cluster with pipeline 2017-06-21 11:32:59 +02:00
Robin Chalas
dabecdee99 [Dotenv] Test load() with multiple paths 2017-06-21 09:43:27 +02:00
Fabien Potencier
be6af2e944 Merge branch '2.7' into 2.8
* 2.7:
  [Routing] Fix XmlFileLoader exception message
  Sessions: configurable "use_strict_mode" option for NativeSessionStorage
  [FrameworkBundle] [Command] Clean bundle directory, fixes #23177
  Reset redirectCount when throwing exception
  [TwigBundle] Remove template.xml services when templating is disabled
  add content-type header on exception response
  Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response
  Fix two edge cases in ResponseCacheStrategy
  [Routing] Expose request in route conditions, if needed and possible
  [Routing] Expose request in route conditions, if needed and possible
  [Translation][FrameworkBundle] Fix resource loading order inconsistency reported in #23034
  [Filesystem] added workaround in Filesystem::rename for PHP bug
  Add tests for ResponseCacheStrategy to document some more edge cases
  [HttpFoundation] added missing docs
  fixes #21606
  [VarDumper] fixes
  [Security] fix switch user _exit without having current token
2017-06-20 16:27:56 -07:00
Oleg Voronkovich
1c091eb703 [Console] Fix catching exception type in QuestionHelper 2017-06-20 23:21:43 +03:00
Fabien Potencier
035d5260b9 bug #23218 [DI] Dedup tags when using instanceof/autoconfigure (ogizanagi)
This PR was merged into the 3.3 branch.

Discussion
----------

[DI] Dedup tags when using instanceof/autoconfigure

| Q             | A
| ------------- | ---
| Branch?       | 3.3 <!-- see comment below -->
| Bug fix?      | yes
| New feature?  | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass?   | yes, failures unrelated (8dc00bbe8d)
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

This fixes uselessly duplicated tags shown when using the `debug:container` command, or in the dumped container in xml format:
<img width="554" alt="screenshot 2017-06-17 a 20 41 27" src="https://user-images.githubusercontent.com/2211145/27255375-de79fc4e-539d-11e7-98d9-c10074ddcffb.PNG">
<img width="494" alt="screenshot 2017-06-17 a 20 41 54" src="https://user-images.githubusercontent.com/2211145/27255376-de7ff5b8-539d-11e7-97ae-ccd31b1d5254.PNG">
<img width="1371" alt="screenshot 2017-06-17 a 20 42 33" src="https://user-images.githubusercontent.com/2211145/27255377-de869ba2-539d-11e7-8cd7-6005f8a499d6.PNG">

(duplicates here are explained by the twig namespaced and unnamespaced versions, and the controllers being tagged explicitly in https://github.com/symfony/symfony-demo/blob/master/app/config/services.yml#L25, while also being tagged by autoconfiguration ([which is expected](https://github.com/symfony/symfony-docs/pull/7921#discussion_r117585827)))

Commits
-------

9f877efb39 [DI] Dedup tags when using instanceof/autoconfigure
2017-06-20 07:01:46 -07:00
Fabien Potencier
9a276aa023 bug #23231 Improved the exception page when there is no message (javiereguiluz)
This PR was merged into the 3.3 branch.

Discussion
----------

Improved the exception page when there is no message

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23135
| License       | MIT
| Doc PR        | -

Commits
-------

5a18553bf1 Improved the exception page when there is no message
2017-06-20 06:58:57 -07:00
Javier Eguiluz
5a18553bf1 Improved the exception page when there is no message 2017-06-20 13:28:19 +02:00
Javier Eguiluz
46994a105b bug #23229 [WebProfilerBundle] Eliminate line wrap on count column (routing) (e-moe)
This PR was merged into the 2.8 branch.

Discussion
----------

[WebProfilerBundle] Eliminate line wrap on count column (routing)

| Q             | A
| ------------- | ---
| Branch?       | 2.8
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #22959
| License       | MIT
| Doc PR        | n/a

Commits
-------

78f1fde [WebProfilerBundle] Eliminate line wrap on count columnt (routing)
2017-06-20 10:41:14 +02:00
Nikolay Labinskiy
78f1fdeb1c [WebProfilerBundle] Eliminate line wrap on count columnt (routing) 2017-06-20 10:52:59 +03:00
Fabien Potencier
6e75cee83e bug #22732 [Security] fix switch user _exit without having current token (dmaicher)
This PR was merged into the 2.7 branch.

Discussion
----------

[Security] fix switch user _exit without having current token

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #22729
| License       | MIT
| Doc PR        | -

Attempting to `_exit` from a switched user caused an error when not having any token in the storage (for example happens when not logged in + disallowing anonymous users on that firewall):

`[1] Symfony\Component\Debug\Exception\FatalThrowableError: Type error: Argument 1 passed to Symfony\Component\Security\Http\Firewall\SwitchUserListener::getOriginalToken()
        must be an instance of Symfony\Component\Security\Core\Authentication\Token\TokenInterface, null given, called in
        symfony/symfony/src/Symfony/Component/Security/Http/Firewall/SwitchUserListener.php on line 164`

Commits
-------

16da6861be [Security] fix switch user _exit without having current token
2017-06-19 11:57:05 -07:00
Fabien Potencier
f89047dd78 bug #23226 [Validator] replace hardcoded service id (xabbuh)
This PR was merged into the 3.3 branch.

Discussion
----------

[Validator] replace hardcoded service id

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23224
| License       | MIT
| Doc PR        |

Commits
-------

44ff4b1a49 [Validator] replace hardcoded service id
2017-06-19 10:02:19 -07:00
Christian Flothmann
44ff4b1a49 [Validator] replace hardcoded service id 2017-06-19 16:33:26 +02:00
Fabien Potencier
71b61b04a1 minor #23222 [Routing] Fix XmlFileLoader exception message (voronkovich)
This PR was merged into the 2.7 branch.

Discussion
----------

[Routing] Fix XmlFileLoader exception message

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

When an `XmlFileLoader` encounters an unknown tag it throws an exception with message like `Unknown tag "foo" used in file "bar". Expected "default", "requirement" or "option".`. A proper message should be `Unknown tag "foo" used in file "bar". Expected "default", "requirement", "option"  or "condition".`

Commits
-------

f6a94cb56f [Routing] Fix XmlFileLoader exception message
2017-06-19 07:02:36 -07:00
Oleg Voronkovich
f6a94cb56f [Routing] Fix XmlFileLoader exception message 2017-06-18 21:08:05 +03:00
Fabien Potencier
ac9a527b81 bug #22730 [FrameworkBundle] Sessions: configurable "use_strict_mode" option for NativeSessionStorage (MacDada)
This PR was merged into the 2.7 branch.

Discussion
----------

[FrameworkBundle] Sessions: configurable "use_strict_mode" option for NativeSessionStorage

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

It is currently not possible to configure the `use_strict_mode` option for `NativeSessionStorage` in a proper manner.

The reason of this PR: https://github.com/symfony/symfony/pull/22352#issuecomment-302113533

It could be considered a new feature, but I wish it wouldn't, as I don't want to do any ugly hacking to get it working.

What else could be done?

* implement more options from `NativeSessionStorage` in the config?
* get rid of duplication somehow (maybe a static method in `NativeSessionStorage` that would return the option list and could be used in `FrameworkExtension`?)
* update `FrameworkExtensionTest`?
* update `ConfigurationTest`?
* update [the docs](https://symfony.com/doc/current/reference/configuration/framework.html#session)?

I'm willing to do those if decided.

Commits
-------

90e192e824 Sessions: configurable "use_strict_mode" option for NativeSessionStorage
2017-06-18 08:41:46 -07:00
Fabien Potencier
d0065fe4dd minor #23219 [Translation] Fix FileLoader::loadResource() php doc (ogizanagi)
This PR was merged into the 2.8 branch.

Discussion
----------

[Translation] Fix FileLoader::loadResource() php doc

| Q             | A
| ------------- | ---
| Branch?       | 2.8 <!-- see comment below -->
| Bug fix?      | no
| New feature?  | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass?   | yes
| Fixed tickets | N/A <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

Commits
-------

e76ee7a542 [Translation] Fix FileLoader::loadResource() php doc
2017-06-18 08:40:29 -07:00
Maxime Steinhausser
9f877efb39 [DI] Dedup tags when using instanceof/autoconfigure 2017-06-17 21:02:43 +02:00
Maxime Steinhausser
e76ee7a542 [Translation] Fix FileLoader::loadResource() php doc 2017-06-17 21:00:18 +02:00
Dawid Nowak
90e192e824 Sessions: configurable "use_strict_mode" option for NativeSessionStorage
https://github.com/symfony/symfony/pull/22352#issuecomment-302113533
2017-06-16 20:49:16 +02:00
Fabien Potencier
436d5e4e94 bug #23195 [FrameworkBundle] [Command] Clean bundle directory, fixes #23177 (NicolasPion)
This PR was squashed before being merged into the 2.7 branch (closes #23195).

Discussion
----------

[FrameworkBundle] [Command] Clean bundle directory, fixes #23177

| Q             | A
| ------------- | ---
| Branch?       | 2.7 <!-- see comment below -->
| Bug fix?      | yes
| New feature?  | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass?   | no
| Fixed tickets | #23177
| License       | MIT

This PR fix #23177
when running an assets:install, it will remove directorys who do not have anymore a valid Bundle

Commits
-------

180f178f43 [FrameworkBundle] [Command] Clean bundle directory, fixes #23177
2017-06-16 11:24:38 -07:00
Nicolas Pion
180f178f43 [FrameworkBundle] [Command] Clean bundle directory, fixes #23177 2017-06-16 11:24:36 -07:00
Fabien Potencier
772ab3d74b bug #23213 Fixed composer resources between web/cli (iltar)
This PR was merged into the 3.3 branch.

Discussion
----------

Fixed composer resources between web/cli

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | no (reverts one)
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23212
| License       | MIT
| Doc PR        | ~

This is a possible fix for the flawed module check for the composer resource. As this is the easiest fix, I've created a PR ready to be merged.

Commits
-------

9e047122f1 Fixed composer resources between web/cli
2017-06-16 11:17:54 -07:00
Fabien Potencier
1d304d2c9b fixed CS 2017-06-16 10:45:26 -07:00
Fabien Potencier
54b3e71992 bug #23160 [WebProfilerBundle] Fix the icon for the Cache panel (javiereguiluz)
This PR was squashed before being merged into the 3.3 branch (closes #23160).

Discussion
----------

[WebProfilerBundle] Fix the icon for the Cache panel

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23159
| License       | MIT
| Doc PR        | -

Commits
-------

50c1d478ce [WebProfilerBundle] Fix the icon for the Cache panel
2017-06-16 10:44:58 -07:00
Javier Eguiluz
50c1d478ce [WebProfilerBundle] Fix the icon for the Cache panel 2017-06-16 10:44:56 -07:00
Fabien Potencier
c8884e7d9a bug #23052 [TwigBundle] Add Content-Type header for exception response (rchoquet)
This PR was merged into the 2.7 branch.

Discussion
----------

[TwigBundle] Add Content-Type header for exception response

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

This PR comes after I was looking to customize the way exceptions are served for a JSON API (grabbed the info at http://symfony.com/doc/current/controller/error_pages.html#overriding-the-default-exceptioncontroller).

I noticed that even when changing the request format to 'json' so that the right json.twig template is served:
```php
// in my override of the ExceptionController
public function showAction(Request $request, FlattenException $exception, DebugLoggerInterface $logger = null)
{
    $request->setRequestFormat('json');
    return parent::showAction($request, $exception, $logger);
}
```
the response Content-Type header was still 'text/html'.

By now, the response Content-Type should be corresponding to the given request format.

I also feel there's some room for improvement with the general "displaying error for a JSON API" chapter as it feels strange that there's no configuration option to just say "serve me anything as json", but that's another issue.

Commits
-------

9e2b408f25 add content-type header on exception response
2017-06-16 08:39:36 -07:00
Fabien Potencier
60e3a998d6 bug #23173 [WebServerBundle] Fix router script option BC (1ed)
This PR was merged into the 3.3 branch.

Discussion
----------

[WebServerBundle] Fix router script option BC

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23206
| License       | MIT
| Doc PR        | -

Server commands does not work with router script given by a relative path eg.:
```
bin/console server:run -r router.php
```
but, this was working before and was removed (by accident I guess) in https://github.com/symfony/symfony/pull/21039/files#diff-b915f83f99a4166eb34eab581a92501bL187

Commits
-------

aeab2fe1f7 [WebServerBundle] Fix router script path and check existence
2017-06-16 06:30:30 -07:00
Gábor Egyed
aeab2fe1f7 [WebServerBundle] Fix router script path and check existence 2017-06-16 15:28:11 +02:00
Iltar van der Berg
9e047122f1 Fixed composer resources between web/cli 2017-06-16 14:40:34 +02:00
Fabien Potencier
b8c94d03c2 bug #23199 Reset redirectCount when throwing exception (hvanoch)
This PR was merged into the 2.7 branch.

Discussion
----------

Reset redirectCount when throwing exception

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23197
| License       | MIT

When catching the exception throw when exceeding the redirect limit, all new request which results in a redirect fail. By resetting the redirectCount we can still use the same client instance.

Commits
-------

83fd578f96 Reset redirectCount when throwing exception
2017-06-15 07:57:21 -07:00
Fabien Potencier
d909592b2c bug #23180 [FrameworkBundle] Expose the AbstractController's container to its subclasses (BPScott)
This PR was merged into the 3.3 branch.

Discussion
----------

[FrameworkBundle] Expose the AbstractController's container to its subclasses

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

This is useful if an application provides their own base Controller that
references items in the container. It also makes it simpler for that
base controller to add additional optional dependencies by only overriding
getSubscribedServices instead of having to reimplement setContainer and
use ControllerTrait.

Commits
-------

ee17131fca Expose the AbstractController's container to its subclasses
2017-06-15 07:36:39 -07:00
Fabien Potencier
511905d417 bug #23186 [TwigBundle] Move template.xml loading to a compiler pass (ogizanagi)
This PR was merged into the 2.7 branch.

Discussion
----------

[TwigBundle] Move template.xml loading to a compiler pass

| Q             | A
| ------------- | ---
| Branch?       | 2.7 <!-- see comment below -->
| Bug fix?      | yes
| New feature?  | no <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass?   | yes
| Fixed tickets | #23181 <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

(failures unrelated)

Commits
-------

6ac0de8c2f [TwigBundle] Remove template.xml services when templating is disabled
2017-06-15 07:32:56 -07:00
Fabien Potencier
e1f2962cbe minor #23196 [Yaml] Fix typo: PARSE_KEYS_AS_STRING -> PARSE_KEYS_AS_STRINGS (meyerbaptiste)
This PR was merged into the 3.3 branch.

Discussion
----------

[Yaml] Fix typo: PARSE_KEYS_AS_STRING -> PARSE_KEYS_AS_STRINGS

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| 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
-------

f927ebadad [Yaml] Fix typo: PARSE_KEYS_AS_STRING -> PARSE_KEYS_AS_STRINGS
2017-06-15 07:27:50 -07:00
Henne Van Och
83fd578f96 Reset redirectCount when throwing exception 2017-06-15 15:33:54 +02:00
meyerbaptiste
f927ebadad [Yaml] Fix typo: PARSE_KEYS_AS_STRING -> PARSE_KEYS_AS_STRINGS 2017-06-15 14:58:50 +02:00
Ben Scott
ee17131fca Expose the AbstractController's container to its subclasses
Useful if an application provides their own base Controller that
references items in the container. It also makes it simpler for that
base controller to add additional optional dependencies by only overriding
getSubscribedServices instead of having to reimplement setContainer and
use ControllerTrait.
2017-06-15 13:29:56 +01:00
Maxime Steinhausser
6ac0de8c2f [TwigBundle] Remove template.xml services when templating is disabled 2017-06-15 13:54:31 +02:00
rchoquet
9e2b408f25 add content-type header on exception response 2017-06-15 11:47:56 +02:00
Fabien Potencier
3c2b1ff929 bug #23130 Keep s-maxage when expiry and validation are used in combination (mpdude)
This PR was merged into the 2.7 branch.

Discussion
----------

Keep s-maxage when expiry and validation are used in combination

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

(Symfony) docs say that [expiration wins over validation](https://symfony.com/doc/current/http_cache/validation.html). So,

a) when both the master and embedded response are public with an s-maxage, the result should be public as well and use the lower s-maxage of both, *also* in the case that the embedded response carries validation headers. (The cache may use those for revalidating the embedded response once it has become stale, but that does not impact expiration-based caching of the combined response.)

b) when both the master and embedded response are public with an s-maxage, the result should be public as well and use the lower s-maxage of both, *also* in the case that the master response carries validation headers. However, those *must not* be passed on to the client: They do not apply to the combined response, but may only be used by the cache itself to revalidate the (raw) master response.

Commits
-------

09bcbc70e7 Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response
2017-06-14 15:21:38 -07:00
Matthias Pigulla
09bcbc70e7 Embedding a response that combines expiration and validation, that should not defeat expiration on the combined response 2017-06-14 23:57:46 +02:00
Fabien Potencier
8dc00bbe8d fixed bad merge 2017-06-14 14:54:47 -07:00
Fabien Potencier
551e5ba515 bug #23129 Fix two edge cases in ResponseCacheStrategy (mpdude)
This PR was squashed before being merged into the 2.7 branch (closes #23129).

Discussion
----------

Fix two edge cases in ResponseCacheStrategy

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

While reviewing how `ResponseCacheStrategy` calculates the caching-related headers for responses that embed subrequests, I came across two cases that I think are currently implemented incorrectly.

a) When the main response is public and cacheable with an expiration time, but it embeds (via ESI) a controller that does not set any caching-related headers, this embedded response is more constrained. So, the resulting (combined) response must not be cacheable, especially it may not keep the s-maxage.

b) When the main response is public and cacheable with an expiration time, but it embeds (via ESI) a controller that explicitly creates a "private" response, the resulting (combined) response must be private as well.

Commits
-------

c6e8c07e4d Fix two edge cases in ResponseCacheStrategy
2017-06-14 14:29:16 -07:00
Matthias Pigulla
c6e8c07e4d Fix two edge cases in ResponseCacheStrategy 2017-06-14 14:29:14 -07:00
Fabien Potencier
814b43e510 feature #22636 [Routing] Expose request in route conditions, if needed and possible (ro0NL)
This PR was squashed before being merged into the 2.7 branch (closes #22636).

Discussion
----------

[Routing] Expose request in route conditions, if needed and possible

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #16968, #22635
| License       | MIT
| Doc PR        | -

given

```
/**
 * @Route("/", name="homepage", condition="request.isXmlHttpRequest()")
 */
```

```
$ app/console route:match /
```

before

![image](https://cloud.githubusercontent.com/assets/1047696/25716808/b9ab518e-3100-11e7-8b59-21351b5c14ca.png)

after

![image](https://cloud.githubusercontent.com/assets/1047696/25716833/d08065fc-3100-11e7-9462-987b2c6eaa26.png)

Commits
-------

94371d052b [Routing] Expose request in route conditions, if needed and possible
2017-06-14 14:11:23 -07:00
Roland Franssen
94371d052b [Routing] Expose request in route conditions, if needed and possible 2017-06-14 14:11:20 -07:00
Fabien Potencier
f392282984 bug #22636 [Routing] Expose request in route conditions, if needed and possible (ro0NL)
This PR was squashed before being merged into the 2.7 branch (closes #22636).

Discussion
----------

[Routing] Expose request in route conditions, if needed and possible

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #16968, #22635
| License       | MIT
| Doc PR        | -

given

```
/**
 * @Route("/", name="homepage", condition="request.isXmlHttpRequest()")
 */
```

```
$ app/console route:match /
```

before

![image](https://cloud.githubusercontent.com/assets/1047696/25716808/b9ab518e-3100-11e7-8b59-21351b5c14ca.png)

after

![image](https://cloud.githubusercontent.com/assets/1047696/25716833/d08065fc-3100-11e7-9462-987b2c6eaa26.png)

Commits
-------

016e976691 [Routing] Expose request in route conditions, if needed and possible
2017-06-14 13:57:27 -07:00
Roland Franssen
016e976691 [Routing] Expose request in route conditions, if needed and possible 2017-06-14 13:57:25 -07:00
Fabien Potencier
01057875dd fixed tests 2017-06-14 13:33:13 -07:00
Fabien Potencier
7b827ce823 Merge branch '3.2' into 3.3
* 3.2:
  [SecurityBundle] Move cache of the firewall context into the request parameters
  Fix Usage with anonymous classes
  [Workflow] Added more keywords in the composer.json
  [Cache] APCu isSupported() should return true when apc.enable_cli=Off
  [PropertyAccess] Do not silence TypeErrors from client code.
2017-06-14 13:33:09 -07:00
Fabien Potencier
dddc5bde5b bug #22943 [SecurityBundle] Move cache of the firewall context into the request parameters (GromNaN)
This PR was squashed before being merged into the 3.2 branch (closes #22943).

Discussion
----------

[SecurityBundle] Move cache of the firewall context into the request parameters

Following [this proposal](https://github.com/symfony/symfony/pull/22605#issuecomment-301276639). Since the matching context relates to the request, this information should have been cached inside the request parameters.

| Q             | A
| ------------- | ---
| Branch?       | 3.2
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #22605
| License       | MIT
| Doc PR        | n/a

* Avoid memory leak when handling multiple requests
* Adding the new request parameter `_firewall_context` might be considered as a breaking change. That adds a new "public" property that could be used by end developers.

Commits
-------

b3203cb8ab [SecurityBundle] Move cache of the firewall context into the request parameters
2017-06-14 13:22:28 -07:00