Commit Graph

10002 Commits

Author SHA1 Message Date
Samuel ROZE
f59ce97eff feature #27128 [Messenger] Middleware factories support in config (ogizanagi)
This PR was squashed before being merged into the 4.1 branch (closes #27128).

Discussion
----------

[Messenger] Middleware factories support in config

| Q             | A
| ------------- | ---
| Branch?       | master <!-- see below -->
| Bug fix?      | no
| New feature?  | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no  <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | todo

Following https://github.com/symfony/symfony/pull/26864, this would allow to configure easily the middlewares by using an abstract factory definition to which are provided simple arguments (just scalars, no services references).

For instance, here is how the DoctrineBundle would benefit from such a feature (also solving the wiring of the `DoctrineTransactionMiddleware` reverted in https://github.com/symfony/symfony/pull/26684):

```yaml
framework:
    messenger:
      buses:
        default:
          middleware:
            - logger
            - doctrine_transaction_middleware: ['entity_manager_name']
```

where `doctrine_transaction_middleware` would be an abstract factory definition provided by the doctrine bundle:

```yml
services:

    doctrine.orm.messenger.middleware_factory.transaction:
      class: Symfony\Bridge\Doctrine\Messenger\DoctrineTransactionMiddlewareFactory
      arguments: ['@doctrine']

    doctrine_transaction_middleware:
      class: Symfony\Bridge\Doctrine\Messenger\DoctrineTransactionMiddleware
      factory: ['@doctrine.orm.messenger.middleware_factory.transaction', 'createMiddleware']
      abstract: true
      # the default arguments to use when none provided from config.
      # i.e:
      #   middlewares:
      #     - doctrine_transaction_middleware: ~
      arguments: ['default']
```

and is interpreted as:

```yml
buses:
    default:
        middleware:
            -
                id: logger
                arguments: {  }
            -
                id: doctrine_transaction_middleware
                arguments:
                    - entity_manager_name
        default_middleware: true
```

---

<details>

<summary>Here is the whole config reference with these changes: </summary>

```yaml
# Messenger configuration
messenger:
    enabled:              true
    routing:

        # Prototype
        message_class:
            senders:              []
    serializer:
        enabled:              true
        format:               json
        context:

            # Prototype
            name:                 ~
    encoder:              messenger.transport.serializer
    decoder:              messenger.transport.serializer
    adapters:

        # Prototype
        name:
            dsn:                  ~
            options:              []
    default_bus:          null
    buses:

        # Prototype
        name:
            default_middleware:  true
            middleware:

                # Prototype
                -
                    id:                   ~ # Required
                    arguments:            []
```

</details>

Commits
-------

f5ef421474 [Messenger] Middleware factories support in config
2018-05-14 20:17:15 +01:00
Maxime Steinhausser
f5ef421474 [Messenger] Middleware factories support in config 2018-05-14 20:17:01 +01:00
Maxime Steinhausser
d52f491bfa [Profiler] Remove propel & event_listener_loading category identifiers 2018-05-14 18:07:30 +02:00
Gabriel Ostrolucký
16ebb43bd4 Disallow illegal characters like "." in session.name
PHP saves cookie with correct name, but upon deserialization to
$_COOKIE, it replaces some characters, e.g. "." becomes "_".

This is probably also reason why \SessionHandler is not able to find
a session.

https://harrybailey.com/2009/04/dots-arent-allowed-in-php-cookie-names/
https://bugs.php.net/bug.php?id=75883
2018-05-13 23:57:04 +02:00
Fabien Potencier
8335537446 feature #27202 [Messenger] Improve the profiler panel (ogizanagi)
This PR was squashed before being merged into the 4.1 branch (closes #27202).

Discussion
----------

[Messenger] Improve the profiler panel

| Q             | A
| ------------- | ---
| Branch?       | 4.1 <!-- see below -->
| Bug fix?      | no
| New feature?  | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A   <!-- #26597  issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

This is an attempt to enhance the profiler panel a bit.

**with the following messages dispatched:**

```php
$queryBus->dispatch(Envelope::wrap(new GetGreetingsQuery('Hello you'))
    ->with(new JustAFriendOfMine())
    ->with(new AndHisPlusO̶n̶e̶Eleven())
);
$commandBus->dispatch(new SendGiftCommand());
$queryBus->dispatch(new GetGreetingsQuery('Exterminate!'));
```

## Before

<img width="1084" alt="screenshot 2018-05-12 a 13 57 57" src="https://user-images.githubusercontent.com/2211145/39957055-8a0f009e-55ec-11e8-9d8e-bf79aad4b420.PNG">

🐛calls order are wrong here, fixed in this PR

## After

### collapsed

<!-- <img width="1083" alt="screenshot 2018-05-10 a 23 51 07" src="https://user-images.githubusercontent.com/2211145/39896093-19a8c7ee-54ad-11e8-8dcb-4e165ffd2eae.PNG">-->

<img width="1085" alt="screenshot 2018-05-12 a 13 18 35" src="https://user-images.githubusercontent.com/2211145/39956802-9d4c38a2-55e7-11e8-8425-ad090c0871b6.PNG">
<img width="1085" alt="screenshot 2018-05-12 a 13 26 44" src="https://user-images.githubusercontent.com/2211145/39956827-25d9e426-55e8-11e8-9116-160603649f33.PNG">

📝 _When loading the page, all messages details are collapsed by default but the first one per tab._

### expanded

<!-- <img width="1083" alt="screenshot 2018-05-10 a 23 13 39" src="https://user-images.githubusercontent.com/2211145/39894779-42c9cc9a-54a8-11e8-9529-6292481536d4.PNG"> -->

<img width="1086" alt="screenshot 2018-05-12 a 13 49 42" src="https://user-images.githubusercontent.com/2211145/39956981-639fc3d6-55eb-11e8-9224-a48f591db3da.PNG">

### live

<!-- ![mai-10-2018 23-16-17](https://user-images.githubusercontent.com/2211145/39894789-4b8fa138-54a8-11e8-986c-fccf6cd0234f.gif) -->

![mai-12-2018 13-55-40](https://user-images.githubusercontent.com/2211145/39957041-37f17b34-55ec-11e8-8569-a733a104bf82.gif)

### toolbar (with exceptions)

<img width="284" alt="screenshot 2018-05-10 a 23 18 32" src="https://user-images.githubusercontent.com/2211145/39895011-0467f2a0-54a9-11e8-9d78-25461cf71c41.PNG">

## Notes

- Table headers are clickable, so you can jump directly to the message class in the code
- Reversing headers/rows allows to have a wider space for dumps and allows to add more entries in the future. This is an issue we already have with the Validator panel (when there is both an invalid value as object and a constraint violation dumped) which I'd like to revamp soon.
- ~~I wonder if we should keep the dispatched messages in call order, or if we can segregate by bus (using tabs?).~~
- ~~we could add a left container listing messages classes only, allowing to show details of a single message dispatched on a right container (similar to what the Form panel does). I'll probably suggest the same for the Validator panel.~~

Commits
-------

3d19578297 [Messenger] Improve the profiler panel
2018-05-13 08:14:37 +02:00
Maxime Steinhausser
3d19578297 [Messenger] Improve the profiler panel 2018-05-13 08:14:09 +02:00
Fabien Potencier
4f3afd53a8 fixed CS 2018-05-11 17:58:37 +02:00
Fabien Potencier
f5e6a61a82 Merge branch '3.4' into 4.0
* 3.4:
  fixed CS
  fixed CS
  [FrameworkBundle] Fix cache:clear on vagrant
  [HttpKernel] Handle NoConfigurationException "onKernelException()"
  Fix misses calculation when calling getItems
  Fixed return type
2018-05-11 17:53:11 +02:00
Fabien Potencier
df43c1e99d fixed CS 2018-05-11 17:51:28 +02:00
Nicolas Grekas
3381611d86 [FrameworkBundle] Fix cache:clear on vagrant 2018-05-11 08:27:29 -07:00
Kevin Bond
fa4ce7bbc4
[Messenger] remove autoconfiguration for Sender/ReceiverInterface 2018-05-11 08:48:51 -04:00
Tobias Schultze
497ce74f9e bug #27229 [Messenger] Rename tag attribute "name" by "alias" (yceruto)
This PR was merged into the 4.1 branch.

Discussion
----------

[Messenger] Rename tag attribute "name" by "alias"

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

As "name" is a reserved attribute in YAML and XML schema it makes impossible to register manually a custom Sender or Receiver with another "name" attribute.

> The file ".../demos/messenger-flex/config/services.yaml" does not contain valid YAML.
Duplicate key "name" detected at line 30 (near "- { name: 'messenger.receiver', name: 'mail' }").

Commits
-------

1ef27a7e6a Rename tag attribute "name" by "alias"
2018-05-11 11:17:32 +02:00
Yonel Ceruto
1ef27a7e6a Rename tag attribute "name" by "alias" 2018-05-10 17:13:07 -04:00
Yonel Ceruto
6295879a30 Autoconfiguring TransportFactoryInterface classes 2018-05-10 13:03:14 -04:00
Samuel ROZE
ebbe1adebc minor #27206 [Messenger] Add more tests around the AMQP transport (sroze)
This PR was merged into the 4.1 branch.

Discussion
----------

[Messenger] Add more tests around the AMQP transport

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

Adding more tests to the AMQP transport/factory. These should have captured the following 3 bugs: #27198, #27197, #27196.

Commits
-------

faf9382223 Add more tests around the AMQP transport
2018-05-10 08:14:28 +01:00
Fabien Potencier
1403112de1 bug #27209 [Workflow] add is deprecated since Symfony 4.1. Use addWorkflow() instead (xkobal)
This PR was squashed before being merged into the 4.1 branch (closes #27209).

Discussion
----------

[Workflow] add is deprecated since Symfony 4.1. Use addWorkflow() instead

| Q             | A
| ------------- | ---
| Branch?       | 4.1
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #...
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Commits
-------

ffa5d1ca94 [Workflow] add is deprecated since Symfony 4.1. Use addWorkflow() instead
2018-05-09 17:27:38 +02:00
Xavier HAUSHERR
ffa5d1ca94 [Workflow] add is deprecated since Symfony 4.1. Use addWorkflow() instead 2018-05-09 17:27:28 +02:00
Samuel ROZE
cb2a77b24b Merge branch '4.1'
* 4.1:
  [Messenger][DX] Uses a default receiver when only one is defined
  fix deps
  [Profiler] Join using ';\n'
  Rename the command `DebugCommand`
  [Messenger] Add debug:messenger CLI command
  [Messenger] Fix default bus name
  Fix the transport factory after moving it
  [Messenger] Fix AMQP Transport factory & TransportFactoryInterface
  Fix AmqpTransport
  [Profiler] Fix dump makes toolbar disappear
  Improved exception on invalid message type
  bumped Symfony version to 4.1.0
  updated VERSION for 4.1.0-BETA1
  updated CHANGELOG for 4.1.0-BETA1
  [Messenger] Add TransportInterface as first class citizen sender+receiver
2018-05-09 15:43:48 +01:00
Samuel ROZE
e0f225bd85 minor #27203 [Messenger][DX] Uses a default receiver when only one is defined (sroze)
This PR was squashed before being merged into the 4.1 branch (closes #27203).

Discussion
----------

[Messenger][DX] Uses a default receiver when only one is defined

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

When using only one receiver, as a developer, it makes no sense for me to have to precise the receiver name when using the `messenger:consume-messages` command. This is the change:

```patch
- bin/console messenger:consume-messages default
+ bin/console messenger:consume-messages
```

If I have more than one transport configured, I'll get the following message:

>
>  You have 0 or more than one receiver (no default have been found). You need to specify the receiver name with an argument.
>

Commits
-------

8315b868d5 [Messenger][DX] Uses a default receiver when only one is defined
2018-05-09 15:41:23 +01:00
Samuel ROZE
8315b868d5 [Messenger][DX] Uses a default receiver when only one is defined 2018-05-09 15:41:15 +01:00
Samuel ROZE
6207d70964 feature #26803 [Messenger] Add debug:messenger CLI command (ro0NL, sroze)
This PR was merged into the 4.1 branch.

Discussion
----------

[Messenger] Add debug:messenger CLI command

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Adds a `debug:messenger` CLI command to expose message classes that can be dispatched. Heavily inspired by `debug:autowiring`.

Commits
-------

7f87309c10 fix deps
290c7eb1bc Rename the command `DebugCommand`
9847b83723 [Messenger] Add debug:messenger CLI command
2018-05-09 15:39:20 +01:00
Roland Franssen
7f87309c10 fix deps 2018-05-09 13:47:01 +02:00
Maxime Steinhausser
09987102a8 [Profiler] Join using ';\n' 2018-05-09 13:16:14 +02:00
Samuel ROZE
290c7eb1bc Rename the command DebugCommand 2018-05-09 09:31:45 +01:00
Roland Franssen
9847b83723 [Messenger] Add debug:messenger CLI command 2018-05-09 09:27:25 +01:00
Samuel ROZE
faf9382223 Add more tests around the AMQP transport 2018-05-09 09:02:39 +01:00
Fabien Potencier
9b841d969c bug #27189 [Profiler] Fix dump makes toolbar disappear (ogizanagi)
This PR was merged into the 4.1 branch.

Discussion
----------

[Profiler] Fix dump makes toolbar disappear

| Q             | A
| ------------- | ---
| Branch?       | 4.1 <!-- see below -->
| Bug fix?      | yes
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #27180   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

Don't know if there is a better solution than executing eval on the global scope.

For ref: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/eval
> If you use the eval function indirectly, by invoking it via a reference other than eval, as of ECMAScript 5 it works in the global scope rather than the local scope. This means, for instance, that function declarations create global functions, and that the code being evaluated doesn't have access to local variables within the scope where it's being called.

Commits
-------

0cd51ae267 [Profiler] Fix dump makes toolbar disappear
2018-05-09 08:02:10 +02:00
Fabien Potencier
796c8fed1e bug #27199 [Messenger] Fix default bus name (ogizanagi)
This PR was merged into the 4.1 branch.

Discussion
----------

[Messenger] Fix default bus name

| Q             | A
| ------------- | ---
| Branch?       | 4.1 <!-- see below -->
| Bug fix?      | yesish
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #27162   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

After #27162, the default bus name configured automatically should use a full service id too, otherwise we currently get a `default` service id, no namespace identifier, which is the default bus.

Commits
-------

fa9b9849b1 [Messenger] Fix default bus name
2018-05-09 08:01:16 +02:00
Maxime Steinhausser
fa9b9849b1 [Messenger] Fix default bus name 2018-05-08 18:02:52 +02:00
Samuel ROZE
7a091d9d61 Fix the transport factory after moving it 2018-05-08 16:44:19 +01:00
Maxime Steinhausser
0cd51ae267 [Profiler] Fix dump makes toolbar disappear 2018-05-08 14:38:48 +02:00
Fabien Potencier
016d556262 updated version to 4.2 2018-05-07 16:51:25 +02:00
Nicolas Grekas
379b8eb56b [Messenger] Add TransportInterface as first class citizen sender+receiver 2018-05-07 07:49:40 -07:00
Samuel ROZE
9ae7c11805 Do not fix the middleware XML name anymore 2018-05-07 13:39:55 +01:00
Fabien Potencier
52e7500edb removed usage of middlewares 2018-05-07 13:37:49 +02:00
Maxime Steinhausser
e7cfb59480 [Messenger] Fix missing s/tolerate_no_handler/allow_no_handler/g 2018-05-07 11:41:32 +02:00
Fabien Potencier
9d5f50d7b6 bug #27162 [FrameworkBundle][Messenger] Remove convention-based service id generation for buses (nicolas-grekas)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle][Messenger] Remove convention-based service id generation for buses

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

Service ids for buses are user facing ids: ppl *will* have to deal with them when wiring their services.
Like for cache pools, we should ask ppl to declare them using full identifiers, instead of having a convention-based way to turn a name into and id (which is something nobody will be able to remember at some point.)

Commits
-------

c7a0045cbd [FrameworkBundle][Messenger] Remove convention-based service id generation for buses
2018-05-07 10:35:29 +02:00
Fabien Potencier
07ea1bb6f3 Merge branch '4.0'
* 4.0:
  fixed bad merge
2018-05-07 10:32:19 +02:00
Fabien Potencier
cb06e2a6fb fixed bad merge 2018-05-07 10:32:11 +02:00
Fabien Potencier
c53541f0ef bug #27084 [Messenger] Relax messenger config and fix some bugs (yceruto)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Messenger] Relax messenger config and fix some bugs

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

After playing a little with the config of this component I found some bugs around.

Reproducer:

 1. Install a fresh Symfony flex project with `^4.0@dev` dependencies
 2. Add the `symfony/messenger` requirement
 3. Add the following configuration separately:

Note that `symfony/serializer` has not been installed yet. ATM it's not required.

----------------------

Configuring my custom transport (not amqp):
```yaml
framework:
    messenger:
        transports:
            custom: 'my_transport://localhost/msgs'
        routing:
            '*': custom
```

**Before**  (Current behaviour):
Threw a logic exception, IMO unrelated at this point:
> Using the default encoder/decoder, Symfony Messenger requires the Serializer. Enable it or install it by running "composer require symfony/serializer-pack".

**After** (Proposal):
Pass! The Messenger's serializer config is disabled by definition because the Serializer component is not installed yet, then the related (default) encoder/decoder aliases are invalid, so the amqp transport factory service is removed altogether.

----------------------

According to the previous exception I configured my custom encoder/decoder services:
```yaml
framework:
    messenger:
        encoder: App\Serializer\Serializer
        decoder: App\Serializer\Serializer
        transports:
            custom: 'my_transport://localhost/msgs'
        routing:
            '*': custom
```

**Before**:
The same exception has been thrown, now a bit vague according to the config:
> Using the default encoder/decoder, Symfony Messenger requires the Serializer. Enable it or install it by running "composer require symfony/serializer-pack".

**After**:
Pass! the serializer is disabled by definition but there is custom encoder/decoder services, so let's keep the amqp transport factory with their custom encoder/decoder deps.

----------------------

Just enabling the serializer option:
```yaml
framework:
    messenger:
        serializer: true
```

**Before**:
Pass! Unexpected, as there is no transport configuration the exception wasn't thrown and still keeps the amqp transport factory service with invalid encoder/decoder (Serializer) dependencies.

**After**:
The Serializer config & support is verified if it's enabled regardless of the transport configuration and this exception is thrown for this case:
> The default Messenger serializer cannot be enabled as the Serializer support is not enabled.

I've removed the "install" part because at this point only we're checking whether the `framework.serializer` is enabled or not, so the next step after that should be enable the Serializer support in `framework.serializer`, which already verify whether the Serializer component is installed or not. IMO "composer require symfony/serializer-pack" should be there and not here. Also because `symfony/serializer` is not a hard dependency of this component.

----------------------

By last, I disabled the serializer option manually:
```yaml
framework:
    messenger:
        serializer: false
        transports:
            custom: 'my_transport://localhost/msgs'
        routing:
            '*': custom
```

**Before**:
I received this DI exception:
> The service "messenger.transport.amqp.factory" has a dependency on a non-existent service "messenger.transport.serializer".

**After**:
Pass! (same behaviour that the first example)

----------------------

As I explained earlier, this PR enables or disables the Messenger's serializer config based on the current Symfony platform and whether the Serializer component is installed or not, like other config with similar behaviour.

Tests included :)

Cheers!

Commits
-------

a05e2e2c3b Relax Messenger config and fix some bugs
2018-05-07 10:11:33 +02:00
Fabien Potencier
8123bb102b Merge branch '4.0'
* 4.0:
  use brace-style regex delimiters
  Fixed typo RecursiveIterator -> RecursiveIteratorIterator
  [Cache] fix logic for fetching tag versions on TagAwareAdapter
  [FrameworkBundle] Remove dead code
  [FrameworkBundle] Use the correct service id for CachePoolPruneCommand in its compiler pass
  Hide short exception trace by default
  [Doctrine Bridge] fix priority for doctrine event listeners
  [Validator] make phpdoc of ObjectInitializerInterface interface more accurate
  [Validator] fixes phpdoc reference to an interface that was removed in Symfony 3.0
2018-05-07 09:14:12 +02:00
Fabien Potencier
956c2f8091 Merge branch '3.4' into 4.0
* 3.4:
  use brace-style regex delimiters
  Fixed typo RecursiveIterator -> RecursiveIteratorIterator
  [Cache] fix logic for fetching tag versions on TagAwareAdapter
  [FrameworkBundle] Use the correct service id for CachePoolPruneCommand in its compiler pass
  Hide short exception trace by default
  [Doctrine Bridge] fix priority for doctrine event listeners
  [Validator] make phpdoc of ObjectInitializerInterface interface more accurate
  [Validator] fixes phpdoc reference to an interface that was removed in Symfony 3.0
2018-05-07 09:12:24 +02:00
Nicolas Grekas
c7a0045cbd [FrameworkBundle][Messenger] Remove convention-based service id generation for buses 2018-05-06 08:37:23 -07:00
Yonel Ceruto
a05e2e2c3b Relax Messenger config and fix some bugs 2018-05-06 10:57:10 -04:00
Javier Eguiluz
d27b158e4f Show the deprecations tab by default in the logger panel 2018-05-06 12:05:18 +02:00
Nicolas Grekas
278f40f48d bug #27143 [Console] By default hide the short exception trace line from exception messages in Symfony's commands (yceruto)
This PR was merged into the 3.4 branch.

Discussion
----------

[Console] By default hide the short exception trace line from exception messages in Symfony's commands

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

After https://github.com/symfony/symfony/pull/24131 this was in my contribution list since then.

Maybe it should be taken as a good practice when we build console commands, **use the exception classes of the Console component as much as possible to show a better message style to the end user**.

(See the before/after effect in the referenced PR)

Commits
-------

11f3c455d4 Hide short exception trace by default
2018-05-04 10:44:42 -07:00
Nicolas Grekas
cada38f520 minor #27144 [FrameworkBundle] Hide some lock-related services (nicolas-grekas)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] Hide some lock-related services

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

I don't know why, but I missed these in #26921

Commits
-------

d06d8b2573 [FrameworkBundle] Hide some lock-related services
2018-05-04 10:30:57 -07:00
Robin Chalas
29b3e31382 [FrameworkBundle] Remove dead code 2018-05-04 16:54:39 +02:00
Christian Flothmann
ffb19e9518 replace remaining adapters with transports 2018-05-04 11:13:11 +02:00
Nicolas Grekas
d06d8b2573 [FrameworkBundle] Hide some lock-related services 2018-05-03 18:14:10 -07:00
Nicolas Grekas
47da23c7cb minor #27129 [Messenger] Rename Adapters to Transports (sroze)
This PR was squashed before being merged into the 4.1-dev branch (closes #27129).

Discussion
----------

[Messenger] Rename Adapters to Transports

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

Last of our tasks on the "plan to beta", renaming "adapters" to "transports". This is a term that makes more sense and is commonly used within the "queue community".

Commits
-------

13b747565f [Messenger] Rename Adapters to Transports
2018-05-03 17:10:25 -07:00
Samuel ROZE
13b747565f [Messenger] Rename Adapters to Transports 2018-05-03 17:09:35 -07:00
Nicolas Grekas
ce7f9bccdf minor #27123 [DebugBundle][HttpKernel] Update var-dumper requirement for components using SourceContextProvider (jvasseur)
This PR was squashed before being merged into the 4.1-dev branch (closes #27123).

Discussion
----------

[DebugBundle][HttpKernel] Update var-dumper requirement for components using SourceContextProvider

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

The DebugBundle is using the SourceContextProvider class that was introduced in v4.1

Commits
-------

b0b9060237 [DebugBundle][HttpKernel] Update var-dumper requirement for components using SourceContextProvider
2018-05-03 17:01:38 -07:00
Jérôme
b0b9060237 [DebugBundle][HttpKernel] Update var-dumper requirement for components using SourceContextProvider 2018-05-03 17:01:20 -07:00
Bert Hekman
32c7ee35be [FrameworkBundle] Use the correct service id for CachePoolPruneCommand in its compiler pass 2018-05-03 16:57:56 -07:00
Yonel Ceruto
11f3c455d4 Hide short exception trace by default 2018-05-03 19:18:14 -04:00
Fabien Potencier
6cb90daa76 feature #27104 [DX] Redirect to proper Symfony version documentation (noniagriconomie)
This PR was squashed before being merged into the 4.1-dev branch (closes #27104).

Discussion
----------

[DX] Redirect to proper Symfony version documentation

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

Just a small improvement
I think this can make some dev target the right documentation instead of reading an other version that the one they are developing on

EDIT: I do not know if including the constant directly is the good choice, or it is better to add a global symfony version collector?

Commits
-------

d611160ec6 [DX] Redirect to proper Symfony version documentation
2018-05-03 08:29:40 +02:00
Antoine M
d611160ec6 [DX] Redirect to proper Symfony version documentation 2018-05-03 08:29:31 +02:00
Nicolas Grekas
e6f99da5ca bug #26955 [DebugBundle][VarDumper] Fix server dumper placeholder command (ogizanagi)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[DebugBundle][VarDumper] Fix server dumper placeholder command

| Q             | A
| ------------- | ---
| Branch?       | master <!-- see below -->
| Bug fix?      | no, fixes a deprecation warning
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no, fixes ones <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26944 <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

This placeholder command was addressed in quite an unorthodox fashion and the following fix isn't really better, but I guess that's fine for an internal class.

_As a reminder: this command aims to favor discoverability of the `ServerDumpCommand` when listing available commands and by exposing its definition so you can read about it by using `--help`. Execution hints about the `debug.dump_destination` config option required to wire the actual command._

That's the only command for which we're doing this, though. So better keep this placeholder or drop it?

Commits
-------

60af39b161 [DebugBundle][VarDumper] Fix server dumper placeholder command
2018-05-01 16:13:51 -07:00
Nicolas Grekas
7183c59c20 Merge branch '4.0'
* 4.0:
  Remove symfony/polyfill-ctype where not needed
  Use symfony/polyfill-ctype
  [Form] fixes instance variable phpdoc in FormRegistry class
  bumped Symfony version to 4.0.10
  updated VERSION for 4.0.9
  updated CHANGELOG for 4.0.9
  bumped Symfony version to 3.4.10
  updated VERSION for 3.4.9
  updated CHANGELOG for 3.4.9
2018-05-01 16:02:13 -07:00
Nicolas Grekas
a488d555ff Merge branch '3.4' into 4.0
* 3.4:
  Remove symfony/polyfill-ctype where not needed
  Use symfony/polyfill-ctype
  [Form] fixes instance variable phpdoc in FormRegistry class
  bumped Symfony version to 3.4.10
  updated VERSION for 3.4.9
  updated CHANGELOG for 3.4.9
  Add CODE_OF_CONDUCT.md
  Added .github/CODEOWNERS
  bumped Symfony version to 2.8.40
  updated VERSION for 2.8.39
  updated CHANGELOG for 2.8.39
2018-05-01 16:00:51 -07:00
Nicolas Grekas
e525248f66 Merge branch '2.8' into 3.4
* 2.8:
  Remove symfony/polyfill-ctype where not needed
  Use symfony/polyfill-ctype
  [Form] fixes instance variable phpdoc in FormRegistry class
2018-05-01 15:53:27 -07:00
Nicolas Grekas
087c667b83 Merge branch '2.7' into 2.8
* 2.7:
  Remove symfony/polyfill-ctype where not needed
  Use symfony/polyfill-ctype
  [Form] fixes instance variable phpdoc in FormRegistry class
2018-05-01 15:52:40 -07:00
Gert de Pagter
afc09cc8a7 Use symfony/polyfill-ctype
Use the polyfill for every package that uses cytpe functions.
2018-05-01 15:30:49 -07:00
Nicolas Grekas
e548b28b81 Merge branch '4.0'
* 4.0:
  [Debug][WebProfilerBundle] Fix setting file link format
  [Debug] Fixed the formatPath when a custom fileLinkFormat is defined
2018-04-30 10:00:18 -07:00
Nicolas Grekas
59298a9271 Merge branch '3.4' into 4.0
* 3.4:
  [Debug][WebProfilerBundle] Fix setting file link format
  [Debug] Fixed the formatPath when a custom fileLinkFormat is defined
2018-04-30 09:59:37 -07:00
Nicolas Grekas
a4a1645d44 [Debug][WebProfilerBundle] Fix setting file link format 2018-04-30 09:54:07 -07:00
Robin Chalas
e224548a0f [SecurityBundle] Fix framework-bundle dev requirement 2018-04-30 18:23:52 +02:00
Robin Chalas
c93c9a5880 [SecurityBundle] Fix test 2018-04-30 18:12:47 +02:00
Nicolas Grekas
8c0199e66b Merge branch '4.0'
* 4.0:
  PhpDoc: There is no attempt to create the directory
  Avoiding an error when an unused service has a missing base class
  Add an implementation just for php 7.0
  bumped Symfony version to 2.7.47
  Fix #27011: Session ini_set bug
  [Cache] TagAwareAdapterInterface::invalidateTags() should commit deferred items
  updated VERSION for 2.7.46
  update CONTRIBUTORS for 2.7.46
  updated CHANGELOG for 2.7.46
  bug #25844 [HttpKernel] Catch HttpExceptions when templating is not installed
2018-04-29 18:07:08 -07:00
Nicolas Grekas
ca0f0cf351 Merge branch '3.4' into 4.0
* 3.4:
  PhpDoc: There is no attempt to create the directory
  Avoiding an error when an unused service has a missing base class
  Add an implementation just for php 7.0
  bumped Symfony version to 2.7.47
  Fix #27011: Session ini_set bug
  [Cache] TagAwareAdapterInterface::invalidateTags() should commit deferred items
  updated VERSION for 2.7.46
  update CONTRIBUTORS for 2.7.46
  updated CHANGELOG for 2.7.46
  bug #25844 [HttpKernel] Catch HttpExceptions when templating is not installed
2018-04-29 18:05:59 -07:00
Nicolas Grekas
50a59c0488 feature #26655 [WebProfilerBundle] Make WDT follow ajax requests if header set (jeffreymb)
This PR was squashed before being merged into the 4.1-dev branch (closes #26655).

Discussion
----------

[WebProfilerBundle] Make WDT follow ajax requests if header set

Replaces #22509. I accidentally closed that PR and couldn't get GitHub to recognize when I added more commits to the branch in my fork.

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes <!-- don't forget updating src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget updating UPGRADE-*.md files -->
| Tests pass?   | yes (There are no tests that I could find)
| Fixed tickets | #15456
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!--highly recommended for new features-->

When the header of an ajax response contains the `Symfony-Debug-Toolbar-Replace` header with a value of '1' it will automatically update the toolbar with the toolbar with the debug info from the ajax request.

The bulk of the code in the `loadToolbar` function in the `base_js.html.twig` file is moved from the `toolbar_js.html.twig` file and slightly refactored to use the internal functions instead of making external calls. I take no credit/blame for this code. 😉

If this could make it into 4.1 there are multiple people that would be very happy!

Commits
-------

e4e591b [WebProfilerBundle] Make WDT follow ajax requests if header set
2018-04-29 09:29:55 +02:00
Jeffrey Brubaker
e4e591b46b [WebProfilerBundle] Make WDT follow ajax requests if header set 2018-04-29 09:29:44 +02:00
Nicolas Grekas
d843181bf6 minor #27063 [Translator] Further postpone adding resource files (nicolas-grekas)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Translator] Further postpone adding resource files

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

Commits
-------

2aa62df [Translator] Further postpone adding resource files
2018-04-29 08:06:02 +02:00
Nicolas Grekas
ff19a041ef minor #27083 [Messenger] Restore wildcard support in routing (yceruto)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Messenger] Restore wildcard support in routing

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

Also fixing some CS warnings and code structure.

Commits
-------

35317ac Restore wildcard support in routing
2018-04-29 07:57:19 +02:00
Nicolas Grekas
e902caae2f feature #27062 [SecurityBundle] Register a UserProviderInterface alias if one provider only (sroze)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[SecurityBundle] Register a `UserProviderInterface` alias if one provider only

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

When using only one user provider (as in most of the cases), it will register an alias for the `UserProviderInterface` interface and allow auto-wiring of it.

Commits
-------

4cbddd8 Register a `UserProviderInterface` alias if one provider only
2018-04-29 07:49:46 +02:00
Yonel Ceruto
35317ac987 Restore wildcard support in routing 2018-04-28 08:03:41 -04:00
Tobias Schultze
39c7c90a96 minor #27032 [Messenger][DX] Validate that the message exists to be able to configure its routing (sroze)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Messenger][DX] Validate that the message exists to be able to configure its routing

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

It attempted to me already: mispelling the message name and not understanding why it didn't work... An exception letting me know that the configured message does not exists will be 👌

Commits
-------

04d87ca829 Validate that the message exists to be able to configure its routing Uses an existing class in the tests... :) Only trigger the autoloading once
2018-04-27 01:34:37 +02:00
Tobias Schultze
ee0967f0ea feature #26975 [Messenger] Add a memory limit option for ConsumeMessagesCommand (sdelicata)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Messenger] Add a memory limit option for `ConsumeMessagesCommand`

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

New feature to add a memory limit option to the ConsumeMessagesCommand.
```
bin/console messenger:consume-messages <receiver-name> -m 128
```

Commits
-------

08f98cfaf1 [Messenger] Add a memory limit option for `ConsumeMessagesCommand`
2018-04-27 01:14:06 +02:00
Nicolas Grekas
2aa62df029 [Translator] Further postpone adding resource files 2018-04-26 14:20:27 +02:00
Samuel ROZE
4cbddd866f Register a UserProviderInterface alias if one provider only 2018-04-26 14:01:44 +02:00
Simon DELICATA
08f98cfaf1 [Messenger] Add a memory limit option for ConsumeMessagesCommand 2018-04-26 10:28:37 +02:00
Samuel ROZE
04d87ca829 Validate that the message exists to be able to configure its routing
Uses an existing class in the tests... :)
Only trigger the autoloading once
2018-04-25 22:18:22 +02:00
Robin Chalas
26482d78ac [Messenger] Add existing tags to unused whitelist 2018-04-25 20:44:19 +02:00
Kevin Bond
edddc73467
[WebProfilerBundle][Messenger] show bus name in profiler panel 2018-04-25 13:14:10 -04:00
Samuel ROZE
da4fccd37c feature #26864 [Messenger] Define multiple buses from the framework.messenger.buses configuration (sroze)
This PR was squashed before being merged into the 4.1-dev branch (closes #26864).

Discussion
----------

[Messenger] Define multiple buses from the `framework.messenger.buses` configuration

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #26652
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/issues/9617

Not everybody will benefit from having only one bus, especially with the CQRS-like usages. While keeping the extremely use of use of the single bus, this PR has the following:

- Create multiple buses from the YAML configuration
- Tag middleware only a specific buses
- Register middlewares from the YAML configuration

Even if it's visible in the PR's tests, here's how it will look like, for a completely full-customised version:
```yaml
framework:
    messenger:
        default_bus: commands
        buses:
            commands: ~
            events:
                middlewares:
                    - validation
                    - route_messages
                    - "Your\\Middleware\\Service"
                    - call_message_handler
```

A few things to note:
1. The YAML configuration creates `messenger.bus.[name]` services for the buses.
2. The YAML configuration for middleware just adds tags to the corresponding middlewares.
3. If the middleware definition does not exists, it creates it. (without any magic on the arguments though, if it isn't auto-wirable, well... "your problem")
4. In the PR, there is this "TolerateNoHandler" middleware that is a great example for event buses

Commits
-------

e5deb8499b [Messenger] Define multiple buses from the `framework.messenger.buses` configuration
2018-04-25 18:39:19 +02:00
Samuel ROZE
e5deb8499b [Messenger] Define multiple buses from the framework.messenger.buses configuration 2018-04-25 18:39:05 +02:00
Chris McCafferty
4e527aa790 bug #25844 [HttpKernel] Catch HttpExceptions when templating is not installed 2018-04-25 18:12:14 +02:00
Jakub Zalas
66773935eb
[FrameworkBundle] Register all private services on the test service container
Before this fix, only services explicitly configured with public=false were exposed via the test service container:

```
$container->register(PrivateService::class, PrivateService::class)->setPublic(false);
```

but not those explicitly configured as private:

```
$container->register(PrivateService::class, PrivateService::class)->setPrivate(true);
```

nor those implicitly configured as private:

```
$container->register(PrivateService::class, PrivateService::class);
```
2018-04-25 16:27:01 +01:00
Fabien Potencier
833909bd68 feature #26921 [DI][FrameworkBundle] Hide service ids that start with a dot (nicolas-grekas)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[DI][FrameworkBundle] Hide service ids that start with a dot

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

Now that services are private by default, `debug:container` should display them by default.
In fact, the public/private concept should not trigger a difference in visibility for this command.

Instead, I propose to handle service ids that start with a dot as hidden services.

PR should be ready.

(For reference, I tried using a tag instead in #26891, but that doesn't work in practice when working on the implementation.)

Commits
-------

cea051ee5e [DI][FrameworkBundle] Hide service ids that start with a dot
2018-04-20 15:23:35 +02:00
Nicolas Grekas
cea051ee5e [DI][FrameworkBundle] Hide service ids that start with a dot 2018-04-20 15:14:43 +02:00
Nicolas Grekas
1b1c03af83 Merge branch '4.0'
* 4.0:
  Fix tests
  PropertyInfo\DoctrineExtractor - There is bug when indexBy is meta key
  Fix PercentType error rendering.
  [minor] SCA
  [Cache] Inline some hot function calls
  fixed Silex project's URL
  fixed deprecations in tests
  fixed Twig URL
  [Cache] Add missing `@internal` tag on ProxyTrait
  fix formatting arguments in plaintext format
  Fix PSR exception context key
  Don't assume that file binary exists on *nix OS
  Fix that ESI/SSI processing can turn a \"private\" response \"public\"
  [Form] Fixed trimming choice values
  fix rendering exception stack traces
  [Routing] Fix loading multiple class annotations for invokable classes
2018-04-20 13:04:56 +02:00
Nicolas Grekas
6d9d329deb Merge branch '3.4' into 4.0
* 3.4:
  Fix tests
  PropertyInfo\DoctrineExtractor - There is bug when indexBy is meta key
  Fix PercentType error rendering.
  [minor] SCA
  [Cache] Inline some hot function calls
2018-04-20 12:04:09 +02:00
Nicolas Grekas
9a0422ce45 Merge branch '2.8' into 3.4
* 2.8:
  PropertyInfo\DoctrineExtractor - There is bug when indexBy is meta key
  [minor] SCA
2018-04-20 12:02:27 +02:00
Nicolas Grekas
8c5fe4461b Merge branch '2.7' into 2.8
* 2.7:
  [minor] SCA
2018-04-20 11:59:25 +02:00
Vladimir Tsykun
d0cb1de9a5 [HttpKernel] LoggerDataCollector: splitting logs on different sub-requests 2018-04-20 11:44:17 +02:00
Christian Flothmann
468533e18f [TwigBundle] fix tests 2018-04-20 11:14:37 +02:00
Vladimir Reznichenko
877e67883c [minor] SCA 2018-04-20 10:39:18 +02:00
Fabien Potencier
dcbfd00b02 Merge branch '3.4' into 4.0
* 3.4:
  fixed Silex project's URL
2018-04-20 08:21:32 +02:00
Fabien Potencier
d0928fc14f Merge branch '2.8' into 3.4
* 2.8:
  fixed Silex project's URL
2018-04-20 08:21:16 +02:00
Fabien Potencier
d05f0a0e03 fixed Silex project's URL 2018-04-20 08:21:07 +02:00
Fabien Potencier
bb45c75d7b Merge branch '3.4' into 4.0
* 3.4:
  fixed deprecations in tests
  fixed Twig URL
  [Cache] Add missing `@internal` tag on ProxyTrait
  fix formatting arguments in plaintext format
  Fix PSR exception context key
  Don't assume that file binary exists on *nix OS
  Fix that ESI/SSI processing can turn a \"private\" response \"public\"
  [Form] Fixed trimming choice values
  fix rendering exception stack traces
  [Routing] Fix loading multiple class annotations for invokable classes
2018-04-20 08:20:23 +02:00
DQNEO
74ab256bec declare type for arguments of anonymous functions for v2.7 2018-04-20 06:20:29 +02:00
Fabien Potencier
3d40bfa1c4 bug #26877 Add working orphaned events template (kejwmen)
This PR was merged into the 4.1-dev branch.

Discussion
----------

Add working orphaned events template

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

Current template is broken, this PR introduces a simple working template to fix profiler.

Commits
-------

089817b9b1 Add working orphaned events template
2018-04-20 06:10:43 +02:00
Lars Strojny
8c1672743d Don’t normalize global values 2018-04-19 22:19:20 +02:00
Christian Flothmann
f1c1d36fda fix formatting arguments in plaintext format 2018-04-19 10:26:28 +02:00
Fabien Potencier
8c4fd1299b feature #26787 [Security] Make security.providers optional (MatTheCat)
This PR was squashed before being merged into the 4.1-dev branch (closes #26787).

Discussion
----------

[Security] Make security.providers optional

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

Don't really know if it's viable but I just hit #21998 so I would like to tackle this.

Commits
-------

ee54bfa646 [Security] Make security.providers optional
2018-04-19 08:45:32 +02:00
Mathieu Lechat
ee54bfa646 [Security] Make security.providers optional 2018-04-19 08:45:26 +02:00
Samuel ROZE
fe199317da feature #26941 [Messenger] Allow to configure the transport (sroze)
This PR was squashed before being merged into the 4.1-dev branch (closes #26941).

Discussion
----------

[Messenger] Allow to configure the transport

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | ish
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #26900, #26908, #26935
| License       | MIT
| Doc PR        | ø

We allow users to configure the encoder/decoder used by the built-in adapter(s). This also adds the support of configuring the default's encoder/decoder format and context.

Commits
-------

1a3f0bbb14 [Messenger] Allow to configure the transport
2018-04-17 17:47:47 +01:00
Samuel ROZE
1a3f0bbb14 [Messenger] Allow to configure the transport 2018-04-17 17:47:06 +01:00
Maxime Steinhausser
60af39b161 [DebugBundle][VarDumper] Fix server dumper placeholder command 2018-04-16 22:53:37 +02:00
Samuel ROZE
177cea0ee1 Support nested configuration on adapters 2018-04-16 18:40:17 +01:00
Fabien Potencier
7e4de96c03 minor #26909 [Messenger][DX] Uses the adapter name instead of the service name (sroze)
This PR was squashed before being merged into the 4.1-dev branch (closes #26909).

Discussion
----------

[Messenger][DX] Uses the adapter name instead of the service name

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

As a developer, I don't get why I would need to use the service name while I give a name to the adapters. This is basically what this PR means for me in terms of configuration:
```patch
framework:
    messenger:
        routing:
            # We want the command below to be handled async with the "messenger.default_sender" (AMQP producer).
-            'App\Message\Command\CreateNumber': messenger.sender.amqp
+            'App\Message\Command\CreateNumber': amqp

        adapters:
            amqp: "%env(AMQP_DSN)%"
```

And in terms of pulling the messages:
```patch
- bin/console messenger:consume-messages messenger.receiver.amqp
+ bin/console messenger:consume-messages amqp
```

Commits
-------

b5afb40441 [Messenger][DX] Uses the adapter name instead of the service name
2018-04-16 19:19:59 +02:00
Samuel ROZE
b5afb40441 [Messenger][DX] Uses the adapter name instead of the service name 2018-04-16 19:19:48 +02:00
Yonel Ceruto
eedad4c061 Make logger arg a hard dependency, remove dead code and add tests 2018-04-14 13:36:02 -04:00
Christian Flothmann
99302e72fc fix rendering exception stack traces 2018-04-13 17:45:35 +02:00
Samuel ROZE
d60425c868 Allow the logger to be null (as per every other bits in the FrameworkBundle) 2018-04-12 19:18:53 +01:00
Samuel ROZE
3c4be3cdda
Update the tests to also use interface_exists 2018-04-12 16:38:50 +01:00
Ryan Weaver
2405eae500 Fixing bad class_exists vs interface_exists 2018-04-12 11:21:29 -04:00
Samuel ROZE
aa04d06dc4 feature #26632 [Messenger] Add AMQP adapter (sroze)
This PR was squashed before being merged into the 4.1-dev branch (closes #26632).

Discussion
----------

[Messenger] Add AMQP adapter

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

- [x] Depends on the Messenger component #24411
- [x] Add tests once we are all happy about the structure

---

In order to give a great DX for simple needs such as sending messages through an AMQP broker such as RabbitMq, we should ship an AMQP adapter for the Messenger component within Symfony Core. It should be as simple as this proposal. We don't need to handle more specific use-cases nor brokers as other adapters such as the [enqueue adapter](https://github.com/sroze/enqueue-bridge) can also be used.

Configuring the adapter is as simple as the following configuration:
```yaml
# config/packages/messenger_adapters.yaml
framework:
    messenger:
        adapter: "%env(MESSENGER_DSN)%"
```

With the given `.env` for example:
```
MESSENGER_DSN=amqp://guest:guest@localhost:5672/%2f/messages
```

Keep in mind that after having configured the adapter, developers have to route their messages to the given adapter.

```yaml
# config/packages/messenger_routes.yaml
framework:
    messenger:
        routing:
producer).
            'App\Message\Command\CreateNumber': messenger.default_sender
```

---

Additionally, multiple adapters can be created and messages routed to these ones.

```yaml
# config/packages/messenger_routes.yaml
framework:
    messenger:
        adapters:
            commands: "amqp://guest:guest@localhost:5672/%2f/commands"
            maintenance: "amqp://guest:guest@localhost:5672/%2f/maintenance"
        routing:
producer).
            'App\Message\Command\CreateNumber': messenger.commands_sender
            'App\Message\Command\MaintenanceSpecificCommand': messenger.maintenance_sender
```

Commits
-------

798c230ad5 [Messenger] Add AMQP adapter
2018-04-12 09:16:00 +01:00
Samuel ROZE
798c230ad5 [Messenger] Add AMQP adapter 2018-04-12 09:15:52 +01:00
Mateusz Sip
089817b9b1
Add working orphaned events template 2018-04-10 01:02:34 +02:00
Grégoire Pineau
8e0fcf933c [FrameworkBundle] Fixed configuration of php_errors.log 2018-04-09 18:19:45 +02:00
Samuel ROZE
dd18445482 Rename the middleware tag from message_bus_middleware to messenger.bus_middleware 2018-04-08 10:53:48 +01:00
Fabien Potencier
f1a9d7098e Merge branch '4.0'
* 4.0:
  [Form] Fix typo in Upgrade 3.4/4.0
  [EventDispatcher] Dispatcher in stopEventPropagation test now registers correct listener
  Update da translations
  Fix Typo in Guard Factory
2018-04-06 09:35:57 +02:00
Fabien Potencier
5ea5ee2079 Merge branch '3.4' into 4.0
* 3.4:
  [Form] Fix typo in Upgrade 3.4/4.0
  [EventDispatcher] Dispatcher in stopEventPropagation test now registers correct listener
  Update da translations
  Fix Typo in Guard Factory
2018-04-06 09:35:43 +02:00
Fabien Potencier
ee054cd756 Merge branch '2.8' into 3.4
* 2.8:
  [EventDispatcher] Dispatcher in stopEventPropagation test now registers correct listener
  Update da translations
  Fix Typo in Guard Factory
2018-04-06 09:35:25 +02:00
Fabien Potencier
dc29b27a83 feature #26660 [SecurityBundle] allow using custom function inside allow_if expressions (dmaicher)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[SecurityBundle] allow using custom function inside allow_if expressions

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | yes
| Tests pass?   | no
| Fixed tickets | https://github.com/symfony/symfony/issues/23208
| License       | MIT
| Doc PR        | https://github.com/symfony/symfony-docs/pull/9552

This is a follow-up for https://github.com/symfony/symfony/pull/26263

As discussed there I propose to allow using custom functions as a new feature only and thus targeting `master` here.

If we agree to move forward with this there are some todos:
- [x] fix tests
- [x] add cache warmer for allow_if expressions
- [x] update documentation to mention this new feature
- [x] update UPGRADE files

ping @nicolas-grekas @stof

Commits
-------

41552cd896 [SecurityBundle] allow using custom function inside allow_if expressions
2018-04-06 08:18:32 +02:00
Fabien Potencier
3a37e41bfb bug #26816 [Messenger][FrameworkBundle] Move collector, command into the component & minor tweaks (ogizanagi)
This PR was squashed before being merged into the 4.1-dev branch (closes #26816).

Discussion
----------

[Messenger][FrameworkBundle] Move collector, command into the component & minor tweaks

| Q             | A
| ------------- | ---
| Branch?       | master <!-- see below -->
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | N/A   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | N/A

Some suggestions more aligned with most of the core practices, mainly:

- Move the command & collector to the component itself. They are not dependent of the Fwb in any way and are useful out of the fwb usage.
- Add an exception in FrameworkExtension if the `framework.messenger` key is enabled, but the component isn't installed.

Commits
-------

6aec62bad3 [FrameworkBundle] Minor messenger component tweaks
f9c9ca0514 [Messenger] Move data collector & command into the component
2018-04-06 07:28:47 +02:00
Christian Flothmann
79e898ffe8 remove CSRF Twig extension when class is missing 2018-04-05 18:06:51 +02:00
Maxime Steinhausser
6aec62bad3 [FrameworkBundle] Minor messenger component tweaks 2018-04-05 17:47:14 +02:00
Maxime Steinhausser
f9c9ca0514 [Messenger] Move data collector & command into the component 2018-04-05 17:21:58 +02:00
David Maicher
41552cd896 [SecurityBundle] allow using custom function inside allow_if expressions 2018-04-04 20:31:39 +02:00
Fabien Potencier
5b4e1c5b6b Merge branch '4.0'
* 4.0:
  [Security] register custom providers on ExpressionLanguage directly
  [PhpUnitBridge] Catch deprecation error handler
2018-04-04 20:25:14 +02:00
Fabien Potencier
eb7050ab50 Merge branch '3.4' into 4.0
* 3.4:
  [Security] register custom providers on ExpressionLanguage directly
  [PhpUnitBridge] Catch deprecation error handler
2018-04-04 20:24:59 +02:00
Fabien Potencier
572042c4ec feature #26684 [Messenger] Remove the Doctrine middleware configuration from the FrameworkBundle (sroze)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Messenger] Remove the Doctrine middleware configuration from the FrameworkBundle

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

As per @fabpot's request, remove the enabling feature of the DoctrineMiddleware from the FramworkBundle.

/cc @Nyholm

Commits
-------

27a8b1dc96 Remove the Doctrine middleware configuration from the FrameworkBundle
2018-04-04 19:46:16 +02:00
David Maicher
3a55a86609 [Security] register custom providers on ExpressionLanguage directly 2018-04-04 19:20:26 +02:00
Zan Baldwin
c0a051d46d Fix Typo in Guard Factory 2018-04-04 16:36:22 +01:00
Robin Chalas
e973f6f380 [master] fix test 2018-04-04 16:30:04 +02:00
Nicolas Grekas
bd4820b146 Merge branch '4.0'
* 4.0:
  [Routing] Fix throwing NoConfigurationException instead of 405
  [Security] Load the user before pre/post auth checks when needed
  [SecurityBundle] Add test for simple authentication config
  [WebProfilerBundle] fix version check
  [SecurityBundle] Add missing argument to security.authentication.provider.simple
  [Finder] fix tests
2018-04-04 15:53:40 +02:00
Nicolas Grekas
bc23cae7b0 Merge branch '3.4' into 4.0
* 3.4:
  [Routing] Fix throwing NoConfigurationException instead of 405
  [Security] Load the user before pre/post auth checks when needed
  [SecurityBundle] Add test for simple authentication config
  [WebProfilerBundle] fix version check
  [SecurityBundle] Add missing argument to security.authentication.provider.simple
  [Finder] fix tests
2018-04-04 15:50:32 +02:00
Nicolas Grekas
5d189e1018 Merge branch '2.8' into 3.4
* 2.8:
  [Security] Load the user before pre/post auth checks when needed
  [SecurityBundle] Add test for simple authentication config
  [SecurityBundle] Add missing argument to security.authentication.provider.simple
  [Finder] fix tests
2018-04-04 15:49:01 +02:00
Samuel ROZE
27a8b1dc96 Remove the Doctrine middleware configuration from the FrameworkBundle 2018-04-04 13:52:24 +01:00
Robin Chalas
c82c2f1efa [SecurityBundle] Add test for simple authentication config 2018-04-04 14:16:21 +02:00
Nicolas Grekas
946eefa284 [WebProfilerBundle] fix version check 2018-04-04 14:14:22 +02:00
Boris Vujicic
1b26aac8d2 [SecurityBundle] Add missing argument to security.authentication.provider.simple 2018-04-04 13:53:06 +02:00
Fabien Potencier
54268f1266 Merge branch '4.0'
* 4.0:
  fixed tests
  [Finder] Remove duplicate slashes in filenames
  [VarDumper] Skip some tests on custom xdebug.file_link_format
  [WebProfilerBundle][HttpKernel] Make FileLinkFormatter URL format generation lazy
  bumped Symfony version to 4.0.8
  updated VERSION for 4.0.7
  updated CHANGELOG for 4.0.7
  bumped Symfony version to 3.4.8
  updated VERSION for 3.4.7
  updated CHANGELOG for 3.4.7
2018-04-04 07:11:41 +02:00
Fabien Potencier
f76624a0b7 Merge branch '3.4' into 4.0
* 3.4:
  fixed tests
  [Finder] Remove duplicate slashes in filenames
  [VarDumper] Skip some tests on custom xdebug.file_link_format
  [WebProfilerBundle][HttpKernel] Make FileLinkFormatter URL format generation lazy
  bumped Symfony version to 3.4.8
  updated VERSION for 3.4.7
  updated CHANGELOG for 3.4.7
2018-04-04 07:10:37 +02:00
Samuel ROZE
235e037748 Fix validation configuration default test case 2018-04-03 22:35:24 +01:00
Samuel ROZE
d5b88eb7eb feature #26685 [Messenger] Add a MessageHandlerInterface (multiple messages + auto-configuration) (sroze)
This PR was squashed before being merged into the 4.1-dev branch (closes #26685).

Discussion
----------

[Messenger] Add a `MessageHandlerInterface` (multiple messages + auto-configuration)

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

Based on @chalasr's PR: https://github.com/symfony/symfony/pull/26672.

This reduces the hassle of registering handlers: it allows the auto-configuration with a new interface `HandlerInterface`. At the same time, it allows a handler to handle multiple messages.

Commits
-------

07e6bc73a3 [Messenger] Add a `MessageHandlerInterface` (multiple messages + auto-configuration)
2018-04-03 21:23:24 +01:00
Samuel ROZE
07e6bc73a3 [Messenger] Add a MessageHandlerInterface (multiple messages + auto-configuration) 2018-04-03 21:23:12 +01:00
Tobias Nyholm
43a51714d4 [Messenger] Added a middleware that validates messages 2018-04-03 21:17:07 +01:00
Nicolas Grekas
e074c0550c [WebProfilerBundle][HttpKernel] Make FileLinkFormatter URL format generation lazy 2018-04-03 12:14:10 +02:00
Fabien Potencier
382b5868e4 bug #26740 [FrameworkBundle] fix log level support config handling (xabbuh)
This PR was squashed before being merged into the 4.1-dev branch (closes #26740).

Discussion
----------

[FrameworkBundle] fix log level support config handling

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

Commits
-------

2ee6bb4897 fix log level support config handling
ad8c8d00aa add PHP errors options to XML schema definition
2018-04-02 14:14:00 +02:00
Grégoire Pineau
95049154b3 Revert "[FrameworkBundle] Partially revert HttpCache is not longer abstract (4d075da)"
This reverts commit 60730666ab.
2018-04-02 13:58:37 +02:00
Nicolas Grekas
6e95c2ad27 Merge branch '4.0'
* 4.0: (24 commits)
  moved Twig runtime to proper class
  fixed deprecated messages in tests
  add PHP errors options to XML schema definition
  [HttpCache] Unlink tmp file on error
  Added LB translation for #26327 (Errors sign for people that do not see colors)
  [TwigBridge] Fix rendering of currency by MoneyType
  Import InvalidArgumentException in PdoAdapter
  [DI] Do not suggest writing an implementation when multiple exist
  [Intl] Update ICU data to 61.1
  Use 3rd person verb form in command description
  [Validator] Add Japanese translation
  Support phpdbg SAPI in Debug::enable()
  [HttpKernel] DumpDataCollector: do not flush when a dumper is provided
  [DI] Fix hardcoded cache dir for warmups
  [Routing] fix tests
  [Routing] Fixed the importing of files using glob patterns that match multiple resources
  [Ldap] cast to string when checking empty passwords
  [Validator] sync validator translation id
  [WebProfilerBundle] use the router to resolve file links
  no type errors with invalid submitted data types
  ...
2018-04-02 12:08:33 +02:00
Nicolas Grekas
a5a44472c9 Merge branch '3.4' into 4.0
* 3.4: (24 commits)
  moved Twig runtime to proper class
  fixed deprecated messages in tests
  add PHP errors options to XML schema definition
  [HttpCache] Unlink tmp file on error
  Added LB translation for #26327 (Errors sign for people that do not see colors)
  [TwigBridge] Fix rendering of currency by MoneyType
  Import InvalidArgumentException in PdoAdapter
  [DI] Do not suggest writing an implementation when multiple exist
  [Intl] Update ICU data to 61.1
  Use 3rd person verb form in command description
  [Validator] Add Japanese translation
  Support phpdbg SAPI in Debug::enable()
  [HttpKernel] DumpDataCollector: do not flush when a dumper is provided
  [DI] Fix hardcoded cache dir for warmups
  [Routing] fix tests
  [Routing] Fixed the importing of files using glob patterns that match multiple resources
  [Ldap] cast to string when checking empty passwords
  [Validator] sync validator translation id
  [WebProfilerBundle] use the router to resolve file links
  no type errors with invalid submitted data types
  ...
2018-04-02 11:52:41 +02:00
Fabien Potencier
62eebd7d50 Merge branch '2.8' into 3.4
* 2.8:
  fixed deprecated messages in tests
  [HttpCache] Unlink tmp file on error
  Added LB translation for #26327 (Errors sign for people that do not see colors)
  [TwigBridge] Fix rendering of currency by MoneyType
  [HttpKernel] DumpDataCollector: do not flush when a dumper is provided
2018-04-02 11:38:44 +02:00
Fabien Potencier
92322f1be0 fixed deprecated messages in tests 2018-04-02 11:33:07 +02:00
Fabien Potencier
72501cd311 Merge branch '2.7' into 2.8
* 2.7:
  [HttpCache] Unlink tmp file on error
  Added LB translation for #26327 (Errors sign for people that do not see colors)
  [TwigBridge] Fix rendering of currency by MoneyType
  [HttpKernel] DumpDataCollector: do not flush when a dumper is provided
2018-04-02 11:31:53 +02:00
Christian Flothmann
2ee6bb4897 fix log level support config handling 2018-04-02 11:08:46 +02:00
Christian Flothmann
ad8c8d00aa add PHP errors options to XML schema definition 2018-04-02 10:42:40 +02:00
Christian Flothmann
7d39bac2dc add PHP errors options to XML schema definition 2018-04-02 10:41:14 +02:00
Fabien Potencier
46c9842a4c Revert "feature #26698 [Console] Use UTF-8 bullet for listing (ro0NL)"
This reverts commit 6bfc082b87, reversing
changes made to 9b25573e73.
2018-04-01 10:27:13 +02:00
Fabien Potencier
6bfc082b87 feature #26698 [Console] Use UTF-8 bullet for listing (ro0NL)
This PR was squashed before being merged into the 4.1-dev branch (closes #26698).

Discussion
----------

[Console] Use UTF-8 bullet for listing

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #...   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Inspired by the new table style, this updates the listing style.

before

![image](https://user-images.githubusercontent.com/1047696/38031214-019c79f4-329b-11e8-8352-9453c7ccc129.png)

after

![image](https://user-images.githubusercontent.com/1047696/38031186-ed8b1e66-329a-11e8-8538-2256a0e24a42.png)

Commits
-------

d1e4acb02e [Console] Use UTF-8 bullet for listing
2018-03-30 10:44:22 +02:00
Roland Franssen
d1e4acb02e [Console] Use UTF-8 bullet for listing 2018-03-30 10:44:16 +02:00
Fabien Potencier
f568271238 feature #26682 Improved the lint:xliff command (javiereguiluz)
This PR was squashed before being merged into the 4.1-dev branch (closes #26682).

Discussion
----------

Improved the lint:xliff command

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

This is how it looks:

![lint-xliff-output](https://user-images.githubusercontent.com/73419/37958502-fd8732e0-31b0-11e8-8688-8644ca930daf.png)

Commits
-------

6bbcc45d96 Improved the lint:xliff command
2018-03-30 10:39:14 +02:00
Javier Eguiluz
6bbcc45d96 Improved the lint:xliff command 2018-03-30 10:39:04 +02:00
Roland Franssen
a3a2ff0c74 [TwigBridge] Fix rendering of currency by MoneyType 2018-03-29 15:55:10 +02:00
Robin Chalas
9b6ed69a71 minor #26703 [Messenger] Fix messenger profiler name (sroze)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Messenger] Fix messenger profiler name

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26674
| License       | MIT
| Doc PR        | ø

In #26674, the profiler name was not renamed properly, which means it wasn't displayed anymore.

Commits
-------

bd234ff Fix messenger profiler name
2018-03-29 10:09:35 +02:00
Samuel ROZE
bd234ff7f8 Fix messenger profiler name 2018-03-29 00:50:07 +02:00
Fabien Potencier
3d5f04cce3 Merge branch '2.8' into 3.4
* 2.8:
  [Intl] Update ICU data to 61.1
  [Validator] Add Japanese translation
  Support phpdbg SAPI in Debug::enable()
  [Ldap] cast to string when checking empty passwords
  [Validator] sync validator translation id
  no type errors with invalid submitted data types
  [FrameworkBundle] Partially revert HttpCache is not longer abstract (4d075da)
  [Finder] Fixed leading/trailing / in filename
  allow html5 compatible rendering of forms with null names
  Change datetime input to datetime-local
2018-03-28 20:23:39 +02:00
Fabien Potencier
e3201b8f37 Merge branch '2.7' into 2.8
* 2.7:
  [Intl] Update ICU data to 61.1
  [Validator] Add Japanese translation
  Support phpdbg SAPI in Debug::enable()
  [Validator] sync validator translation id
  no type errors with invalid submitted data types
  [FrameworkBundle] Partially revert HttpCache is not longer abstract (4d075da)
  [Finder] Fixed leading/trailing / in filename
  allow html5 compatible rendering of forms with null names
  Change datetime input to datetime-local
2018-03-28 20:22:50 +02:00
Fabien Potencier
e3f964f923 bug #26670 [FrameworkBundle] Remove double cache generation by detecting fresh kernels on cache:clear (nicolas-grekas)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] Remove double cache generation by detecting fresh kernels on cache:clear

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

The `cache:clear` command currently runs non-optional cache warmers twice or more.
It also clears + warms up just created caches (when var/cache/dev doens't exist yet, eg on 1st `composer install`.)

This PR fixes both behaviors. To run only what's needed once.
Best reviewed [ignoring whitespaces](https://github.com/symfony/symfony/pull/26670/files?w=1).

Commits
-------

9d8eac213a [FrameworkBundle] Remove double cache generation by detecting fresh kernels on cache:clear
2018-03-28 20:12:22 +02:00
Nicolas Grekas
9d8eac213a [FrameworkBundle] Remove double cache generation by detecting fresh kernels on cache:clear 2018-03-28 19:19:11 +02:00
Marco Petersen
e467e4cc6e Use 3rd person verb form in command description 2018-03-27 23:06:51 +02:00
Fabien Potencier
44a6f60fdb feature #26504 [FrameworkBundle] framework.php_errors.log now accept a log level (Simperfit)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] framework.php_errors.log now accept a log level

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26267   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        |  todo <!-- required for new features -->

We are testing that `framework.php_errors.log` is either a bool or an int (set the value of the log level you want).
This fixes #26267, so it gives a way to not log some level on production.

Commits
-------

664f821895 [FrameworkBundle] framework.php_errors.log now accept a log level
2018-03-27 20:27:43 +02:00
Amrouche Hamza
664f821895
[FrameworkBundle] framework.php_errors.log now accept a log level 2018-03-27 16:39:44 +02:00
Samuel ROZE
ea6d8618ff feature #26647 [Messenger] Add a middleware that wraps all handlers in one Doctrine transaction. (Nyholm)
This PR was squashed before being merged into the 4.1-dev branch (closes #26647).

Discussion
----------

[Messenger] Add a middleware that wraps all handlers in one Doctrine transaction.

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

This is greatly inspired by SimpleBus. This middleware will rollback a transaction if the message handler throws an exception.

Commits
-------

623dc5fb16 [Messenger] Add a middleware that wraps all handlers in one Doctrine transaction.
2018-03-27 11:43:33 +01:00
Tobias Nyholm
623dc5fb16 [Messenger] Add a middleware that wraps all handlers in one Doctrine transaction. 2018-03-27 11:43:30 +01:00
Gabriel Ostrolucký
eb6974d14c [WebProfilerBundle] Live duration of AJAX request 2018-03-27 11:02:44 +02:00
Fabien Potencier
5b27c2f61f feature #26650 [Messenger] Clone messages to show in profiler (Nyholm)
This PR was squashed before being merged into the 4.1-dev branch (closes #26650).

Discussion
----------

[Messenger] Clone messages to show in profiler

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

We should make the profiler page more pretty by using the cloner.

![screen shot 2018-03-23 at 11 08 02](https://user-images.githubusercontent.com/1275206/37823687-816a373a-2e8a-11e8-824e-ac7f96a51e3b.png)

Commits
-------

4d1be87b70 [Messenger] Clone messages to show in profiler
2018-03-27 09:46:52 +02:00
Tobias Nyholm
4d1be87b70 [Messenger] Clone messages to show in profiler 2018-03-27 09:46:50 +02:00
Fabien Potencier
7b20b8cf3e feature #26281 [FrameworkBundle] keep query in redirect (Simperfit)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] keep query in redirect

| Q             | A
| ------------- | ---
| Branch?       | 4.1
| Bug fix?      | no
| New feature?  | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26256   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | #9314

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Commits
-------

406bfc9896 [FrameworkBundle] keep query params in redirection
2018-03-27 09:45:03 +02:00
Fabien Potencier
a9494840f2 feature #26665 Improved the Ajax profiler panel when there are exceptions (javiereguiluz)
This PR was merged into the 4.1-dev branch.

Discussion
----------

Improved the Ajax profiler panel when there are exceptions

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

This makes the following changes in the Ajax panel:

* The `Profiler` column is now the first one.
* When the response status code is `400` or higher, the profiler link points to the exception panel instead of the default request/response panel

![ajax-panel](https://user-images.githubusercontent.com/73419/37874477-52cf3888-3030-11e8-8042-23351f2e7a0f.png)

Commits
-------

074d68d67f Improved the Ajax profiler panel when there are exceptions
2018-03-27 09:38:41 +02:00
Fabien Potencier
9dd89e014b feature #26332 Add a data_help method in Form (mpiot, Nyholm)
This PR was merged into the 4.1-dev branch.

Discussion
----------

Add a data_help method in Form

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #26331
| License       | MIT
| Doc PR        | symfony/symfony-docs#9361

Add a form_help method in twig to display a help message in form. A `help` keyword is added to all FormType to define the message.

Commits
-------

585ca28b8a Add return type hint
859ee03785 Revert: remove comment line from twig templates
d723756331 Fix some mistakes
c74e0dc2da Use spaceless balises in Twig templates
8b937ff43f Try without try/catch
32bf1f68ad Test the renderHelp method in all Tests about help to skip them if necessary.
437b77e81a Skip renderHelp test as skipped if not override
d84be700b2 Update composer files
075fcfd07c [FrameworkBundle] Add widgetAtt to formTable/form_row
f1d13a860c Fix Fabpot.io
69ded67643 Added form_help on horizontal design and removed special variable
fd53bc579a Enable aria-described in row for all Templates
98065d38b5 fabpot.io fix
edb95f8e44 Use array long syntax
aada72c5d4 Set help option on nul as default
f948147e38 Rename help id (snake_case)
77fa3178bd Fix Test
30deaa9b28 PSR fix
bf4d08c5ae Add aria-describedBy on input
1f3a15e33b Rename id
058489d7df Add an id to the help
6ea7a2054b Remove vars option from form_help
ba798dfdf4 FrameworkBundle Tests
4f2581d7da Use array long syntax
f15bc79df1 Fix coding standards
c934e496d2 Add test without help set
8094804522 Add Tests
067c681580 Template for table, Foundation and Bootstrap 3
d3e3e492df Fix: check translation domain
2c2c04549f Adapt existant tests
831693ad45 Add trans filter
e311838aed Remove raw filter for help
8b97c1b516 Use a shortcut to acces help var in Twig template
1b89f9d9dd Add a template fot div_layout
c8914f591e Add a data_help method in Form
2018-03-27 09:25:04 +02:00
Fabien Potencier
d329a7a755 minor #26674 Updated the Messenger profiler panel (javiereguiluz)
This PR was squashed before being merged into the 4.1-dev branch (closes #26674).

Discussion
----------

Updated the Messenger profiler panel

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

The profiler icon of the new Messenger component was still pending. After talking with @sroze, we settled on two possible ideas for the icon: 1) focus on "messages"; 2) focus on "bus" / "message bus".

These are the icons for the two proposals:

| "Messages" | "Message Bus"
| --- | ---
| ![icon-1](https://user-images.githubusercontent.com/73419/37912058-da8aabb8-3111-11e8-972c-e3535ab9e1e8.png) | ![icon-2](https://user-images.githubusercontent.com/73419/37912063-dc2df556-3111-11e8-9fe8-c52a2ea0e008.png)

This is how they look inside the profiler:

"Messages"

![icon-1-profiler](https://user-images.githubusercontent.com/73419/37912208-43c402f0-3112-11e8-9a33-4e45ceb44b8b.png)

"Message Bus"

![icon-2-profiler](https://user-images.githubusercontent.com/73419/37912106-f3912f10-3111-11e8-827b-c8cc06c71ebe.png)

-----

My opinion:

* "Messages" look like "forum messages" or "chat messages". It looks wrong to me.
* Inside the profiler, "Messages" looks similar to "Translation" and we already have another "messages" icon for the "Mailer".
* For these reasons, I'd use "Message Bus".

Now, let's hear the community opinion. Thanks!

-----

If you want to test then on your computer:

"Messages"

```svg
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" x="0px" y="0px" height="24" viewBox="0 0 24 24" enable-background="new 0 0 24 24" xml:space="preserve"><path fill="#aaa" d="M11.32 9.06h-8a3.07 3.07 0 0 0-3.35 3v5a3.09 3.09 0 0 0 3.35 3h2.75l4 3.69c.42.35.89.21.89-.34v-3c2 0 4-1.5 4-3.35v-5c.04-1.85-1.79-3-3.64-3zM11 16.5H4a.5.5 0 1 1 0-1h7a.5.5 0 0 1 0 1zm0-2.63H4a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 .5.5.5.5 0 0 1-.5.5zM21.29.06h-6.46A2.83 2.83 0 0 0 12 2.89v5.33c3.31 0 4 2.28 4 4.72 0 .44.46.56.8.28l3.31-3.16h1.21A2.71 2.71 0 0 0 24 7.35V2.77A2.71 2.71 0 0 0 21.29.06zm-.81 6.66h-5a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.5h5a.5.5 0 0 1 .5.5.5.5 0 0 1-.5.5zm0-2.63h-5a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.5h5a.5.5 0 0 1 .5.5.5.5 0 0 1-.5.5z"/></svg>
```

"Message Bus"

```svg
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" x="0px" y="0px" height="24" viewBox="0 0 24 24" enable-background="new 0 0 24 24" xml:space="preserve"><path fill="#aaa" d="M16 9a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2h-3V4a1 1 0 0 0-1-1H8a2 2 0 0 0-2-2H2a2 2 0 0 0-2 2v2a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2h3v6H8a2 2 0 0 0-2-2H2a2 2 0 0 0-2 2v2a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2h3v9a1 1 0 0 0 2 0v-5h3a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2v-2a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2h-3V9zm2.52-2.5h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zm0 1.63h3a.5.5 0 0 1 .5.5.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.52zm-13-2.82h-3a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.5h3a.5.5 0 0 1 .5.5.5.5 0 0 1-.54.48zm0-1.62h-3a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.5h3a.5.5 0 0 1 .5.5.5.5 0 0 1-.54.48zm0 9.62h-3a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.5h3a.5.5 0 0 1 .5.5.5.5 0 0 1-.54.48zm0-1.62h-3a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.5h3a.5.5 0 0 1 .5.5.5.5 0 0 1-.54.48zm13 2.81h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1zm0 1.63h3a.5.5 0 0 1 .5.5.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5.5.5 0 0 1 .5-.52z"/></svg>
```

Commits
-------

92a041c074 Updated the Messenger profiler panel
2018-03-27 09:13:34 +02:00
Javier Eguiluz
92a041c074 Updated the Messenger profiler panel 2018-03-27 09:13:31 +02:00
Javier Eguiluz
510b05fb74 More compact display of vendor code in exception pages 2018-03-27 09:07:12 +02:00
Amrouche Hamza
406bfc9896
[FrameworkBundle] keep query params in redirection 2018-03-26 16:59:39 +02:00
Javier Eguiluz
074d68d67f Improved the Ajax profiler panel when there are exceptions 2018-03-25 13:25:04 +02:00
Grégoire Pineau
ce66ef028f bug #26657 [Workflow] Fixed default parameters (lyrixx)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Workflow] Fixed default parameters

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

Commits
-------

fc303a8 [Workflow] Fixed default parameters
2018-03-23 17:00:48 +01:00
Mathieu Piot
585ca28b8a Add return type hint 2018-03-23 15:53:02 +01:00
Mathieu Piot
d723756331 Fix some mistakes 2018-03-23 15:53:02 +01:00
Mathieu Piot
d84be700b2 Update composer files 2018-03-23 15:53:02 +01:00
Mathieu Piot
075fcfd07c [FrameworkBundle] Add widgetAtt to formTable/form_row 2018-03-23 15:53:02 +01:00
Mathieu Piot
f1d13a860c Fix Fabpot.io 2018-03-23 15:53:02 +01:00
Nyholm
69ded67643 Added form_help on horizontal design and removed special variable 2018-03-23 15:53:02 +01:00
Mathieu Piot
98065d38b5 fabpot.io fix 2018-03-23 15:53:02 +01:00
Mathieu Piot
f948147e38 Rename help id (snake_case) 2018-03-23 15:53:02 +01:00
Mathieu Piot
30deaa9b28 PSR fix 2018-03-23 15:53:02 +01:00
Mathieu Piot
bf4d08c5ae Add aria-describedBy on input 2018-03-23 15:53:02 +01:00
Mathieu Piot
1f3a15e33b Rename id 2018-03-23 15:53:02 +01:00
Mathieu Piot
058489d7df Add an id to the help 2018-03-23 15:53:02 +01:00
Mathieu Piot
6ea7a2054b Remove vars option from form_help 2018-03-23 15:53:02 +01:00
Mathieu Piot
ba798dfdf4 FrameworkBundle Tests 2018-03-23 15:53:02 +01:00
Grégoire Pineau
fc303a8d9f [Workflow] Fixed default parameters 2018-03-23 15:16:51 +01:00
Fabien Potencier
4bbdf06c10 feature #23831 [VarDumper] Introduce a new way to collect dumps through a server dumper (ogizanagi, nicolas-grekas)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[VarDumper] Introduce a new way to collect dumps through a server dumper

| Q             | A
| ------------- | ---
| Branch?       | 4.1 <!-- see comment below -->
| Bug fix?      | no
| New feature?  | yes <!-- 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 | #22987 <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | todo <!--highly recommended for new features-->

Could also be interesting as alternate solution for #23442.

Inspired by the [`ServerLogHandler`](https://github.com/symfony/symfony/pull/21080) and @nicolas-grekas's [comment](https://github.com/symfony/symfony/pull/22987#issuecomment-305791102) in #22987.

---

## Description

This PR introduces a new `server:dump` command available in the `VarDumper` component.
Conjointly with a new `ServerDumper` data dumper, it allows to send serialized `Data` clones to a single centralized server, in charge of dumping them on CLI output, or in an file in HTML format.

## Showcase

### HTTP calls

For instance, when working on an API and dumping something, you might end up with a mix of your response and the CLI dumped version of the data you asked:

```php
class HelloController extends AbstractController
{
    /**
     * @Route("/hello")
     */
    public function hello(Request $request, UserInterface $user)
    {
        dump($request->attributes, $user);

        return JsonResponse::create([
            'status' => 'OK',
            'message' => "Hello {$user->getUsername()}"
        ]);
    }
}
```

<img width="732" alt="screenshot 2017-08-08 a 16 44 24" src="https://user-images.githubusercontent.com/2211145/29077731-0b2152d6-7c59-11e7-99dd-2d060a906d48.PNG">

You might even get the HTML dump version [under some conditions](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/DataCollector/DumpDataCollector.php#L146-L157).

Dumping to a server allows collecting dumps in a separate place:

<!--![server-dumper-http-to-cli-output](https://user-images.githubusercontent.com/2211145/29077977-8ace19ce-7c59-11e7-998e-ee9c49e67958.gif)-->

![server-dump-http-to-cli](https://user-images.githubusercontent.com/2211145/29226044-dcc95f12-7ed0-11e7-8343-40aeb7b18dd5.gif)

~⚠️ By swallowing the previous dumpers output, the dump data collector is not active when running the dump server. Disable swallowing if you want both.~ ➜ Dumps are still collected in the profiler thanks to f24712effc9fab1163c0053e2a0a0d5cc4f6473e

### CLI calls

The best probably is (to me) that you can also debug CLI applications...

![server-dump-cli](https://user-images.githubusercontent.com/2211145/29225951-84e29098-7ed0-11e7-8067-abaa9c50d169.gif)

<!--![server-dumper-cli-to-cli-output](https://user-images.githubusercontent.com/2211145/29078261-1eb950ea-7c5a-11e7-94ee-aa3ae3bf7fb0.gif)-->

...and get HTML formatted dumps:

![server-dumper-cli-to-html-output](https://user-images.githubusercontent.com/2211145/30784609-d7dc19b8-a158-11e7-9b11-88ae819cfcca.gif)

<!--![server-dump-cli-to-html](https://user-images.githubusercontent.com/2211145/29225866-2b5675e4-7ed0-11e7-98eb-339611bd94a7.gif)-->

<!--![server-dumper-cli-to-html-output](https://user-images.githubusercontent.com/2211145/29078247-17e33e5c-7c5a-11e7-94f7-47de6774e0e8.gif)-->

hence, benefit from all the features of this format (collapse, search, ...)

### HTML output at a glance

<img width="831" alt="screenshot 2017-08-11 a 19 28 25" src="https://user-images.githubusercontent.com/2211145/29225513-eae349f2-7ece-11e7-9861-8cda9e80ba7f.PNG">

The HTML output benefits from all the `HtmlDumper` features and contains extra informations about the context (sources, requests, command line, ...). It doesn't aim to replace the profiler for HTTP calls with the framework, but is really handy for CLI apps or by wiring it in your own web app, out of the framework usage.

### CLI output at a glance

<img width="829" alt="screenshot 2017-08-11 a 19 52 57" src="https://user-images.githubusercontent.com/2211145/29225482-c24afe18-7ece-11e7-8e83-d019b0d8303e.PNG">

## Usage within the framework

### Config

For instance, in your `config_dev.yml`:

```yml
#config_dev.yml
debug:
    server_dump: true
```

or in your `config.yml`:

```yml
#config.yml
debug:
    server_dump: '%kernel.debug%'
```

~~The configuration also allows to set a `host` option, but there is already a sensible default value (`tcp://0.0.0.0:9912`) so you don't have to deal with it.~~ Since b002175, in case you want to change the default host value used, simply use the `VAR_DUMPER_SERVER` env var.

When the server is running, all dumps are collected by the server and previous dumpers ones are "swallowed" ~~by default. If you want both to collect dumps on the server AND keep previous dumpers on regular outputs, you can disable swallowing:~~

<!--
```yml
debug:
    server_dump:
        swallow: false
```
-->

When the server isn't running or in case of failure to send the data clones to the server, the server dumper will delegates to the configured wrapped dumper, so dumps are displayed and collected as usual.

### Running the server

```bash
bin/console server:dump [--format=cli|html]
```

#### Options

- ~~The `output` option defaults to `null` which will display dumps on CLI. It accepts a file path in which dumps will be collected in HTML format.~~
- The `format` option allows to switch format to use. For instance, use the `html` format and redirect the output to a file in order to open it in your browser and inspect dumps in HTML format.
- ~~The default `host` value is the same as the one configured under the `debug.server_dump.host` config option, so you don't have to deal with it in most cases.~~
    Since b002175, in case you want to change the default host value used, simply use the `VAR_DUMPER_SERVER` env var:

    ```bash
    VAR_DUMPER_SERVER=0.0.0.0:9204 bin/console server:dump
    ```

## Manual wiring

If you want to wire it yourself in your own project or using it to inspect dumps as html before the kernel is even boot for instance:

```php
$host = 'tcp://0.0.0.0:9912'; // use null to read from the VAR_DUMPER_SERVER env var
$cloner = new VarCloner();
$dumper = new ServerDumper($host, new CliDumper());

VarDumper::setHandler(function ($var) use ($dumper, $cloner) {
    $dumper->dump($cloner->cloneVar($var));
});
```

## Create your own server app

The component already provides a default server app by means of the `ServerDumpCommand`, but
 you could also build your own by using the `DumpServer`:

```php
$host = 'tcp://0.0.0.0:9912'; // use null to read from the VAR_DUMPER_SERVER env var

$server = new DumpServer($host);

$server->start();

$server->listen(function (Data $data, array $context, $clientId) {
    // do something
});
```

Commits
-------

138dad6440 [VarDumper] Some tweaks after Nicolas' commit & ServerDumperPlaceholderCommand
088c52ed70 [VarDumper] Review config to use debug.dump_destination & tweak data collector
3db14045d4 [VarDumper] Introduce a new way to collect dumps through a server dumper
2018-03-23 10:18:50 +01:00
Maxime Steinhausser
138dad6440 [VarDumper] Some tweaks after Nicolas' commit & ServerDumperPlaceholderCommand 2018-03-23 10:12:13 +01:00
Nicolas Grekas
088c52ed70 [VarDumper] Review config to use debug.dump_destination & tweak data collector
(cherry picked from commit 602b9a8)
2018-03-23 10:11:10 +01:00
Maxime Steinhausser
3db14045d4 [VarDumper] Introduce a new way to collect dumps through a server dumper 2018-03-23 10:11:09 +01:00
Fabien Potencier
e157dedc6a feature #24411 [Messenger] Add a new Messenger component (sroze)
This PR was squashed before being merged into the 4.1-dev branch (closes #24411).

Discussion
----------

[Messenger] Add a new Messenger component

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #24326
| License       | MIT
| Doc PR        | symfony/symfony-docs#9437

As discussed in #24326. This PR is to help going forward with the discussions of having a Message component.

# Resources

| What | Where
| --- | ---
| Documentation | [In the PR](https://github.com/sroze/symfony/blob/add-message-component/src/Symfony/Component/Message/README.md)
| Demo | [In `sroze/symfony-demo:message-component-demo`](https://github.com/sroze/symfony-demo/compare/message-component-demo)
| [php-enqueue](https://github.com/php-enqueue/enqueue-dev) adapter | 1. Source: [In `sroze/enqueue-bridge`](https://github.com/sroze/enqueue-bridge) _(to be moved as `symfony/enqueue-bridge` I guess)_<br/>2. Demo: [In `sroze/symfony-demo:message-component-demo-with-enqueue`](https://github.com/sroze/symfony-demo/compare/message-component-demo...sroze:message-component-demo-with-enqueue)
| [Swarrot](https://github.com/swarrot/swarrot) adapter | **Outdated adapter, waiting for stabilization** 1. Source: [In `sroze/swarrot-bridge`](https://github.com/sroze/swarrot-bridge) _(to be moved as `symfony/swarrot-bridge` I guess)_<br/>2. Demo: [In `sroze/symfony-demo:message-component-demo-with-swarrot`](https://github.com/sroze/symfony-demo/compare/message-component-demo...sroze:message-component-demo-with-swarrot)
| [HTTP](https://github.com/sroze/message-http-adapter) adapter | **Outdated adapter, waiting for stabilization** 1. Source: [In `sroze/message-http-adapter`](https://github.com/sroze/message-http-adapter) <br/>2. Demo: [In `sroze/symfony-demo:message-component-demo-with-http-adapter`](https://github.com/sroze/symfony-demo/compare/message-component-demo...sroze:message-component-demo-with-http-adapter)
| Web profiler integration | _In the pull-request_

# Important points

1. **Tests are not in the PR as they were written in PhpSpec & Behat.** If we decide to go forward with this approach, I'll translate them to PHPUnit.
2. The aim is not to solve all the message/queuing problems but provide a good, simple and extensible message bus for developers.
3. The communication with the actual AMQP/API brokers is down to the adapters for now. Not sure if we need to ship some by default or not 🤔

I guess that this would replace #23842 & #23315.

# Changes from the proposals

Based on the comments, a few changes have been made from the proposal.

1. `MessageProducer`s have been renamed to `MessageSender`s
2. `MessageConsumer`s have been renamed to `MessageReceiver`s

Commits
-------

c9cfda990b [Messenger] Add a new Messenger component
2018-03-23 09:01:57 +01:00
Samuel ROZE
c9cfda990b [Messenger] Add a new Messenger component 2018-03-23 09:01:52 +01:00
Fabien Potencier
acf49e9d85 feature #22150 [Serializer] Added a ConstraintViolationListNormalizer (lyrixx)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Serializer] Added a ConstraintViolationListNormalizer

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

---

It seems logical to me that Symfony is able to serialise natively some very common Symfony data structure. (and requested by @nicolas-grekas & @javiereguiluz )

Usage example (from symfony/symfony-demo):

```php
    /**
     * @Route("", name="api_blog_new")
     * @Method("POST")
     * @Security("is_granted('ROLE_ADMIN')")
     */
    public function newAction(Request $request)
    {
        $data = $request->getContent();

        $post = $this->get('serializer')->deserialize($data, Post::class, 'json', ['groups' => ['post_write']]);

        $post->setAuthor($this->getUser());

        $violations = $this->get('validator')->validate($post);

        $post->setSlug($this->get('slugger')->slugify($post->getTitle()));

        if (count($violations) > 0) {
            $repr = $this->get('serializer')->serialize($violations, 'json');

            return JsonResponse::fromJsonString($repr, 400);
        }

        $this->getDoctrine()->getManager()->persist($post);
        $this->getDoctrine()->getManager()->flush();

        $repr = $this->get('serializer')->serialize($post, 'json', ['groups' => ['post_read']]);

        return JsonResponse::fromJsonString($repr);
    }
```

Commits
-------

2a35d09f53 [Serializer] Added a ConstraintViolationListNormalizer
2018-03-23 08:59:18 +01:00
Grégoire Pineau
886b8a6e29 [SecurityBundle] Added an alias from RoleHierarchyInterface to security.role_hierarchy 2018-03-22 17:50:26 +01:00
Grégoire Pineau
2a35d09f53 [Serializer] Added a ConstraintViolationListNormalizer 2018-03-22 10:57:52 +01:00
Nicolas Grekas
2cfc57315e [WebProfilerBundle] use the router to resolve file links 2018-03-21 20:24:29 +01:00
Fabien Potencier
07a2f6cef4 feature #26092 [Workflow] Add a MetadataStore to fetch some metadata (lyrixx)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Workflow] Add a MetadataStore to fetch some metadata

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | yes (little)
| Deprecations? | yes
| Tests pass?   | yes
| Fixed tickets | #23257
| License       | MIT
| Doc PR        | TODO

---

This is an attempt to fix #23257. I first started to implement
`Ẁorkflow::getMetadata()`, `Transition::getMetadata()` and
`Place::getMetadata()`. **BUT**, there are no `Place` class. For now it's just a
`string`. So dealing with BC is a nightmare.

So I tried to find another way to fix the issue. [This
comment](https://github.com/symfony/symfony/issues/23257#issuecomment-315551397)
summary well the two options. But this PR is (will be) a mix of theses 2
options.

First it will be possible to configure the workflow/metadata like this:

```yaml
blog_publishing:
    supports:
        - AppBundle\Entity\BlogPost
    metada:
         label: Blog publishing
         description: Manages blog publishing
    places:
        draft:
            metadata:
                 description: Blog has just been created
                 color: grey
        review:
            metadata:
                 description: Blog is waiting for review
                 color: blue
    transitions:
        to_review:
            from: draft
            to: review
            metadata:
                label: Submit for review
                route: admin.blog.review
```

I think is very good for the DX. Simple to understand.

All metadata will live in a `MetadataStoreInterface`. If metadata are set via
the configuration (workflows.yaml), then we will use the
`InMemoryMetadataStore`.

Having a MetadataStoreInterface allow user to get dynamic value for a place /
transitions. It's really flexible. (But is it a valid use case ?)

Then, to retrieve these data, the end user will have to write this code:

```php
public function onReview(Event $event) {
    $metadataStore = $event->getWorkflow()->getMetadataStore();
    foreach ($event->getTransition()->getTos() as $place) {
        $this->flashbag->add('info', $metadataStore->getPlaceMetadata($place)->get('description'));
    }
}
```

Note: I might add some shortcut to the Event class

or in twig:

```jinja
{% for transition in workflow_transitions(post) %}
    <a href="{{ workflow_metadata_transition(post, route) }}">
         {{ workflow_metadata_transition(post, transition) }}
   </a>
{% endfor %}
```

---

WDYT ?

Should I continue this way, or should I introduce a `Place` class (there will be
so many deprecation ...)

Commits
-------

bd1f2c8583 [Workflow] Add a MetadataStore
2018-03-21 11:17:02 +01:00
Grégoire Pineau
bd1f2c8583 [Workflow] Add a MetadataStore 2018-03-21 11:06:23 +01:00
Fabien Potencier
14ab56e6fc feature #26121 [FrameworkBundle] feature: add the ability to search a route (Simperfit)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] feature: add the ability to search a route

| Q             | A
| ------------- | ---
| Branch?       | 4.1
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes
| Fixed tickets | #26033
| License       | MIT
| Doc PR        | symfony/symfony-docs#9236

This add the ability to search a route in the debug:router command.
![img_3271](https://user-images.githubusercontent.com/3451634/36034017-e60cbfda-0db2-11e8-841a-60bc75b0b631.jpeg)

Commits
-------

ef0df02afc [FrameworkBundle] feature: add the ability to search a route
2018-03-21 10:59:31 +01:00
Grégoire Pineau
60730666ab [FrameworkBundle] Partially revert HttpCache is not longer abstract (4d075da) 2018-03-21 10:56:17 +01:00
Amrouche Hamza
ef0df02afc
[FrameworkBundle] feature: add the ability to search a route 2018-03-21 10:40:34 +01:00
Fabien Potencier
a1b1a44a7b feature #25197 [FrameworkBundle][TwigBridge] make csrf_token() usable without forms (xabbuh)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle][TwigBridge] make csrf_token() usable without forms

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

The Twig function `csrf_token()` is currently only registered when the
Form component is installed. However, this function is also useful, for
example, when creating simple login forms for which you do not need the
full Form component.

Commits
-------

709efa30fc make csrf_token() usable without forms
2018-03-21 10:10:25 +01:00
Nicolas Grekas
2ca8657547 Merge branch '4.0'
* 4.0: (32 commits)
  [Form] fix tests and deps
  [Cache] Rely on mock for Doctrine ArrayCache
  [FrameworkBundle] Respect debug mode when warm up annotations
  [Console] Fix docblock of DescriptorInterface::describe
  [Config] Handle nullable node name + fix inheritdocs
  [Security] added userChecker to SimpleAuthenticationProvider
  [Debug] fix test
  Fix typo in test method name
  Fixes #26563 (open_basedir restriction in effect)
  [Debug] Reset previous exception handler ealier to prevent infinite loop
  add hint in Github pull request template
  [Validator] Fix docblock of ClassMetadata#members
  [BrowserKit] Fix cookie path handling when $domain is null
  [DoctrineBridge] Don't rely on ClassMetadataInfo->hasField in DoctrineOrmTypeGuesser anymore
  [BrowserKit] Improves CookieJar::get
  [BrowserKit] Fix Cookie's PHPDoc
  [DomCrawler] Change bad wording in ChoiceFormField::untick
  [DomCrawler] Fix the PHPDoc of ChoiceFormField::setValue
  [DomCrawler] Avoid a useless call to strtolower
  [FrameworkBundle] HttpCache is not longer abstract
  ...
2018-03-19 23:38:22 +01:00
Nicolas Grekas
1f119cc16c Merge branch '3.4' into 4.0
* 3.4: (32 commits)
  [Form] fix tests and deps
  [Cache] Rely on mock for Doctrine ArrayCache
  [FrameworkBundle] Respect debug mode when warm up annotations
  [Console] Fix docblock of DescriptorInterface::describe
  [Config] Handle nullable node name + fix inheritdocs
  [Security] added userChecker to SimpleAuthenticationProvider
  [Debug] fix test
  Fix typo in test method name
  Fixes #26563 (open_basedir restriction in effect)
  [Debug] Reset previous exception handler ealier to prevent infinite loop
  add hint in Github pull request template
  [Validator] Fix docblock of ClassMetadata#members
  [BrowserKit] Fix cookie path handling when $domain is null
  [DoctrineBridge] Don't rely on ClassMetadataInfo->hasField in DoctrineOrmTypeGuesser anymore
  [BrowserKit] Improves CookieJar::get
  [BrowserKit] Fix Cookie's PHPDoc
  [DomCrawler] Change bad wording in ChoiceFormField::untick
  [DomCrawler] Fix the PHPDoc of ChoiceFormField::setValue
  [DomCrawler] Avoid a useless call to strtolower
  [FrameworkBundle] HttpCache is not longer abstract
  ...
2018-03-19 23:35:49 +01:00
Nicolas Grekas
34d5b5eb99 Merge branch '2.8' into 3.4
* 2.8: (29 commits)
  [Console] Fix docblock of DescriptorInterface::describe
  [Config] Handle nullable node name + fix inheritdocs
  [Security] added userChecker to SimpleAuthenticationProvider
  [Debug] fix test
  Fix typo in test method name
  Fixes #26563 (open_basedir restriction in effect)
  [Debug] Reset previous exception handler ealier to prevent infinite loop
  add hint in Github pull request template
  [Validator] Fix docblock of ClassMetadata#members
  [BrowserKit] Fix cookie path handling when $domain is null
  [DoctrineBridge] Don't rely on ClassMetadataInfo->hasField in DoctrineOrmTypeGuesser anymore
  [BrowserKit] Improves CookieJar::get
  [BrowserKit] Fix Cookie's PHPDoc
  [DomCrawler] Change bad wording in ChoiceFormField::untick
  [DomCrawler] Fix the PHPDoc of ChoiceFormField::setValue
  [DomCrawler] Avoid a useless call to strtolower
  [FrameworkBundle] HttpCache is not longer abstract
  Php Inspections (EA Ultimate): address some of one-time used local variables
  [Intl] Load locale aliases to support alias fallbacks
  [CssSelector] Fix CSS identifiers parsing - they can start with dash
  ...
2018-03-19 23:32:39 +01:00
Fabien Potencier
28f4662935 bug #26513 [FrameworkBundle] Respect debug mode when warm up annotations (Strate)
This PR was squashed before being merged into the 3.4 branch (closes #26513).

Discussion
----------

[FrameworkBundle] Respect debug mode when warm up annotations

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

Propagate current debug mode to the annotations reader. Without thi, warmup is useless with debug mode, because timetsamps are not written to cache.

Commits
-------

f3ec39616c [FrameworkBundle] Respect debug mode when warm up annotations
2018-03-19 22:13:45 +01:00
Artur Eshenbrener
f3ec39616c [FrameworkBundle] Respect debug mode when warm up annotations 2018-03-19 22:13:45 +01:00
Nicolas Grekas
af6be350e6 Merge branch '2.7' into 2.8
* 2.7:
  [Config] Handle nullable node name + fix inheritdocs
  [Security] added userChecker to SimpleAuthenticationProvider
  [Debug] fix test
  Fix typo in test method name
  Fixes #26563 (open_basedir restriction in effect)
  [Debug] Reset previous exception handler ealier to prevent infinite loop
  add hint in Github pull request template
  [Validator] Fix docblock of ClassMetadata#members
  [BrowserKit] Fix cookie path handling when $domain is null
  [DoctrineBridge] Don't rely on ClassMetadataInfo->hasField in DoctrineOrmTypeGuesser anymore
  [BrowserKit] Improves CookieJar::get
  [BrowserKit] Fix Cookie's PHPDoc
  [DomCrawler] Change bad wording in ChoiceFormField::untick
  [DomCrawler] Fix the PHPDoc of ChoiceFormField::setValue
  [DomCrawler] Avoid a useless call to strtolower
  [FrameworkBundle] HttpCache is not longer abstract
  [DomCrawler] extract(): fix a bug when the attribute list is empty
  [Config] Backport string|null api for node names
2018-03-19 22:11:56 +01:00
Boris Vujicic
cb9c92d065 [Security] added userChecker to SimpleAuthenticationProvider 2018-03-19 21:02:10 +01:00
Nicolas Grekas
5e5216017a Merge branch '4.0'
* 4.0: (28 commits)
  [DI] Add tests for EnvVarProcessor
  typo
  [Bridge\PhpUnit] Fix #26430 Cannot autoload listeners
  Make sure we always render errors. Eventhough labels are disabled
  Make sure form errors is valid HTML
  [HttpKernel] Allow generators in registerBundle
  [TwigBundle] document TwigRenderer BC break in UPGRADE-3.4
  Extra line to bootstrap 3 horizontal layout
  [Serializer] Remove const override
  Update Client.php
  [PhpUnitBridge] Ability to use different composer.json file
  [DomCrawler] FormField: remove an useless return statement
  [Config] ReflectionClassResource check abstract ServiceSubscriberInterface and EventSubscriberInterface
  Display the Welcome Page when there is no homepage defined
  [DI] Remove dead dumper check
  Make KernelInterface docblock more fit for bundle-less environment
  fix regression when extending the Container class without a constructor
  fix the updating of timestamp in the MemcachedSessionHandler
  [SecurityBundle] Make extra character non mandatory in regex
  [Config] Add characters to the regex
  ...
2018-03-19 18:34:12 +01:00
Nicolas Grekas
72041c8821 Merge branch '3.4' into 4.0
* 3.4: (22 commits)
  [DI] Add tests for EnvVarProcessor
  [Bridge\PhpUnit] Fix #26430 Cannot autoload listeners
  Make sure we always render errors. Eventhough labels are disabled
  Make sure form errors is valid HTML
  [HttpKernel] Allow generators in registerBundle
  [TwigBundle] document TwigRenderer BC break in UPGRADE-3.4
  Extra line to bootstrap 3 horizontal layout
  [Serializer] Remove const override
  Update Client.php
  [PhpUnitBridge] Ability to use different composer.json file
  [DomCrawler] FormField: remove an useless return statement
  [Config] ReflectionClassResource check abstract ServiceSubscriberInterface and EventSubscriberInterface
  Display the Welcome Page when there is no homepage defined
  fix regression when extending the Container class without a constructor
  fix the updating of timestamp in the MemcachedSessionHandler
  [SecurityBundle] Make extra character non mandatory in regex
  [Config] Add characters to the regex
  bumped Symfony version to 3.4.7
  updated VERSION for 3.4.6
  updated CHANGELOG for 3.4.6
  ...
2018-03-19 18:30:36 +01:00
Nicolas Grekas
7ae529291f bug #26273 [Security][Profiler] Display the original expression in 'Access decision log' (lyrixx)
This PR was merged into the 3.4 branch.

Discussion
----------

[Security][Profiler] Display the original expression in 'Access decision log'

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

---

before:

![screenshot at 2018-02-22 18-22-28](https://user-images.githubusercontent.com/408368/36553752-798001ba-17fd-11e8-9539-254a25a01e60.png)

after:

![after](https://user-images.githubusercontent.com/408368/36553856-b7449fe2-17fd-11e8-94cb-ddaf4f033511.png)

Commits
-------

8f16c2e [Security][Profiler] Display the original expression in 'Access decision log'
2018-03-19 18:03:08 +01:00
Nicolas Grekas
9446fa01c4 minor #26592 [FrameworkBundle] Use a::b notation in ControllerTrait docblock (hacfi)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] Use `a::b` notation in ControllerTrait docblock

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

<!--
Write a short README entry for your feature/bugfix here (replace this comment block.)
This will help people understand your PR and can be used as a start of the Doc PR.
Additionally:
 - Bug fixes must be submitted against the lowest branch where they apply
   (lowest branches are regularly merged to upper ones so they get the fixes too).
 - Features and deprecations must be submitted against the master branch.
-->

Replaced the deprecated the bundle notation with the new `a::b` notation in the docblock of `ControllerTrait::forward`

Commits
-------

973c5ec [FrameworkBundle] Use `a::b` notation in ControllerTrait docblock
2018-03-19 13:53:48 +01:00
Philipp Wahala
973c5ec995 [FrameworkBundle] Use a::b notation in ControllerTrait docblock 2018-03-18 18:57:30 +01:00
Florent Mata
4110d57da1 [HttpFoundation] deprecate call to Request::getSession() when Request::hasSession() returns false 2018-03-17 16:02:11 +01:00
Nicolas Grekas
5cf0a2ea8f feature #26499 [FrameworkBundle] Allow fetching private services from test clients (nicolas-grekas)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] Allow fetching private services from test clients

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

With this PR, `$client->getContainer()` returns a special container that gives access to private services as if they were public.

Tests derived from `WebTestCase` and `KernelTestCase` can access this special container by using the new `static::$container` property.

Commits
-------

a840809 [FrameworkBundle] Allow fetching private services from test clients
2018-03-16 10:51:38 +01:00
Fabien Potencier
bf120d042b feature #26288 [FrameworkBundle] show the unregistered command warning at the end of the list command (Simperfit)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] show the unregistered command warning at the end of the list command

| Q             | A
| ------------- | ---
| Branch?       | 4.1
| Bug fix?      | no
| New feature?  | yes   <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no   <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #26203  <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | I don't think we need one.

This PR modify the warning error when you have unregistered command on the list command, it shows it at the end.

Commits
-------

99b104ab5c [FrameworkBundle] show the unregistered command warning at the end of the list command
2018-03-15 09:35:44 -07:00
Grégoire Pineau
4d075da934 [FrameworkBundle] HttpCache is not longer abstract 2018-03-15 10:35:06 +01:00
Amrouche Hamza
99b104ab5c
[FrameworkBundle] show the unregistered command warning at the end of the list command 2018-03-14 12:19:56 +01:00
Javier Eguiluz
547076e3ea Added some HTML5 features to the Symfony Profiler 2018-03-14 10:51:38 +01:00
Nicolas Grekas
a840809e5d [FrameworkBundle] Allow fetching private services from test clients 2018-03-13 12:50:01 +01:00
Fabien Potencier
009b4d216e feature #26398 [WebProfilerBundle] Display the missing translation panel by default (javiereguiluz)
This PR was squashed before being merged into the 4.1-dev branch (closes #26398).

Discussion
----------

[WebProfilerBundle] Display the missing translation panel by default

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Display the "Missing Translations" panel by default ... except if there are no missing translations.

Commits
-------

15fe686a58 [WebProfilerBundle] Display the missing translation panel by default
2018-03-10 15:12:02 -06:00
Javier Eguiluz
15fe686a58 [WebProfilerBundle] Display the missing translation panel by default 2018-03-10 15:12:00 -06:00
David Prévot
44b4fc8db5 [SecurityBundle] Make extra character non mandatory in regex
The extra character was introduced in 5f9471e, and breaks the testsuite
in native php 7.2.
2018-03-05 22:53:32 -10:00
Javier Eguiluz
21ee76c0ad Made the translation profiler panel more compact 2018-03-05 16:26:36 +01:00
Nicolas Grekas
710a189e83 Merge branch '2.7' into 2.8
* 2.7:
  [WebProfilerBundle] fix wrong variable for profiler counting ajax requests
2018-03-02 16:25:13 +01:00
Marin Nicolae
0fb83af015 [WebProfilerBundle] fix wrong variable for profiler counting ajax requests 2018-03-02 16:24:40 +01:00
Nicolas Grekas
1f7b9f0fc5 feature #26223 [FrameworkBundle] Add command to delete an item from a cache pool (pierredup)
This PR was squashed before being merged into the 4.1-dev branch (closes #26223).

Discussion
----------

[FrameworkBundle] Add command to delete an item from a cache pool

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

Currently there is no way to clear a specific item from a cache pool (except programatically), the entire pool needs to be cleared.
Especially during development, when implementing caching, it is useful to delete a specific key to test functionality. Clearing the entire pool, means that everything will need to be cached again, adding unnecessary execution time.

I propose adding a new command, `cache:pool:delete` to delete a specific item from a cache pool

Commits
-------

fd43e81 [FrameworkBundle] Add command to delete an item from a cache pool
2018-03-02 13:13:05 +01:00
Pierre du Plessis
fd43e81fd7 [FrameworkBundle] Add command to delete an item from a cache pool 2018-03-02 13:13:00 +01:00
Nicolas Grekas
acb5d9f9a1 Merge branch '4.0'
* 4.0:
  [WebProfilerBundle] Fix Debug toolbar breaks app
  Use fill instead of style for svg colors
  bumped Symfony version to 4.0.6
  updated VERSION for 4.0.5
  updated CHANGELOG for 4.0.5
  bumped Symfony version to 3.4.6
  updated VERSION for 3.4.5
  updated CHANGELOG for 3.4.5
  bumped Symfony version to 2.8.36
  updated VERSION for 2.8.35
  updated CHANGELOG for 2.8.35
  [FrameworkBundle] Silence "Failed to remove directory" on cache:clear
  bumped Symfony version to 2.7.43
  updated VERSION for 2.7.42
  update CONTRIBUTORS for 2.7.42
  updated CHANGELOG for 2.7.42
2018-03-02 09:29:06 +01:00
Nicolas Grekas
1c826ca0f3 Merge branch '3.4' into 4.0
* 3.4:
  [WebProfilerBundle] Fix Debug toolbar breaks app
  Use fill instead of style for svg colors
  bumped Symfony version to 3.4.6
  updated VERSION for 3.4.5
  updated CHANGELOG for 3.4.5
  bumped Symfony version to 2.8.36
  updated VERSION for 2.8.35
  updated CHANGELOG for 2.8.35
  [FrameworkBundle] Silence "Failed to remove directory" on cache:clear
  bumped Symfony version to 2.7.43
  updated VERSION for 2.7.42
  update CONTRIBUTORS for 2.7.42
  updated CHANGELOG for 2.7.42
2018-03-02 09:28:17 +01:00
Nicolas Grekas
fe4d055bd7 Merge branch '2.8' into 3.4
* 2.8:
  [WebProfilerBundle] Fix Debug toolbar breaks app
  bumped Symfony version to 2.8.36
  updated VERSION for 2.8.35
  updated CHANGELOG for 2.8.35
  bumped Symfony version to 2.7.43
  updated VERSION for 2.7.42
  update CONTRIBUTORS for 2.7.42
  updated CHANGELOG for 2.7.42
2018-03-02 09:27:00 +01:00
Nicolas Grekas
aa8254ce2f Merge branch '2.7' into 2.8
* 2.7:
  [WebProfilerBundle] Fix Debug toolbar breaks app
  bumped Symfony version to 2.7.43
  updated VERSION for 2.7.42
  update CONTRIBUTORS for 2.7.42
  updated CHANGELOG for 2.7.42
2018-03-02 09:25:37 +01:00
Nicolas Grekas
b2df671912 feature #26341 Autoconfigure service locator tag (apfelbox)
This PR was squashed before being merged into the 4.1-dev branch (closes #26341).

Discussion
----------

Autoconfigure service locator tag

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

We will now also autoconfigure the (required) tag `container.service_locator` for all `ServiceLocator`s.

I couldn't find any integration tests for the whole list of autoconfigured core services, so I didn't add any new tests.

Commits
-------

c4b9b42 Autoconfigure service locator tag
2018-03-02 09:24:43 +01:00
Jannik Zschiesche
c4b9b4252b Autoconfigure service locator tag 2018-03-02 09:24:40 +01:00
Xavier HAUSHERR
52f187e86a [WebProfilerBundle] Fix Debug toolbar breaks app 2018-03-02 09:20:32 +01:00
Remon van de Kamp
e29677858f
Use fill instead of style for svg colors
Using style does not work when a Content Security Policy is in place,
resulting in non-styles (black) images instead of grey.
2018-03-02 09:07:37 +01:00
Nicolas Grekas
3ba624af9f [FrameworkBundle] Silence "Failed to remove directory" on cache:clear 2018-03-01 15:51:10 +01:00
Nicolas Grekas
d1b67a561c fix test 2018-03-01 11:49:02 +01:00
Fabien Potencier
97cee3a157 Merge branch '4.0'
* 4.0:
  [Form][WCAG] Add hidden labels on date and time fields
  Pass on previous exception in FatalThrowableError
  [Routing] remove dead code
  [Routing] fix typo
  [Form][WCAG] Fixed HTML errors
  fix merge
  [FrameworkBundle] [Console] add a warning when command is not found
  [WebProfilerBundle] limit ajax request to 100 and remove the last one
2018-02-28 13:50:15 -08:00
Fabien Potencier
96aac17c0d Merge branch '3.4' into 4.0
* 3.4:
  [Form][WCAG] Add hidden labels on date and time fields
  Pass on previous exception in FatalThrowableError
  [Routing] remove dead code
  [Routing] fix typo
  [Form][WCAG] Fixed HTML errors
  fix merge
  [FrameworkBundle] [Console] add a warning when command is not found
  [WebProfilerBundle] limit ajax request to 100 and remove the last one
2018-02-28 13:50:02 -08:00
Grégoire Pineau
8f16c2e39e [Security][Profiler] Display the original expression in 'Access decision log' 2018-02-28 09:32:47 +01:00
Nicolas Grekas
4a9e5c7099 minor #26270 [WebProfilerBundle] limit ajax request to 100 and remove the last one (Simperfit)
This PR was merged into the 3.4 branch.

Discussion
----------

[WebProfilerBundle] limit ajax request to 100 and remove the last one

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | none fix merge
| License       | MIT

Merging back the bugfix to 3.4.

Commits
-------

33bace4 [WebProfilerBundle] limit ajax request to 100 and remove the last one
2018-02-27 19:18:46 +01:00
Robin Chalas
5781b8f1a1 [SecurityBundle] Deprecate switch_user.stateless config node 2018-02-27 15:11:07 +01:00
Fabien Potencier
4261b19e75 bug #26290 [FrameworkBundle] [Console][DX] add a warning when command is not found (Simperfit)
This PR was merged into the 3.4 branch.

Discussion
----------

[FrameworkBundle] [Console][DX] add a warning when command is not found

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | none
| License       | MIT
| Doc PR        |

This PR add DX on the the console `find()` and `get()` methods when a command is not found because it has not been registered properly.

Commits
-------

efd8f7fa3a [FrameworkBundle] [Console] add a warning when command is not found
2018-02-27 08:02:49 +01:00
Nicolas Grekas
d419fd4cc8 fix merge 2018-02-26 19:35:35 +01:00
Nicolas Grekas
f06fa04ff1 Merge branch '4.0'
* 4.0:
  Fix typos
  [Routing] remove useless failing mocks
  [appveyor] Workaround GitHub disabling of low versions of TLS
  Use long array syntax
  [Routing] Fix GC control of PHP-DSL
  [Routing] Don't throw 405 when scheme requirement doesn't match
  [Routing] Revert throwing 405 on missed slash/scheme redirections
  [WebProfilerBundle] fix test after ajax path updated
  Fix ArrayInput::toString() for InputArgument::IS_ARRAY args
  Update excluded_ajax_paths for sf4
  Add missing use for RoleInterface
  Add missing use of Role
  [Routing] fix CS
  add container.autowiring.strict_mode to 3.4 docs
  Set controller without __invoke method from invokable class
  [VarDumper] Fixed PHPDoc
2018-02-26 18:04:28 +01:00
Nicolas Grekas
b56674720c Merge branch '3.4' into 4.0
* 3.4:
  [Routing] remove useless failing mocks
  [appveyor] Workaround GitHub disabling of low versions of TLS
  Use long array syntax
  [Routing] Fix GC control of PHP-DSL
  [Routing] Don't throw 405 when scheme requirement doesn't match
  [Routing] Revert throwing 405 on missed slash/scheme redirections
  [WebProfilerBundle] fix test after ajax path updated
  Fix ArrayInput::toString() for InputArgument::IS_ARRAY args
  Update excluded_ajax_paths for sf4
  Add missing use for RoleInterface
  [Routing] fix CS
  add container.autowiring.strict_mode to 3.4 docs
  Set controller without __invoke method from invokable class
  [VarDumper] Fixed PHPDoc
2018-02-26 16:55:47 +01:00
Fabien Potencier
52af59fd48 bug #26275 Set controller without __invoke method from invokable class (Tobion)
This PR was merged into the 3.4 branch.

Discussion
----------

Set controller without __invoke method from invokable class

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets |
| License       | MIT
| Doc PR        |

Fixes one part of #25103

Commits
-------

cc68c5074e Set controller without __invoke method from invokable class
2018-02-26 05:28:34 +01:00
Tobias Schultze
cd5f4105a4 minor #26280 [FrameworkBundle] clarify changelog and upgrade instructions (xabbuh)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[FrameworkBundle] clarify changelog and upgrade instructions

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/pull/24894#discussion_r169172405
| License       | MIT
| Doc PR        |

Commits
-------

a8df0aee92 clarify changelog and upgrade instructions
2018-02-25 16:08:35 +01:00
Amrouche Hamza
efd8f7fa3a
[FrameworkBundle] [Console] add a warning when command is not found 2018-02-25 09:26:30 +01:00
Amrouche Hamza
77dfc90846
[WebProfilerBundle] fix test after ajax path updated 2018-02-24 20:41:23 +01:00
Houziaux mike
ce01097935 Update excluded_ajax_paths for sf4 2018-02-24 12:14:39 +01:00
Christian Flothmann
3b092a08ea fix lowest supported Serializer version
The `AbstractObjectNormalizer::setMaxDepthHandler()` method does not
exist before `symfony/serializer` 4.1.
2018-02-23 14:04:00 +01:00
Christian Flothmann
a8df0aee92 clarify changelog and upgrade instructions 2018-02-23 09:21:43 +01:00
Tobias Schultze
cc68c5074e Set controller without __invoke method from invokable class 2018-02-23 00:30:18 +01:00
Amrouche Hamza
33bace44d4
[WebProfilerBundle] limit ajax request to 100 and remove the last one 2018-02-22 15:11:08 +01:00
Nicolas Grekas
3609744ab8 Merge branch '4.0'
* 4.0:
  [Translation] Process multiple segments within a single unit.
  Document the container.autowiring.strict_mode option
  fix custom radios/inputs for checkbox/radio type
  Another PR template tweak
  [FrameworkBundle] Add missing XML config for circular_reference_handler. Add tests.
  fix CS
  [PropertyInfo] ReflectionExtractor: give a chance to other extractors if no properties
  Clean calls to http_build_query()
  [WebProfilerBundle] limit ajax request to 100 and remove the last one
  Add support for URL-like DSNs for the PdoSessionHandler
  removed version in @final @internal for version < 4.0
  [HttpFoundation] Fix missing "throw" in JsonResponse
  Improve the documentation of
  Suppress warning from sapi_windows_vt100_support on stream other than STDIO
  removed extra-verbose comments
  Fixes #26136: Avoid emitting warning in hasParameterOption()
  Added a README entry to the PR template
  [HttpFoundation] Add x-zip-compressed to MimeTypeExtensionGuesser.
  [DI] Add null check for removeChild
2018-02-22 12:40:25 +01:00
Nicolas Grekas
0dc6acb123 Merge branch '3.4' into 4.0
* 3.4:
  [Translation] Process multiple segments within a single unit.
  Document the container.autowiring.strict_mode option
  fix custom radios/inputs for checkbox/radio type
  Another PR template tweak
  [FrameworkBundle] Add missing XML config for circular_reference_handler. Add tests.
  fix CS
  [PropertyInfo] ReflectionExtractor: give a chance to other extractors if no properties
  Clean calls to http_build_query()
  [WebProfilerBundle] limit ajax request to 100 and remove the last one
  Add support for URL-like DSNs for the PdoSessionHandler
  [HttpFoundation] Fix missing "throw" in JsonResponse
  Improve the documentation of
  Suppress warning from sapi_windows_vt100_support on stream other than STDIO
  removed extra-verbose comments
  Fixes #26136: Avoid emitting warning in hasParameterOption()
  Added a README entry to the PR template
  [HttpFoundation] Add x-zip-compressed to MimeTypeExtensionGuesser.
  [DI] Add null check for removeChild
2018-02-22 11:50:29 +01:00
Nicolas Grekas
124d338446 Merge branch '2.7' into 2.8
* 2.7:
  Another PR template tweak
  [WebProfilerBundle] limit ajax request to 100 and remove the last one
2018-02-22 11:35:54 +01:00
Nicolas Grekas
716adf8641 [HttpKernel] Fix BC of the test suite 2018-02-22 11:30:42 +01:00
Fabien Potencier
6651087a98 feature #26085 Deprecate bundle:controller:action and service:method notation (Tobion)
This PR was squashed before being merged into the 4.1-dev branch (closes #26085).

Discussion
----------

Deprecate bundle:controller:action and service:method notation

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

The `a::b` notation had some awkward limitations. It supported `MyControllerClass::method` where `MyControllerClass` is either plain class or a service with the same name but the class must exists. This meant it did NOT support `my_service_controller_id::method` because the `class_exists` check would fail at the wrong point in time. But it did support services where class name == id, i.e. the new auto registration based psr naming. This made it very confusing.

I enhanced the `a::b` notation to be very straight forward:
- if `a` exists as a service then use `a` as a service
- otherwise try to use `a` as a class, i.e. `new $a()`
- otherwise check if a::b is a static method (only relevant when the class is abstract or has private contructor). this was potentially supported when using array controller syntax. it now works the same when using the `::` string syntax, like in php itself. since it only happens when nothing else works, it does not have any performance impact.

The old `a:b` syntax is deprecated and just forwards to `a::b` now internally, just as bundle:controller:action.
In general I was able to refactor the logic quite a bit because it always goes through `instantiateController` now.
Spotting deprecated usages is very easy as all outdated routing configs will trigger a deprecation with the DelegatingLoader and it will be normalized in the dumped routes. So you don't get a deprecation again in the ControllerResolver. But if the controller does not come from routing, e.g. twigs render controller function, then it will still be triggered there.

- [x] deprecate `a🅱️c`
- [x] deprecate `a:b`
- [x] update existing references to `a::b`
- [x] fix tests
- [x] fix/add support for static controllers
- [x] add support for closures as controllers
- [x] update Symfony\Component\Routing\Loader\ObjectRouteLoader
- [x] deprecate \Symfony\Bundle\FrameworkBundle\Controller\ControllerNameParser but we still need to use it in several places for BC.
- [x] add changelog/upgrade
- [x] update controller.service_arguments logic for double colon controller syntax

Commits
-------

f8a609cdbd Deprecate bundle:controller:action and service:method notation
2018-02-21 06:14:06 +01:00
Tobias Schultze
f8a609cdbd Deprecate bundle:controller:action and service:method notation 2018-02-21 06:14:04 +01:00
Fabien Potencier
2711d144b1 feature #26175 [Security] Add configuration for Argon2i encryption (CoalaJoe)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Security] Add configuration for Argon2i encryption

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #26174
| License       | MIT
| Doc PR        | [#9300](https://github.com/symfony/symfony-docs/pull/9300)

Feedback?

Current situation: Configuration only applies if argon2i is natively supported.

Commits
-------

1300fece5f [Security] Add configuration for Argon2i encryption
2018-02-20 21:36:26 +01:00
Ashura
1300fece5f [Security] Add configuration for Argon2i encryption 2018-02-20 13:01:36 +01:00
Fabien Potencier
3cb5619216 feature #26108 [Serializer] Add a MaxDepth handler (dunglas)
This PR was squashed before being merged into the 4.1-dev branch (closes #26108).

Discussion
----------

[Serializer] Add a MaxDepth handler

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes <!-- don't forget to update src/**/CHANGELOG.md files -->
| BC breaks?    | no
| Deprecations? | no <!-- don't forget to update UPGRADE-*.md files -->
| Tests pass?   | yes
| Fixed tickets | api-platform/core#1130, api-platform/core#1528, api-platform/core#1528 <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | todo <!--highly recommended for new features-->

Sometimes, instead of just stopping the serialization process when the configured max depth is reached, it can be interesting to let the user return something (like returning the identifier of the entity to stop manually the serialization process).

This PR also makes the max depth handling more similar to circular references handling (that already has the possibility to set a handler).

Commits
-------

ed975c764b [Serializer] Add a MaxDepth handler
2018-02-19 21:26:23 +01:00
Kévin Dunglas
ed975c764b [Serializer] Add a MaxDepth handler 2018-02-19 21:26:22 +01:00
Fabien Potencier
43f8081d60 minor #26225 Make deprecation notices less verbose (fabpot)
This PR was merged into the 4.1-dev branch.

Discussion
----------

Make deprecation notices less verbose

| 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

I think there is no need to say that deprecated features will be removed in the next major version. That makes messages more verbose for no real reasons.

Commits
-------

0c6ec3fec0 made deprecation notices less verbose
2018-02-19 21:13:12 +01:00
Fabien Potencier
389efc0af3 minor #26229 removed version in @final @internal for version < 4.0 (fabpot)
This PR was merged into the 4.0 branch.

Discussion
----------

removed version in @final @internal for version < 4.0

| 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

On 4.0+, I think we can removed the "since version 3.x" from `@final` and `@internal` annotations. I've kept them for things that reference version 4.x.

Commits
-------

ed27b12d2c removed version in @final @internal for version < 4.0
2018-02-19 21:08:53 +01:00
Kévin Dunglas
611ff59c3e
[FrameworkBundle] Add missing XML config for circular_reference_handler. Add tests. 2018-02-19 19:14:07 +01:00
Nicolas Grekas
49759e3138 Merge branch '4.0'
* 4.0:
  [Bridge/Twig] fix composer.json
  bug #26086 [FrameworkBundle] Fix using annotation_reader in compiler pass to inject configured cache provider
  [WebProfilerBundle] Fix anchor CSS
  [HttpKernel] Send new session cookie from AbstractTestSessionListener after session invalidation
  [WebProfilerBundle] Tweak default route name
  updated StopwatchEvent phpdoc due to the additional of optional float precision introduced in 0db8d7fb6a
  Retro-fit proxy code to make it deterministic for older proxy manager implementations
  [Serializer] remove unneeded php doc line
  Yaml parser regression with comments and non-strings
  Fixed broken tests
  [TwigBridge] Apply some changes to support Bootstrap4-stable
2018-02-19 17:51:42 +01:00
Nicolas Grekas
2871a96fa7 Merge branch '3.4' into 4.0
* 3.4:
  [Bridge/Twig] fix composer.json
  bug #26086 [FrameworkBundle] Fix using annotation_reader in compiler pass to inject configured cache provider
  [WebProfilerBundle] Fix anchor CSS
  [HttpKernel] Send new session cookie from AbstractTestSessionListener after session invalidation
  [WebProfilerBundle] Tweak default route name
  updated StopwatchEvent phpdoc due to the additional of optional float precision introduced in 0db8d7fb6a
  Retro-fit proxy code to make it deterministic for older proxy manager implementations
  Yaml parser regression with comments and non-strings
  Fix undiscoverablility of SymfonyTestsListenerForV7
  Fixed broken tests
  [TwigBridge] Apply some changes to support Bootstrap4-stable
2018-02-19 17:50:22 +01:00
Nicolas Grekas
0aedb03af6 bug #26088 [FrameworkBundle] Fix using annotation_reader in compiler pass to inject configured cache provider (Laizerox)
This PR was merged into the 3.4 branch.

Discussion
----------

[FrameworkBundle] Fix using annotation_reader in compiler pass to inject configured cache provider

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

The compilation pass of AddAnnotationsCachedReaderPass relies on already removed definition `annotations.cached_reader` due to an alias to `annotation_reader`.

Since the definition is being removed because of alias, configured annotation cache provider is not injected and will default back to ArrayCache.

This PR replaces the use of `annotations.cached_reader` to `annotation_reader` to complete the injection of configured cache provider.

Commits
-------

dfd93da bug #26086 [FrameworkBundle] Fix using annotation_reader in compiler pass to inject configured cache provider
2018-02-19 17:40:19 +01:00
Dmitri Petmanson
dfd93da236 bug #26086 [FrameworkBundle] Fix using annotation_reader in compiler pass to inject configured cache provider 2018-02-19 17:36:43 +01:00
Roland Franssen
ee4599284f [WebProfilerBundle] Fix anchor CSS 2018-02-19 17:27:36 +01:00
Amrouche Hamza
9ff86d6181
[WebProfilerBundle] limit ajax request to 100 and remove the last one 2018-02-19 15:17:52 +01:00
Fabien Potencier
ed27b12d2c removed version in @final @internal for version < 4.0 2018-02-19 13:18:43 +01:00
Fabien Potencier
0c6ec3fec0 made deprecation notices less verbose 2018-02-19 13:10:10 +01:00
Pawel Smolinski
64fb5a5663 [FrameworkBundle] Add support to 307/308 HTTP status codes in RedirectController 2018-02-19 08:01:54 +01:00
Roland Franssen
5c4566ca73 [WebProfilerBundle] Tweak default route name 2018-02-18 16:35:26 +01:00
Nicolas Grekas
5cf0181991 Merge branch '4.0'
* 4.0:
  [Serializer] optims and cleanup
  do not mock the container builder in tests
  [PhpUnitBridge] Added support for PHPUnit 7 in Coverage Listener
  fix accessing request values
  Avoid running the remove command without any packages
  [Form] Add translations for Tagalog
2018-02-14 15:11:22 +01:00
Nicolas Grekas
8faf29f54e Merge branch '3.4' into 4.0
* 3.4:
  [Serializer] optims and cleanup
  do not mock the container builder in tests
  [PhpUnitBridge] Added support for PHPUnit 7 in Coverage Listener
  fix accessing request values
  Avoid running the remove command without any packages
  [Form] Add translations for Tagalog
2018-02-14 15:11:10 +01:00
Nicolas Grekas
6b51addbd2 minor #26165 do not mock the container builder in tests (xabbuh)
This PR was merged into the 3.4 branch.

Discussion
----------

do not mock the container builder in tests

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

Commits
-------

777acfb do not mock the container builder in tests
2018-02-14 13:23:44 +01:00
Christian Flothmann
777acfbac9 do not mock the container builder in tests 2018-02-14 11:03:57 +01:00
Nicolas Grekas
aed5991834 Merge branch '4.0'
* 4.0:
  [Routing] Throw 405 instead of 404 when redirect is not possible
  [Process] fix test case
  Add security.tl.xlf to legacy directory
  [Security][Validator] Add translations for Tagalog
  fixed typo
  Typo fix in security component lithuanian translation.
  [TwigBundle][WebProfilerBundle] Fix JS collision
  [Process] Check PHP_BINDIR before $PATH in PhpExecutableFinder
2018-02-12 18:55:29 +01:00
Nicolas Grekas
f32a50d369 Merge branch '3.4' into 4.0
* 3.4:
  [Routing] Throw 405 instead of 404 when redirect is not possible
  [Process] fix test case
  Add security.tl.xlf to legacy directory
  [Security][Validator] Add translations for Tagalog
  fixed typo
  Typo fix in security component lithuanian translation.
  [TwigBundle][WebProfilerBundle] Fix JS collision
  [Process] Check PHP_BINDIR before $PATH in PhpExecutableFinder
2018-02-12 18:55:14 +01:00
Roland Franssen
07dd09db59 [WebProfilerBundle] Imply forward request by a new X-Previous-Debug-Token header 2018-02-12 18:43:33 +01:00
Fabien Potencier
267bf4c118 bug #26119 [TwigBundle][WebProfilerBundle] Fix JS collision (ro0NL)
This PR was merged into the 3.4 branch.

Discussion
----------

[TwigBundle][WebProfilerBundle] Fix JS collision

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes/no
| Fixed tickets | #25894
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!--highly recommended for new features-->

<!--
- Bug fixes must be submitted against the lowest branch where they apply
  (lowest branches are regularly merged to upper ones so they get the fixes too).
- Features and deprecations must be submitted against the master branch.
- Replace this comment by a description of what your PR is solving.
-->

Commits
-------

da39e01eb9 [TwigBundle][WebProfilerBundle] Fix JS collision
2018-02-12 08:07:49 +01:00
Nicolas Grekas
e81aa7694c Merge branch '4.0'
* 4.0:
  [YAML] Issue #26065: leading spaces in YAML multi-line string literals
  [Bridge\PhpUnit] Exit as late as possible
  [Bridge\PhpUnit] Cleanup BC layer
  [PhpBridge] add PHPUnit 7 support to SymfonyTestsListener
  [Lock] Log already-locked errors as "notice" instead of "warning"
  add context to serialize and deserialize
  Update Repository Symlink Helper
  isCsrfTokenValid() replace string  by ?string
  Document explicitly that dotfiles and vcs files are ignored by default
  [HttpKernel] don't try to wire Request argument with controller.service_arguments
  Make kernel build time optionally deterministic
  Use 0 for unlimited expiry
  [Routing] fix typo
  Bump default PHPUnit version from 6.3 to 6.5
  do not mock the container builder in tests
  [Cache][WebProfiler] fix collecting cache stats with sub-requests + allow clearing calls
2018-02-11 18:18:00 +01:00
Nicolas Grekas
6e34963b3d Merge branch '3.4' into 4.0
* 3.4:
  [YAML] Issue #26065: leading spaces in YAML multi-line string literals
  [Bridge\PhpUnit] Exit as late as possible
  [Bridge\PhpUnit] Cleanup BC layer
  [PhpBridge] add PHPUnit 7 support to SymfonyTestsListener
  [Lock] Log already-locked errors as "notice" instead of "warning"
  add context to serialize and deserialize
  Update Repository Symlink Helper
  Document explicitly that dotfiles and vcs files are ignored by default
  [HttpKernel] don't try to wire Request argument with controller.service_arguments
  Make kernel build time optionally deterministic
  Use 0 for unlimited expiry
  [Routing] fix typo
  Bump default PHPUnit version from 6.3 to 6.5
  do not mock the container builder in tests
  [Cache][WebProfiler] fix collecting cache stats with sub-requests + allow clearing calls
2018-02-11 18:17:44 +01:00
Nicolas Grekas
8ed107d09c Merge branch '2.8' into 3.4
* 2.8:
  [Bridge\PhpUnit] Exit as late as possible
  Update Repository Symlink Helper
  Document explicitly that dotfiles and vcs files are ignored by default
  do not mock the container builder in tests
2018-02-11 18:15:12 +01:00
Nicolas Grekas
e490d663d6 Merge branch '2.7' into 2.8
* 2.7:
  [Bridge\PhpUnit] Exit as late as possible
  Update Repository Symlink Helper
  Document explicitly that dotfiles and vcs files are ignored by default
  do not mock the container builder in tests
2018-02-11 17:53:59 +01:00
Gaylord Poillon
37fbbca086 isCsrfTokenValid() replace string by ?string 2018-02-11 11:55:53 +01:00
Christian Flothmann
347438ee36 Merge branch '4.0'
* 4.0:
  fix merge
  Env var maps to undefined constant.
  [SecurityBundle] Backport test
  [Security] fix merge of 2.7 into 2.8 + add test case
  backport regression test from 3.4
  do not mock the container builder or definitions
  fixed CS
  [TwigBundle] Register TwigBridge extensions first
  [WebProfilerBundle] Fix sub request link
  PhpDocExtractor::getTypes() throws fatal error when type omitted
  Fix misspelling variable
  use libsodium to run Argon2i related tests
  [DI] minor: use a strict comparision in setDecoratedService
  [HttpKernel] fix FC
  Follow-on to #25825: Fix edge case in getParameterOption.
  keep the context when validating forms
2018-02-09 16:48:09 +01:00
Roland Franssen
da39e01eb9 [TwigBundle][WebProfilerBundle] Fix JS collision 2018-02-09 15:48:30 +01:00
Christian Flothmann
064acb6ac3 Merge branch '3.4' into 4.0
* 3.4:
  Env var maps to undefined constant.
  [SecurityBundle] Backport test
  [Security] fix merge of 2.7 into 2.8 + add test case
  backport regression test from 3.4
  do not mock the container builder or definitions
  fixed CS
  [TwigBundle] Register TwigBridge extensions first
  [WebProfilerBundle] Fix sub request link
  PhpDocExtractor::getTypes() throws fatal error when type omitted
  Fix misspelling variable
  use libsodium to run Argon2i related tests
  [DI] minor: use a strict comparision in setDecoratedService
  [HttpKernel] fix FC
  Follow-on to #25825: Fix edge case in getParameterOption.
  keep the context when validating forms
2018-02-09 15:25:12 +01:00
Christian Flothmann
dab422287f do not mock the container builder in tests 2018-02-08 09:15:30 +01:00
Christian Flothmann
8bba882512 do not mock the container builder or definitions 2018-02-07 19:04:46 +01:00
Grégoire Pineau
3d01404da0 [Workflow] Fixed the dump command
* The 'label' option had a wrong mode
* Simplified the code
2018-02-07 11:09:07 +01:00
Fabien Potencier
0c128f8d3c feature #24705 [Workflow] Add PlantUML dumper to workflow:dump command (Plopix)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[Workflow] Add PlantUML dumper to workflow:dump command

| Q             | A
| ------------- | ---
| Branch        | 4.1
| Bug fix       | no
| New feature   | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT
| Doc PR        | Will do depending on the comments about that PR

Hello,

`workflow:dump` exports workflows in `dot` format. To me, this format is not the easiest and not the simplest to use. Styles and logic are mixed together which makes it hard to read.

[PlantUML](http://plantuml.com/) is a tool based on Graphviz like Dot but that
generates nicer diagrams, more readable and most of all easier to adapt to your
documentation. Just copy and paste the PUML on the website you will see the rendering live.

Also, there is a [PHPStorm Plugin](https://plugins.jetbrains.com/plugin/7017-plantuml-integration) and [plenty of integration](http://plantuml.com/running) of this format.

This PR adds 2 options

* a `--dump-format=puml` option to the `workflow:dump` command to generate the workflows in PlantUML.

* a `--puml-transition-format=square|arrow` option to the `workflow:dump` command to generate the workflows in PlantUML using a square shape or arrow for the transition. (see below)

The conversion requires the PlantUML JAR, and can be used like that:
```bash
php bin/console workflow:dump pull_request --dump-format=puml | java -jar plantuml.jar -p  > workflow.png
```
> don't forget the `-p` to enable the "piping"

Here is an example with `pull_request` workflow of the documentation (with no style and no marking):
```
@startuml
title pull_request
state start <<initial>>
state coding
state travis
state review
state merged
state closed
start --> travis: submit
coding --> travis: update
travis --> travis: update
review --> travis: update
travis --> review: wait_for_review
review --> coding: request_change
review --> merged: accept
review --> closed: reject
closed --> review: reopen
@enduml
```

As PlantUML let us define styles, I have provided some by default that the user can override.
Adding some marking:
```bash
php bin/console workflow:dump pull_request travis review --dump-format=puml
```
will give us:

```
@startuml
sprite $sf_logo [81x20/16z] {
hPNRaYiX24K1xwBo_tyx6-qaCtDEJ-KXLYMTLbp0HWcHZr3KRDJ8z94HG3jZn4_mijbQ2ryJoFePtXLWA_qxyGy19DpdY_10z11ZAbGjFHRwcEbcKx5-wqsV
yIMo8StMCHKh8ZUxnEwrZiwRAUOvy1lLcPQF4lEFAjhzMd5WOAqvKflS0Enx8PbihiSYXM8ClGVAseIWTAjCgVSAcnYbQG79xKFsZ0VnDCNc7AVBoPSMcTsX
UnrujbYjjz0NnsObkTgnmolqJD4QgGUYTQiNe8eIjtx4b6Vv8nPGpncn3NJ8Geo9W9VW2wGACm_JzgIO8A8KXr2jUBCVGEAAJSZ6JUlsNnmOzmIYti9G7bjL
8InaHM9G40NkwTG7OxrggvNIejA8AZuqyWjOzTIKi-wwYvjeHYesSWuPiTGDN5THzkYLU4MD5r2_0PDhG7LIUG33z5HtM6CP3icyWEVOS61sD_2ZsBfJdbVA
qM53XHDUwhY0TAwPug3OG9NonRFhO8ynF3I4unuAMDHmSrXH57V1RGvl9jafuZF9ZhqjWOEh98y0tUYGsUxkBSllIyBdT2oM5Fn2-ut-fzsq_cQNuL6Uvwqr
knh4RrvOKzxZfLV3s0rs_R_1SdYt3VxeQ1_y2_W2
}
title pull_request
skinparam titleBorderRoundCorner 15
skinparam titleBorderThickness 2
skinparam state {
    BackgroundColor<<initial>> #87b741
    BackgroundColor<<marked>> #3887C6
    BorderColor #3887C6
    BorderColor<<marked>> Black
    FontColor<<marked>> White
}
state start <<initial>>
state coding
state travis <<marked>>
state review <<marked>>
state merged
state closed
start --> travis: submit
coding --> travis: update
travis --> travis: update
review --> travis: update
travis --> review: wait_for_review
review --> coding: request_change
review --> merged: accept
review --> closed: reject
closed --> review: reopen
footer \nGenerated by <$sf_logo> **Workflow Component** and **PlantUML**
@enduml
```

Which gives you that:
![workflow](https://user-images.githubusercontent.com/313532/32086584-253e39c0-ba8b-11e7-82c7-fa24309dbcd6.png)

With `square` as transition, it gives you that:
![workflow](https://user-images.githubusercontent.com/313532/32533123-a8ea4530-c403-11e7-8f88-4f18d5e23a28.png)

Hope you will find that interesting!

Commits
-------

1497d36cab Add option to the workflow:dump command to allow PlantUML format dump
2018-02-07 06:48:48 +01:00
Fabien Potencier
39e88ed312 fixed CS 2018-02-07 06:34:13 +01:00
Fabien Potencier
abb913283e bug #25756 [TwigBundle] Register TwigBridge extensions first (fancyweb)
This PR was squashed before being merged into the 3.4 branch (closes #25756).

Discussion
----------

[TwigBundle] Register TwigBridge extensions first

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | https://github.com/symfony/symfony/issues/25610
| License       | MIT
| Doc PR        | -

The only extension that is really needed to display the current exception page is the `CodeExtension` so we could only prepend this one. However, prepending all of them seems safer to me in the long term.

Also I deeply looked into why this problem only appeared in 3.4 and found the reason. Before 3.4 it actually never reaches the `ExceptionController` for this kind of error because it cannot be resolved because it needs a twig instance in its constructor. This instance is directly taken from the container. Before 3.4 when an exception is thrown when you try to get a service from the container, the instance stored in the `$services` array is unset which is not the case in further versions. So in 3.4+, the `ExceptionController` can be resolved because the instance of twig is still in the container even after the initial exception.

It also means these kind of exceptions are displayed with bugs on all versions before 3.4 I guess. Actually it shows the message 2 times : one for the initial exception and the other one when it tries to resolve the `ExceptionController`.

Maybe another solution might be to use a dedicated twig instance with the right settings just for the exception page ?

Commits
-------

c8465ed97f [TwigBundle] Register TwigBridge extensions first
2018-02-07 06:32:49 +01:00
Thomas Calvet
c8465ed97f [TwigBundle] Register TwigBridge extensions first 2018-02-07 06:32:47 +01:00
Roland Franssen
8f0e47f636 [WebProfilerBundle] Fix sub request link 2018-02-07 06:25:55 +01:00
Fabien Potencier
731690f726 feature #25164 [WebProfilerBundle] Improve controller linking (ro0NL)
This PR was merged into the 4.1-dev branch.

Discussion
----------

[WebProfilerBundle] Improve controller linking

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes/no
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!--highly recommended for new features-->

I propose to remove the `Controller class` entry from the request toolbar panel, IMHO it's confusing/useless compared to the linked `Controller` entry above. They represent the same.

To preserve its value it's now used as title attribute instead, favored over controller file currently being used here. We can read that from the statusbar anyway :-)

Before: (hovering ontroller link)

![image](https://user-images.githubusercontent.com/1047696/35796142-ce6cdff4-0a5b-11e8-9fa3-91897516c9fc.png)

After: (hovering ontroller link)

![image](https://user-images.githubusercontent.com/1047696/35796237-2855e556-0a5c-11e8-8dca-853c3eabd2e9.png)

Commits
-------

f6c0dc64e6 [WebProfilerBundle] Improve controller linking
2018-02-07 06:05:22 +01:00
Christian Flothmann
5f9471ef47 use libsodium to run Argon2i related tests 2018-02-06 09:09:00 +01:00
Yonel Ceruto
922878ee53 Deprecating "false" as default value of "strict_variable" under Twig configuration 2018-02-05 09:53:02 -05:00
Roland Franssen
f6c0dc64e6 [WebProfilerBundle] Improve controller linking 2018-02-05 09:58:18 +01:00
Nicolas Grekas
2ef0d600aa Merge branch '4.0'
* 4.0:
  Use the PCRE_DOLLAR_ENDONLY modifier in route regexes
  [Form] Make sure errors are a part of the label on bootstrap 4 - this is a requirement for WCAG2
  [Config] Only using filemtime to check file freshness
2018-02-04 17:44:20 +01:00
Nicolas Grekas
767b028439 Merge branch '3.4' into 4.0
* 3.4:
  Use the PCRE_DOLLAR_ENDONLY modifier in route regexes
  [Form] Make sure errors are a part of the label on bootstrap 4 - this is a requirement for WCAG2
  [Config] Only using filemtime to check file freshness
2018-02-04 17:43:51 +01:00
Nicolas Grekas
5e094e8752 Merge branch '2.8' into 3.4
* 2.8:
  Use the PCRE_DOLLAR_ENDONLY modifier in route regexes
2018-02-04 17:43:40 +01:00
Nicolas Grekas
c337bf6810 Merge branch '2.7' into 2.8
* 2.7:
  Use the PCRE_DOLLAR_ENDONLY modifier in route regexes
2018-02-04 17:41:06 +01:00
Matthias Pigulla
f713a3e879 Use the PCRE_DOLLAR_ENDONLY modifier in route regexes 2018-02-04 16:50:24 +01:00
Robin Chalas
068b43a11b [SecurityBundle] Fix merge 2018-02-04 15:08:19 +01:00
Nicolas Grekas
302f33702d Merge branch '4.0'
* 4.0:
  fix merge
  Fix lock strategy tests
  [travis] cache compiled php extensions
  fix merge
  Allow remember-me factory creation when multiple user providers are configured.
  Add tests for glob loaders
  Improve assertions
  [DI][Routing] Fix tracking of globbed resources
  [Config] Handle Service/EventSubscriberInterface in ReflectionClassResource
  always call the parent class' constructor
2018-02-04 14:10:55 +01:00
Nicolas Grekas
f2d54fe694 fix merge 2018-02-04 14:10:03 +01:00
Nicolas Grekas
752c7cbbbe Merge branch '3.4' into 4.0
* 3.4:
  Fix lock strategy tests
  [travis] cache compiled php extensions
  fix merge
  Allow remember-me factory creation when multiple user providers are configured.
  Add tests for glob loaders
  Improve assertions
  [DI][Routing] Fix tracking of globbed resources
  [Config] Handle Service/EventSubscriberInterface in ReflectionClassResource
  always call the parent class' constructor
2018-02-04 14:08:26 +01:00
Nicolas Grekas
c57258b308 bug #25989 [DI][Routing] Fix tracking of globbed resources (nicolas-grekas, sroze)
This PR was merged into the 3.4 branch.

Discussion
----------

[DI][Routing] Fix tracking of globbed resources

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

The current `GlobFileLoader` in `Config` misses resource tracking, so we can't use it and have to use a per-component one instead.

(deps=high failures will be fixed after merging up to master.)

Commits
-------

945c753 Add tests for glob loaders
ad98c1fa [DI][Routing] Fix tracking of globbed resources
2018-02-04 11:32:13 +01:00
Nicolas Grekas
9a3aa07d35 minor #26002 Improve assertions (carusogabriel)
This PR was merged into the 3.4 branch.

Discussion
----------

Improve assertions

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

Following #25420 in `3.4` branch.

Commits
-------

829f59d Improve assertions
2018-02-04 11:29:43 +01:00
Robin Chalas
1e90ddd00d Merge branch '4.0'
* 4.0:
  [Intl] Fixed the broken link
  Fix typo
  Fix typo
  Fixed issue #25985
  Don't show wanna-be-private services as public in debug:container
  [Routing] Fix trailing slash redirection for non-safe verbs
  [DI] Fix tracking of source class changes for lazy-proxies
  Proxy class names should be deterministic and independent of spl_object_hash() which is somewhat random
  [Debug] Fix bad registration of exception handler, leading to mem leak
  [Form] Fixed empty data on expanded ChoiceType and FileType
  collect extension information as late as possible
2018-02-03 01:58:16 +01:00
Robin Chalas
c7ab3a9555 Merge branch '3.4' into 4.0
* 3.4:
  [Intl] Fixed the broken link
  Fix typo
  Fix typo
  Fixed issue #25985
  Don't show wanna-be-private services as public in debug:container
  [Routing] Fix trailing slash redirection for non-safe verbs
  [DI] Fix tracking of source class changes for lazy-proxies
  Proxy class names should be deterministic and independent of spl_object_hash() which is somewhat random
  [Debug] Fix bad registration of exception handler, leading to mem leak
  [Form] Fixed empty data on expanded ChoiceType and FileType
  collect extension information as late as possible
2018-02-03 01:57:23 +01:00
Israel J. Carberry
6ab8dd92e9 Allow remember-me factory creation when multiple user providers are configured. 2018-02-01 09:00:52 -06:00
Gabriel Caruso
829f59da7f Improve assertions 2018-02-01 04:11:27 -02:00
Nicolas Grekas
7f8e215d91 feature #25892 Adding an array adapter (weaverryan)
This PR was merged into the 4.1-dev branch.

Discussion
----------

Adding an array adapter

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | none
| License       | MIT
| Doc PR        | symfony/symfony-docs#9110

There's no simple way to *disable* caching (e.g. in the dev) environment. Setting up an array adapter is a very simple way to allow this :).

Commits
-------

f92e03d adding an array adapter
2018-01-31 21:13:43 +01:00
Robin Chalas
31f43e5226 Don't show wanna-be-private services as public in debug:container 2018-01-31 18:08:05 +01:00
Nicolas Grekas
ad98c1fa90 [DI][Routing] Fix tracking of globbed resources 2018-01-31 16:05:11 +01:00
Nicolas Grekas
f74bda51eb Merge branch '4.0'
* 4.0:
  update test for Twig performance optimizations
  [WebProfilerBundle] Increase retry delays between toolbarAction ajax calls
  support sapi_windows_vt100_support for php 7.2+
  bumped Symfony version to 4.0.5
  updated VERSION for 4.0.4
  updated CHANGELOG for 4.0.4
  bumped Symfony version to 3.4.5
  updated VERSION for 3.4.4
  updated CHANGELOG for 3.4.4
  bumped Symfony version to 2.8.35
  updated VERSION for 2.8.34
  updated CHANGELOG for 2.8.34
  bumped Symfony version to 2.7.42
  updated VERSION for 2.7.41
  update CONTRIBUTORS for 2.7.41
  updated CHANGELOG for 2.7.41
  [HttpFoundation] Added "null" type on Request::create docblock
  Don't stop PSR-4 service discovery if a parent class is missing.
  Allow trans filter to be safe
2018-01-31 11:41:42 +01:00
Nicolas Grekas
e341b27559 Merge branch '3.4' into 4.0
* 3.4:
  update test for Twig performance optimizations
  [WebProfilerBundle] Increase retry delays between toolbarAction ajax calls
  support sapi_windows_vt100_support for php 7.2+
  bumped Symfony version to 3.4.5
  updated VERSION for 3.4.4
  updated CHANGELOG for 3.4.4
  bumped Symfony version to 2.8.35
  updated VERSION for 2.8.34
  updated CHANGELOG for 2.8.34
  bumped Symfony version to 2.7.42
  updated VERSION for 2.7.41
  update CONTRIBUTORS for 2.7.41
  updated CHANGELOG for 2.7.41
  [HttpFoundation] Added "null" type on Request::create docblock
  Don't stop PSR-4 service discovery if a parent class is missing.
  Allow trans filter to be safe
2018-01-31 11:41:17 +01:00
Nicolas Grekas
855be6a104 Merge branch '2.8' into 3.4
* 2.8:
  update test for Twig performance optimizations
  [WebProfilerBundle] Increase retry delays between toolbarAction ajax calls
  support sapi_windows_vt100_support for php 7.2+
  bumped Symfony version to 2.8.35
  updated VERSION for 2.8.34
  updated CHANGELOG for 2.8.34
  bumped Symfony version to 2.7.42
  updated VERSION for 2.7.41
  update CONTRIBUTORS for 2.7.41
  updated CHANGELOG for 2.7.41
  [HttpFoundation] Added "null" type on Request::create docblock
  Allow trans filter to be safe
2018-01-31 11:38:55 +01:00