Skip to content

adding a custom method to define the priority of services #11731

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 47 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
90ba4de
minor: update remove of loggingmiddleware
Simperfit May 29, 2019
bcc55c5
Removed Symfony 4.* versionadded directives
javiereguiluz May 29, 2019
5226009
minor #11619 [Messenger]minor: update remove of loggingmiddleware (Si…
javiereguiluz May 29, 2019
e204126
Merge branch '4.4'
javiereguiluz May 29, 2019
5a55c66
Merge branch '4.4'
javiereguiluz May 29, 2019
446877c
Merge branch '4.4'
javiereguiluz May 29, 2019
2a760ec
Merge branch '4.4'
javiereguiluz May 30, 2019
6bf9ef5
Removed the deprecation message
javiereguiluz May 30, 2019
2f903fb
minor #11620 Removed Symfony 4.* versionadded directives (javiereguiluz)
javiereguiluz May 30, 2019
1edf64c
Merge branch '4.4'
weaverryan May 30, 2019
df6db26
Merge branch '4.4'
weaverryan May 31, 2019
327fd33
Merge branch '4.4'
javiereguiluz May 31, 2019
ca2f5ae
Merge branch '4.4'
javiereguiluz May 31, 2019
1bce5d2
Merge branch '4.4'
javiereguiluz May 31, 2019
ce64ac2
Removed deprecated contents
javiereguiluz May 29, 2019
234cf3e
minor #11621 Removed deprecated contents (javiereguiluz)
javiereguiluz May 31, 2019
0ef140f
Merge branch '4.4'
javiereguiluz May 31, 2019
18a5007
Merge branch '4.4'
javiereguiluz May 31, 2019
a9b67a8
Merge branch '4.4'
javiereguiluz May 31, 2019
7a6f99b
Merge branch '4.4'
wouterj Jun 1, 2019
2209f3b
Merge branch '4.4'
OskarStark Jun 3, 2019
2063d26
Merge branch '4.4'
javiereguiluz Jun 3, 2019
3c8358a
Merge branch '4.4'
javiereguiluz Jun 3, 2019
9445af1
Merge branch '4.4'
javiereguiluz Jun 3, 2019
488cc66
Merge branch '4.4'
javiereguiluz Jun 3, 2019
9e43b5c
Merge branch '4.4'
javiereguiluz Jun 3, 2019
3c7a8c1
Merge branch '4.4'
javiereguiluz Jun 4, 2019
4703ad1
Merge branch '4.4'
javiereguiluz Jun 4, 2019
08d8df4
Merge branch '4.4'
javiereguiluz Jun 4, 2019
1484bce
Merge branch '4.4'
OskarStark Jun 5, 2019
cdf009d
Merge branch '4.4'
javiereguiluz Jun 5, 2019
b1b5076
Merge branch '4.4'
javiereguiluz Jun 5, 2019
c5f335b
Merge branch '4.4'
javiereguiluz Jun 5, 2019
9cf3786
Merge branch '4.4'
OskarStark Jun 5, 2019
c888541
Merge branch '4.4'
OskarStark Jun 6, 2019
581e02f
Merge branch '4.4'
OskarStark Jun 6, 2019
6037185
Merge branch '4.4'
OskarStark Jun 6, 2019
6b9754d
Merge branch '4.4'
OskarStark Jun 6, 2019
ec2e0dd
Merge branch '4.4'
wouterj Jun 6, 2019
5528ba6
Merge branch '4.4'
javiereguiluz Jun 7, 2019
a5fdb6e
Merge branch '4.4'
wouterj Jun 8, 2019
72dc2d8
Merge branch '4.4'
wouterj Jun 8, 2019
25c9722
Merge branch '4.4'
javiereguiluz Jun 10, 2019
5d22b29
Merge branch '4.4'
javiereguiluz Jun 10, 2019
a707db2
Merge branch '4.4'
javiereguiluz Jun 10, 2019
4d4b9c6
added the new `default_priority_method`
pcabreus Jun 12, 2019
790ce4b
fixed the new `default_priority_method` for xml and php config
pcabreus Jun 12, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions bundles/configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -197,10 +197,6 @@ The ``Configuration`` class to handle the sample configuration looks like::
}
}

.. deprecated:: 4.2

Not passing the root node name to ``TreeBuilder`` was deprecated in Symfony 4.2.

.. seealso::

The ``Configuration`` class can be much more complicated than shown here,
Expand Down
8 changes: 0 additions & 8 deletions cache.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,6 @@ Basic uses of the cache looks like this::
Symfony supports the Cache Contracts, PSR-6/16 and Doctrine Cache interfaces.
You can read more about these at the :doc:`component documentation </components/cache>`.

.. versionadded:: 4.2

The cache contracts were introduced in Symfony 4.2.

.. _cache-configuration-with-frameworkbundle:

Configuring Cache with FrameworkBundle
Expand Down Expand Up @@ -612,10 +608,6 @@ To see all available cache pools:

$ php bin/console cache:pool:list

.. versionadded:: 4.3

The ``cache:pool:list`` command was introduced in Symfony 4.3.

Clear one pool:

.. code-block:: terminal
Expand Down
4 changes: 0 additions & 4 deletions components/cache/adapters/memcached_adapter.rst
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,6 @@ helper method allows creating and configuring a `Memcached`_ class instance usin
'memcached:?host[localhost]&host[localhost:12345]&host[/some/memcached.sock:]=3'
);

.. versionadded:: 4.2

The option to define multiple servers in a single DSN was introduced in Symfony 4.2.

The `Data Source Name (DSN)`_ for this adapter must use the following format:

.. code-block:: text
Expand Down
8 changes: 0 additions & 8 deletions components/cache/adapters/redis_adapter.rst
Original file line number Diff line number Diff line change
Expand Up @@ -102,14 +102,6 @@ name of your service group::
'redis:?host[redis1:26379]&host[redis2:26379]&host[redis3:26379]&redis_sentinel=mymaster'
);

.. versionadded:: 4.2

The option to define multiple servers in a single DSN was introduced in Symfony 4.2.

.. versionadded:: 4.4

Redis Sentinel support was introduced in Symfony 4.4.

.. note::

See the :class:`Symfony\\Component\\Cache\\Traits\\RedisTrait` for more options
Expand Down
8 changes: 0 additions & 8 deletions components/cache/psr6_psr16_adapters.rst
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,6 @@ this use-case::
// now use this wherever you want
$githubApiClient = new GitHubApiClient($psr6Cache);

.. versionadded:: 4.3

The ``Psr16Adapter`` class was introduced in Symfony 4.3.

Using a PSR-6 Cache Object as a PSR-16 Cache
--------------------------------------------

Expand Down Expand Up @@ -87,8 +83,4 @@ this use-case::
// now use this wherever you want
$githubApiClient = new GitHubApiClient($psr16Cache);

.. versionadded:: 4.3

The ``Psr16Cache`` class was introduced in Symfony 4.3.

.. _`PSR-16`: http://www.php-fig.org/psr/psr-16/
4 changes: 0 additions & 4 deletions components/config/definition.rst
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,6 @@ implements the :class:`Symfony\\Component\\Config\\Definition\\ConfigurationInte
}
}

.. deprecated:: 4.2

Not passing the root node name to ``TreeBuilder`` was deprecated in Symfony 4.2.

Adding Node Definitions to the Tree
-----------------------------------

Expand Down
4 changes: 0 additions & 4 deletions components/console/helpers/progressbar.rst
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,6 @@ If ``$iterable = [1, 2]``, the previous code will output the following:
1/2 [==============>-------------] 50%
2/2 [============================] 100%

.. versionadded:: 4.3

The ``iterate()`` method was introduced in Symfony 4.3.

Customizing the Progress Bar
----------------------------

Expand Down
4 changes: 0 additions & 4 deletions components/console/helpers/questionhelper.rst
Original file line number Diff line number Diff line change
Expand Up @@ -212,10 +212,6 @@ provide a callback function to dynamically generate suggestions::
$filePath = $helper->ask($input, $output, $question);
}

.. versionadded:: 4.3

The ``setAutocompleterCallback()`` method was introduced in Symfony 4.3.

Hiding the User's Response
~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down
16 changes: 0 additions & 16 deletions components/dom_crawler.rst
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,6 @@ tree.
The DomCrawler component will use it automatically when the content has
an HTML5 doctype.

.. versionadded:: 4.3

The automatic support of the html5-php library was introduced in Symfony 4.3.

Node Filtering
~~~~~~~~~~~~~~

Expand Down Expand Up @@ -216,10 +212,6 @@ Access the value of the first node of the current selection::
// avoid the exception passing an argument that text() returns when node does not exist
$message = $crawler->filterXPath('//body/p')->text('Default text content');

.. versionadded:: 4.3

The default argument of ``text()`` was introduced in Symfony 4.3.

Access the attribute value of the first node of the current selection::

$class = $crawler->filterXPath('//body/p')->attr('class');
Expand All @@ -236,10 +228,6 @@ Extract attribute and/or node values from the list of nodes::
Special attribute ``_text`` represents a node value, while ``_name``
represents the element name (the HTML tag name).

.. versionadded:: 4.3

The special attribute ``_name`` was introduced in Symfony 4.3.

Call an anonymous function on each node of the list::

use Symfony\Component\DomCrawler\Crawler;
Expand Down Expand Up @@ -333,10 +321,6 @@ and :phpclass:`DOMNode` objects::
// avoid the exception passing an argument that html() returns when node does not exist
$html = $crawler->html('Default <strong>HTML</strong> content');

.. versionadded:: 4.3

The default argument of ``html()`` was introduced in Symfony 4.3.

Expression Evaluation
~~~~~~~~~~~~~~~~~~~~~

Expand Down
4 changes: 0 additions & 4 deletions components/dotenv.rst
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,6 @@ You can adjust the variable defining the environment, default environment and te
environments by passing them as additional arguments to ``Dotenv::loadEnv()``
(see :method:`Symfony\\Component\\Dotenv\\Dotenv::loadEnv` for details).

.. versionadded:: 4.2

The ``Dotenv::loadEnv()`` method was introduced in Symfony 4.2.

You should never store a ``.env`` file in your code repository as it might
contain sensitive information; create a ``.env.dist`` file (or multiple
environment-specific ones as shown above) with sensible defaults instead.
Expand Down
9 changes: 0 additions & 9 deletions components/finder.rst
Original file line number Diff line number Diff line change
Expand Up @@ -150,10 +150,6 @@ rules to exclude files and directories from the results with the
// excludes files/directories matching the .gitignore patterns
$finder->ignoreVCSIgnored(true);

.. versionadded:: 4.3

The ``ignoreVCSIgnored()`` method was introduced in Symfony 4.3.

File Name
~~~~~~~~~

Expand Down Expand Up @@ -250,11 +246,6 @@ Multiple paths can be excluded by chaining calls or passing an array::
// same as above
$finder->notPath(['first/dir', 'other/dir']);

.. versionadded:: 4.2

Support for passing arrays to ``notPath()`` was introduced in Symfony
4.2

File Size
~~~~~~~~~

Expand Down
4 changes: 0 additions & 4 deletions components/http_client.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ The HttpClient Component
PHP stream wrappers and cURL. It provides utilities to consume APIs and
supports synchronous and asynchronous operations.

.. versionadded:: 4.3

The HttpClient component was introduced in Symfony 4.3.

Installation
------------

Expand Down
24 changes: 0 additions & 24 deletions components/intl.rst
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,6 @@ You can also check if a given language code is valid::

$isValidLanguage = Languages::exists($languageCode);

.. versionadded:: 4.3

The ``Languages`` class was introduced in Symfony 4.3.

The ``Scripts`` class provides access to the optional four-letter script code
that can follow the language code according to the `Unicode ISO 15924 Registry`_
(e.g. ``HANS`` in ``zh_HANS`` for simplified Chinese and ``HANT`` in ``zh_HANT``
Expand Down Expand Up @@ -125,10 +121,6 @@ You can also check if a given script code is valid::

$isValidScript = Scripts::exists($scriptCode);

.. versionadded:: 4.3

The ``Scripts`` class was introduced in Symfony 4.3.

Country Names
~~~~~~~~~~~~~

Expand Down Expand Up @@ -160,10 +152,6 @@ You can also check if a given country code is valid::

$isValidCountry = Countries::exists($countryCode);

.. versionadded:: 4.3

The ``Countries`` class was introduced in Symfony 4.3.

Locales
~~~~~~~

Expand Down Expand Up @@ -196,10 +184,6 @@ You can also check if a given locale code is valid::

$isValidLocale = Locales::exists($localeCode);

.. versionadded:: 4.3

The ``Locales`` class was introduced in Symfony 4.3.

Currencies
~~~~~~~~~~

Expand Down Expand Up @@ -240,10 +224,6 @@ You can also check if a given currency code is valid::

$isValidCurrency = Currencies::exists($currencyCode);

.. versionadded:: 4.3

The ``Currencies`` class was introduced in Symfony 4.3.

Timezones
~~~~~~~~~

Expand Down Expand Up @@ -318,10 +298,6 @@ Finally, you can also check if a given timezone ID is valid::

$isValidTimezone = Timezones::exists($timezoneId);

.. versionadded:: 4.3

The ``Timezones`` class was introduced in Symfony 4.3.

Learn more
----------

Expand Down
4 changes: 0 additions & 4 deletions components/lock.rst
Original file line number Diff line number Diff line change
Expand Up @@ -223,10 +223,6 @@ support blocking, and expects a TTL to avoid stalled locks::
MongoDbStore
~~~~~~~~~~~~

.. versionadded:: 4.3

The ``MongoDbStore`` was introduced in Symfony 4.3.

The MongoDbStore saves locks on a MongoDB server, it requires a
``\MongoDB\Client`` connection from `mongodb/mongodb`_. This store does not
support blocking and expects a TTL to avoid stalled locks::
Expand Down
8 changes: 1 addition & 7 deletions components/messenger.rst
Original file line number Diff line number Diff line change
Expand Up @@ -75,15 +75,9 @@ middleware stack. The component comes with a set of middleware that you can use.
When using the message bus with Symfony's FrameworkBundle, the following middleware
are configured for you:

#. :class:`Symfony\\Component\\Messenger\\Middleware\\LoggingMiddleware` (logs the processing of your messages)
#. :class:`Symfony\\Component\\Messenger\\Middleware\\SendMessageMiddleware` (enables asynchronous processing)
#. :class:`Symfony\\Component\\Messenger\\Middleware\\SendMessageMiddleware` (enables asynchronous processing, logs the processing of your messages if you pass a logger)
#. :class:`Symfony\\Component\\Messenger\\Middleware\\HandleMessageMiddleware` (calls the registered handler(s))

.. deprecated:: 4.3

The ``LoggingMiddleware`` is deprecated since Symfony 4.3 and will be
removed in 5.0. Pass a logger to ``SendMessageMiddleware`` instead.

Example::

use App\Message\MyMessage;
Expand Down
4 changes: 0 additions & 4 deletions components/options_resolver.rst
Original file line number Diff line number Diff line change
Expand Up @@ -439,10 +439,6 @@ This way, the ``$value`` argument will receive the previously normalized
value, otherwise you can prepend the new normalizer by passing ``true`` as
third argument.

.. versionadded:: 4.3

The ``addNormalizer()`` method was introduced in Symfony 4.3.

Default Values that Depend on another Option
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down
5 changes: 0 additions & 5 deletions components/property_access.rst
Original file line number Diff line number Diff line change
Expand Up @@ -169,11 +169,6 @@ This will produce: ``He is an author``
Accessing a non Existing Property Path
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. versionadded:: 4.3

The ``disableExceptionOnInvalidPropertyPath()`` method was introduced in
Symfony 4.3.

By default a :class:`Symfony\\Component\\PropertyAccess\\Exception\\NoSuchPropertyException`
is thrown if the property path passed to :method:`PropertyAccessor::getValue<Symfony\\Component\\PropertyAccess\\PropertyAccessor::getValue>`
does not exist. You can change this behavior using the
Expand Down
6 changes: 0 additions & 6 deletions components/routing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -454,12 +454,6 @@ routes with UTF-8 characters:
;
};

.. versionadded:: 4.3

The ``utf8`` option/method has been introduced in Symfony 4.3.
Before you had to use the ``options`` setting to define this value (for
example, when using annotations: ``options={"utf8": true}``).

In this route, the ``utf8`` option set to ``true`` makes Symfony consider the
``.`` requirement to match any UTF-8 characters instead of just a single
byte character. This means that so the following URLs would match:
Expand Down
4 changes: 0 additions & 4 deletions components/security/authentication.rst
Original file line number Diff line number Diff line change
Expand Up @@ -318,10 +318,6 @@ the ``switch_user`` firewall listener.
The ``Symfony\Component\Security\Http\Event\DeauthenticatedEvent`` event is triggered when a token has been deauthenticated
because of a user change, it can help you doing some clean-up task when a logout has been triggered.

.. versionadded:: 4.3

The ``Symfony\Component\Security\Http\Event\DeauthenticatedEvent`` event was introduced in Symfony 4.3.

.. seealso::

For more information on switching users, see
Expand Down
23 changes: 1 addition & 22 deletions components/serializer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -223,11 +223,6 @@ normalized data, instead of the denormalizer re-creating them. Note that
arrays of objects. Those will still be replaced when present in the normalized
data.

.. versionadded:: 4.3

The ``AbstractObjectNormalizer::DEEP_OBJECT_TO_POPULATE`` option was
introduced in Symfony 4.3.

.. _component-serializer-attributes-groups:

Attributes Groups
Expand Down Expand Up @@ -434,12 +429,6 @@ key in the ``context`` parameter of the desired serializer method::
$serializer = new Serializer([$normalizer], [$encoder]);
$serializer->serialize($person, 'json', ['ignored_attributes' => ['age']]); // Output: {"name":"foo"}

.. deprecated:: 4.2

The :method:`Symfony\\Component\\Serializer\\Normalizer\\AbstractNormalizer::setIgnoredAttributes`
method that was used as an alternative to the ``ignored_attributes`` option
was deprecated in Symfony 4.2.

.. _component-serializer-converting-property-names-when-serializing-and-deserializing:

Converting Property Names when Serializing and Deserializing
Expand Down Expand Up @@ -639,12 +628,6 @@ and ``remove``.
Using Callbacks to Serialize Properties with Object Instances
-------------------------------------------------------------

.. deprecated:: 4.2

The :method:`Symfony\\Component\\Serializer\\Normalizer\\AbstractNormalizer::setCallbacks`
method is deprecated since Symfony 4.2. Use the ``callbacks``
key of the context instead.

When serializing, you can set a callback to format a specific object property::

use App\Model\Person;
Expand All @@ -664,7 +647,7 @@ When serializing, you can set a callback to format a specific object property::
'createdAt' => $callback,
],
];

$normalizer = new GetSetMethodNormalizer(null, null, null, null, null, $defaultContext);

$serializer = new Serializer([$normalizer], [$encoder]);
Expand Down Expand Up @@ -805,10 +788,6 @@ The ``CsvEncoder`` encodes to and decodes from CSV.
You can pass the context key ``as_collection`` in order to have the results
always as a collection.

.. deprecated:: 4.2

Relying on the default value ``false`` is deprecated since Symfony 4.2.

The ``XmlEncoder``
~~~~~~~~~~~~~~~~~~

Expand Down
Loading