Commit Graph

41011 Commits

Author SHA1 Message Date
neghmurken b9ac645d8b Locale aware service registration 2019-04-03 15:10:14 +02:00
Fabien Potencier 4ad54dad28 feature #30255 [DependencyInjection] Invokable Factory Services (zanbaldwin)
This PR was squashed before being merged into the 4.3-dev branch (closes #30255).

Discussion
----------

[DependencyInjection] Invokable Factory Services

| 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#11014

> Failing test is in the Twig bridge, and outside of the the scope of this PR.

Allow referencing invokable factory services, just as route definitions reference invokable controllers.
This functionality was also added for service configurators for consistency.

## Example

```php
<?php

namespace App\Factory;

class ServiceFactory
{
    public function __invoke(bool $debug)
    {
        return new Service($debug);
    }
}
```

```yaml
services:
    App\Service:
        # Prepend with "@" to differentiate between service and function.
        factory: '@App\Factory\ServiceFactory'
        arguments: [ '%kernel.debug%' ]
```

```xml
<?xml version="1.0" encoding="UTF-8" ?>
<container xmlns="http://symfony.com/schema/dic/services"
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://symfony.com/schema/dic/services
               http://symfony.com/schema/dic/services/services-1.0.xsd">
    <services>
        <!-- ... -->
        <service id="App\Service"
                 class="App\Service">
            <factory service="App\Factory\ServiceFactory" />
        </service>
    </services>
</container>
```

```php
<?php

use App\Service;
use App\Factory\ServiceFactory;
use Symfony\Component\DependencyInjection\Reference;

$container->register(Service::class, Service::class)
    ->setFactory(new Reference(ServiceFactory::class));
```

Commits
-------

23cb83f726 [DependencyInjection] Invokable Factory Services
2019-04-03 14:19:39 +02:00
Zan Baldwin 23cb83f726 [DependencyInjection] Invokable Factory Services 2019-04-03 14:19:31 +02:00
Fabien Potencier 248aff57d0 minor #30525 [PropertyInfo] Use a single cache item per method (deviantintegral)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[PropertyInfo] Use a single cache item per method

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

Replaces https://github.com/symfony/symfony/pull/30523 with a rebase to master.

This PR changes how property metadata is cached, significantly reducing the number of calls made between PHP and the backend cache. Instead of storing one cache item per method and set of arguments, a single cache item is stored per method. This matches well with real-world use, where most properties in an object will need to be inspected.

Note that the absolute numbers in the above PR are best case. In production environments where memcache is on a remote server, we were seeing multiple seconds consumed by memcache calls.

Commits
-------

2a4f8a11d4 [PropertyInfo] Use a single cache item per method
2019-04-03 13:59:42 +02:00
Fabien Potencier 8da76862fa feature #30843 [HttpClient] Add ScopingHttpClient::forBaseUri() + tweak MockHttpClient (nicolas-grekas)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[HttpClient] Add ScopingHttpClient::forBaseUri() + tweak MockHttpClient

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

This allows creating scoped HTTP clients in one line:

```php
$client = ScopingHttpClient::forBaseUri($client, 'http://example.com');
```

`$client` now resolves relative URLs using the provided base URI.

If one also adds default options as 3rd argument, these will be applied conditionally when a URL matching the base URI is requested.

This PR also tweaks `MockHttpClient` to make it return `MockResponse` on its own when no constructor argument is provided, easing tests a bit.

Commits
-------

2b9b8e5707 [HttpClient] Add ScopingHttpClient::forBaseUri() + tweak MockHttpClient
2019-04-03 12:40:25 +02:00
Fabien Potencier 78afdd1c5f feature #30844 [Cache] add logs on early-recomputation and locking (nicolas-grekas)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Cache] add logs on early-recomputation and locking

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

Commits
-------

847a9bb86d [Cache] add logs on early-recomputation and locking
2019-04-03 12:38:27 +02:00
Fabien Potencier 4835136e7e bug #30846 [FrameworkBundle] fix HttpClient integration (nicolas-grekas)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[FrameworkBundle] fix HttpClient integration

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

HttpClient should be an optional dep.
Fixes compat of SecurityBundle 4.2 with FrameworkBundle 4.3 as spotted by the CI.

Commits
-------

3e7a47c0bf [FrameworkBundle] fix HttpClient integration
2019-04-03 12:15:50 +02:00
Fabien Potencier 99bf6c2417 feature #30520 [RouterDebugCommand] add link to Controllers (nicoweb)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[RouterDebugCommand] add link to Controllers

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

Adds a link to the controller method on your IDE from dev's terminal:

<img width="734" alt="pr-debug-router" src="https://user-images.githubusercontent.com/29813575/54141007-1f3bc400-4425-11e9-82d0-1b37498d4953.png">

Configuration in your `services.yaml`:

```yaml
parameters:
    debug.file_link_format: phpstorm://open?file=%%f&line=%%l
```

Commits
-------

e9fca21d6b [RouterDebugCommand] add link to Controllers
2019-04-03 12:12:27 +02:00
Fabien Potencier 539f4ca162 feature #30212 [DI] Add support for "wither" methods - for greater immutable services (nicolas-grekas)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[DI] Add support for "wither" methods - for greater immutable services

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

Let's say we want to define an immutable service while still using traits for composing its optional features. A nice way to do so without hitting [the downsides of setters](https://symfony.com/doc/current/service_container/injection_types.html#setter-injection) is to use withers. Here would be an example:

```php
 class MyService
{
    use LoggerAwareTrait;
}

trait LoggerAwareTrait
{
    private $logger;

    /**
     * @required
     * @return static
     */
    public function withLogger(LoggerInterface $logger)
    {
        $new = clone $this;
        $new->logger = $logger;

        return $new;
    }
}

$service = new MyService();
$service = $service->withLogger($logger);
```

As you can see, this nicely solves the setter issues.

BUT how do you make the service container create such a service? Right now, you need to resort to complex gymnastic using the "factory" setting - manageable for only one wither, but definitely not when more are involved and not compatible with autowiring.

So here we are: this PR allows configuring such services seamlessly.
Using explicit configuration, it adds a 3rd parameter to method calls configuration: after the method name and its parameters, you can pass `true` and done, you just declared a wither:
```yaml
services:
    MyService:
        calls:
            - [withLogger, ['@logger'], true]
```

In XML, you could use the new `returns-clone` attribute on the `<call>` tag.

And when using autowiring, the code looks for the `@return static` annotation and turns the flag on if found.

There is only one limitation: unlike services with regular setters, services with withers cannot be part of circular loops that involve calls to wither methods (unless they're declared lazy of course).

Commits
-------

f455d1bd97 [DI] Add support for "wither" methods - for greater immutable services
2019-04-03 12:09:58 +02:00
Nicolas Grekas 3e7a47c0bf [FrameworkBundle] fix HttpClient integration 2019-04-03 12:06:15 +02:00
nicoweb e9fca21d6b [RouterDebugCommand] add link to Controllers 2019-04-03 11:55:14 +02:00
Nicolas Grekas 2b9b8e5707 [HttpClient] Add ScopingHttpClient::forBaseUri() + tweak MockHttpClient 2019-04-03 11:54:40 +02:00
Nicolas Grekas bce6124f8f feature #30674 [FrameworkBundle] change the way http clients are configured by leveraging ScopingHttpClient (nicolas-grekas)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[FrameworkBundle] change the way http clients are configured by leveraging ScopingHttpClient

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

This PR allows configuring scoped HTTP clients ("scoped_clients" replaces the previous "clients" options):

```yaml
framework:
  http_client:
    max_host_connections: 4
    default_options:
      # ...
    scoped_clients:
      github_client:
        base_uri: https://api.github.com
        headers:
          Authorization: token abc123
          # ...
```

The base URI is turned into a scoping regular expression so that the token will be sent only when the `github_client` service is requesting the corresponding URLs.
When the base URI is too restrictive, the `scope` option can be used explicitly to define the regexp that URLs must match before any other options are applied.

~All defined scopes are passed to a new `scoping_http_client` service, that can be used to hit endpoints with authentication pre-configured for several hosts. Its named autowiring alias is `HttpClientInterface $scopingClient` (this cannot be done with `http_client` as we want safe defaults, e.g. credentials should not be used implicitly when writing webhooks/crawlers.)~

Commits
-------

f1a26b9aea [FrameworkBundle] change the way http clients are configured by leveraging ScopingHttpClient
2019-04-03 11:36:15 +02:00
Nicolas Grekas 847a9bb86d [Cache] add logs on early-recomputation and locking 2019-04-03 11:22:57 +02:00
Nicolas Grekas f455d1bd97 [DI] Add support for "wither" methods - for greater immutable services 2019-04-03 11:14:18 +02:00
Nicolas Grekas f1a26b9aea [FrameworkBundle] change the way http clients are configured by leveraging ScopingHttpClient 2019-04-03 10:47:24 +02:00
Fabien Potencier 8f3d80fce7 minor #30842 [FrameworkBundle] Rename WebTestAssertions -> WebTestAssertionsTrait (vudaltsov)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[FrameworkBundle] Rename WebTestAssertions -> WebTestAssertionsTrait

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

Renamed according to the Symfony coding standards.

Commits
-------

2ae30a7e3d Rename WebTestAssertions -> WebTestAssertionsTrait
2019-04-03 10:44:55 +02:00
Valentin Udaltsov 2ae30a7e3d Rename WebTestAssertions -> WebTestAssertionsTrait 2019-04-03 11:22:11 +03:00
Nicolas Grekas 755f41192f minor #30831 [HttpClient][Contracts] rename "raw_headers" to "response_headers" (nicolas-grekas)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[HttpClient][Contracts] rename "raw_headers" to "response_headers"

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

A preliminary step before adding the `request_headers` info on responses to ease debugging.

Commits
-------

0b21268bf5 [HttpClient][Contracts] rename "raw_headers" to "response_headers"
2019-04-02 13:11:42 +02:00
Nicolas Grekas 0b21268bf5 [HttpClient][Contracts] rename "raw_headers" to "response_headers" 2019-04-02 12:06:39 +02:00
Fabien Potencier 50a5dfd4f1 feature #29312 [EventDispatcher] Split events across requests (ro0NL)
This PR was squashed before being merged into the 4.3-dev branch (closes #29312).

Discussion
----------

[EventDispatcher] Split events across requests

| 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 | #24275
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!-- required for new features -->

Split events per request, as currently a profiled sub-request includes all events. Follows same approach how logs are split in #23659.

Commits
-------

c3477badbc [EventDispatcher] Split events across requests
2019-04-02 12:04:12 +02:00
Roland Franssen c3477badbc [EventDispatcher] Split events across requests 2019-04-02 12:04:04 +02:00
Fabien Potencier aa5b6f95b9 feature #30827 [TwigBridge] Add template file link to debug:twig command (yceruto)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[TwigBridge] Add template file link to debug:twig command

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

![debug_twig_file_link](https://user-images.githubusercontent.com/2028198/55365428-8c85c680-54b2-11e9-9d4e-e4845fc7d411.png)

Commits
-------

05e2e1e088 Add template file link
2019-04-02 09:00:23 +02:00
Fabien Potencier a63496bcf4 feature #30826 [Form] Add file links for described classes in debug:form command (yceruto)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Form] Add file links for described classes in debug:form command

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

![debug_form_file_link](https://user-images.githubusercontent.com/2028198/55357775-d1eac980-549b-11e9-8aa8-500aee629753.png)

Commits
-------

dcba01d212 Add file links for described classes
2019-04-02 08:58:30 +02:00
Yonel Ceruto 05e2e1e088 Add template file link 2019-04-01 18:40:03 -04:00
Yonel Ceruto dcba01d212 Add file links for described classes 2019-04-01 16:27:30 -04:00
Fabien Potencier 17a3ccf4b3 feature #30813 New PHPUnit assertions for the WebTestCase (Pierstoval, fabpot)
This PR was merged into the 4.3-dev branch.

Discussion
----------

New PHPUnit assertions for the WebTestCase

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

While reviewing #29990, and working on some tests, I realized that we could do better by adding PHPUnit constraint classes in various components that are then used in WebTextCase.

**Before**

```php
<?php

namespace App\Tests;

use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;

class DefaultControllerTest extends WebTestCase
{
    public function testSomething()
    {
        $client = static::createClient();
        $crawler = $client->request('GET', '/test');

        $this->assertSame(200, $client->getResponse()->getStatusCode());
        $this->assertContains('Hello World', $crawler->filter('h1')->text());
    }
}
```

**After**

```php
<?php

namespace App\Tests;

use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;

class DefaultControllerTest extends WebTestCase
{
    public function testSomething()
    {
        $client = static::createClient();
        $client->request('GET', '/test');

        $this->assertResponseIsSuccessful();
        $this->assertSelectorTextContains('h1', 'Hello World');
    }
}
```

Commits
-------

4f91020c8d added PHPUnit assertions in various components
2f8040ee84 Create new PHPUnit assertions for the WebTestCase
2019-04-01 18:54:09 +02:00
Fabien Potencier 4f91020c8d added PHPUnit assertions in various components 2019-04-01 18:52:57 +02:00
Fabien Potencier fefe62c4d0 updated CHANGELOG 2019-04-01 18:49:08 +02:00
Fabien Potencier b01fd5f370 feature #27738 [Validator] Add a HaveIBeenPwned password validator (dunglas)
This PR was squashed before being merged into the 4.3-dev branch (closes #27738).

Discussion
----------

[Validator] Add a HaveIBeenPwned password validator

| 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 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

This PR adds a new `Pwned` validation constraint to prevent users to choose passwords that have been leaked in public data breaches.
The validator uses the https://haveibeenpwned.com/ API. The implementation is similar to the one used by [Firefox Monitor](https://blog.mozilla.org/futurereleases/2018/06/25/testing-firefox-monitor-a-new-security-tool/). It allows to not expose the password hash using a k-anonymity model. The specific implementation for HaveIBeenPwned has been [described in depth by Cloudflare](https://blog.cloudflare.com/validating-leaked-passwords-with-k-anonymity/).

Usage:

```php
// Rejects the password if is present in any number of times in any data breach
class User
{
    /** @Pwned */
    public $plainPassword;
}

// Rejects the password if is present more than 5 times in data breaches
class User
{
    /** @Pwned(maxCount=5) */
    public $plainPassword;
}

// Customize the error message
class User
{
    /** @Pwned(message='Please select another password, this one has already been hacked.') */
    public $plainPassword;
}
```

Commits
-------

ec1ded898a [Validator] Add a HaveIBeenPwned password validator
2019-04-01 18:48:04 +02:00
Kévin Dunglas ec1ded898a [Validator] Add a HaveIBeenPwned password validator 2019-04-01 18:47:55 +02:00
Fabien Potencier 1fcc994021 feature #30690 Changing messenger bus id from 'message_bus' to 'messenger.default_bus' (THERAGE Kévin)
This PR was merged into the 4.3-dev branch.

Discussion
----------

Changing messenger bus id from 'message_bus' to 'messenger.default_bus'

Changing messenger bus tag from 'message_bus' to 'messenger.message_bus'

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

All is in the title.
This PR change the tag of the default bus from 'message_bus' to 'messenger.message_bus'.

Commits
-------

3cee1cac12 #30690 - Changing messenger bus id from 'message_bus' to 'messenger.default_bus'
2019-04-01 16:50:37 +02:00
Alex Rock Ancelet 2f8040ee84 Create new PHPUnit assertions for the WebTestCase 2019-04-01 16:44:23 +02:00
Fabien Potencier b921076df4 bug #30805 [Messenger] bug fixes in Doctrine Transport (vincenttouzet)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Messenger] bug fixes in Doctrine Transport

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

Just tested the new Doctrine transport and I've see 3 bugs so far :
- [x] The message is not return by the transport
- [x] The headers column must be of type TEXT and not just STRING
- [ ] When using the PhpSerializer the message is truncated (PR: https://github.com/symfony/symfony/pull/30814)

The body in database looks like this :
```
O:36:"Symfony\Component\Messenger\Envelope":2:{s:44:"
```

The body given by the serializer is the following :
```
O:36:"Symfony\Component\Messenger\Envelope":2:{s:44:"Symfony\Component\Messenger\Envelopestamps";a:3:{s:49:"Symfony\Component\Messenger\Stamp\SerializerStamp";a:1:{i:0;O:49:"Symfony\Component\Messenger\Stamp\SerializerStamp":1:{s:58:"Symfony\Component\Messenger\Stamp\SerializerStampcontext";a:0:{}}}s:46:"Symfony\Component\Messenger\Stamp\BusNameStamp";a:1:{i:0;O:46:"Symfony\Component\Messenger\Stamp\BusNameStamp":1:{s:55:"Symfony\Component\Messenger\Stamp\BusNameStampbusName";s:21:"messenger.bus.default";}}s:43:"Symfony\Component\Messenger\Stamp\SentStamp";a:1:{i:0;O:43:"Symfony\Component\Messenger\Stamp\SentStamp":2:{s:56:"Symfony\Component\Messenger\Stamp\SentStampsenderClass";s:64:"Symfony\Component\Messenger\Transport\Doctrine\DoctrineTransport";s:56:"Symfony\Component\Messenger\Stamp\SentStampsenderAlias";s:16:"environment.stop";}}}s:45:"Symfony\Component\Messenger\Envelopemessage";O:34:"App\Message\EnvironmentStopMessage":1:{s:51:"App\Message\AbstractEnvironmentMessageenvironment";O:22:"App\Entity\Environment":5:{s:26:"App\Entity\Environmentid";s:36:"3bade252-b7a9-4188-82bd-3e68129e0da7";s:37:"App\Entity\EnvironmentrepositoryUrl";s:6:"string";s:30:"App\Entity\Environmentbranch";s:6:"string";s:33:"App\Entity\EnvironmenthostNames";a:1:{i:0;N;}s:27:"App\Entity\Environmentenv";a:2:{s:7:"APP_ENV";s:4:"prod";s:7:"APP_VAR";s:13:"example value";}}}}
```

Commits
-------

27466498d0 [Messenger] Fix get in Doctrine Transport
2019-04-01 16:43:38 +02:00
Fabien Potencier 1a5ab6b750 bug #30814 [Messenger] base64_encoding inside PhpSerializer to avoid null characters (weaverryan)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Messenger] base64_encoding inside PhpSerializer to avoid null characters

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

Hi!

As pointed out in #30805, the `PhpSerializer` creates strings with null bytes. This apparently causes problems on at least some database systems (I didn't notice, but @vincenttouzet did). I also read that, for example, SQS doesn't like null characters. And, in general, because we're sending this data over a transport, `base64_encoding` data is pretty standard.

Does anyone see any downsides?

Cheers!

Commits
-------

fe7ad812c7 base64_encoding inside PhpSerializer to avoid null characters
2019-04-01 16:41:45 +02:00
Fabien Potencier 643e9f6b9d minor #30815 [Process] Added more detail to the exception when the CWD is invalid (lyrixx)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Process] Added more detail to the exception when the CWD is invalid

| 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 panther with "special" directory structure, the message is
not really usefull. Let's add the CWD to the exception

Commits
-------

d27858f77b [Process] Added more detail to the exception when the CWD is invalid
2019-04-01 16:24:06 +02:00
Fabien Potencier c8670ee6ca feature #30810 [Inflector] remove "internal" marker from the component (nicolas-grekas)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Inflector] remove "internal" marker from the component

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

This code works: making it non-internal won't increase the maintenance burden and can help others build on it.

Commits
-------

164b45b79c [Inflector] remove "internal" marker from the component
2019-04-01 16:12:23 +02:00
Nicolas Grekas 164b45b79c [Inflector] remove "internal" marker from the component 2019-04-01 15:53:46 +02:00
Grégoire Pineau d27858f77b [Process] Added more detail to the exception when the CWD is invalid 2019-04-01 15:29:45 +02:00
Ryan Weaver fe7ad812c7 base64_encoding inside PhpSerializer to avoid null characters 2019-04-01 08:36:54 -04:00
THERAGE Kévin 3cee1cac12 #30690 - Changing messenger bus id from 'message_bus' to 'messenger.default_bus' 2019-04-01 14:33:42 +02:00
Robin Chalas 9bcea2e9f4 fix test name 2019-03-31 23:15:36 +02:00
Fabien Potencier 5d0fa550df bug #30806 [EventDispatcher] Fix FC layer (bis) (chalasr)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[EventDispatcher] Fix FC layer (bis)

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

Commits
-------

2e02986b26 [EventDispatcher] Fix FC layer (really)
2019-03-31 22:54:21 +02:00
Fabien Potencier 4c78b13ce6 minor #30807 [Messenger] Various minor fixes (fabpot)
This PR was squashed before being merged into the 4.3-dev branch (closes #30807).

Discussion
----------

[Messenger] Various minor fixes

| Q             | A
| ------------- | ---
| Branch?       | master
| 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 | n/a
| License       | MIT
| Doc PR        | n/a

Found while playing with the new Doctrine transport.

Commits
-------

96dee1ee20 [Messenger] fixed missing use statement
1044dfb93d [Messenger] simplified code
2019-03-31 22:43:17 +02:00
Robin Chalas 2e02986b26 [EventDispatcher] Fix FC layer (really) 2019-03-31 22:38:00 +02:00
Fabien Potencier 96dee1ee20 [Messenger] fixed missing use statement 2019-03-31 22:37:12 +02:00
Fabien Potencier 1044dfb93d [Messenger] simplified code 2019-03-31 22:18:13 +02:00
Vincent Touzet 27466498d0 [Messenger] Fix get in Doctrine Transport 2019-03-31 20:44:41 +02:00
Fabien Potencier 9669e13554 [Messenger] made a const private 2019-03-31 19:35:08 +02:00
Fabien Potencier dafc357fb9 minor #30803 [Messenger] Remove unused option in the Doctrine transport (vincenttouzet)
This PR was merged into the 4.3-dev branch.

Discussion
----------

[Messenger] Remove unused option in the Doctrine transport

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

This PR remove the unused option `loop_sleep` in the Messenger Doctrine transport

Commits
-------

4811400372 [Messenger] Remove unused option in the Doctrine transport
2019-03-31 19:33:19 +02:00