Skip to content

Commit 1f77945

Browse files
committed
Merge branch '4.4' into 5.0
* 4.4: [RememberMe] add doctrine migration note
2 parents 66d9722 + 1eeda33 commit 1f77945

File tree

2 files changed

+53
-5
lines changed

2 files changed

+53
-5
lines changed

messenger.rst

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -889,12 +889,30 @@ up manually by calling the ``messenger:setup-transports`` command.
889889
To avoid tools like Doctrine Migrations from trying to remove this table because
890890
it's not part of your normal schema, you can set the ``schema_filter`` option:
891891

892-
.. code-block:: yaml
892+
.. configuration-block::
893+
894+
.. code-block:: yaml
895+
896+
# config/packages/doctrine.yaml
897+
doctrine:
898+
dbal:
899+
schema_filter: '~^(?!messenger_messages)~'
900+
901+
.. code-block:: xml
893902
894-
# config/packages/doctrine.yaml
895-
doctrine:
896-
dbal:
897-
schema_filter: '~^(?!messenger_messages)~'
903+
# config/packages/doctrine.xml
904+
<doctrine:dbal schema-filter="~^(?!messenger_messages)~" .../>
905+
906+
.. code-block:: php
907+
908+
# config/packages/doctrine.php
909+
$container->loadFromExtension('doctrine', [
910+
'dbal' => [
911+
'schema_filter' => '~^(?!messenger_messages)~',
912+
// ...
913+
],
914+
// ...
915+
]);
898916
899917
The transport has a number of options:
900918

security/remember_me.rst

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,36 @@ so ``DoctrineTokenProvider`` can store the tokens:
247247
`username` varchar(200) NOT NULL
248248
);
249249
250+
.. note::
251+
252+
If you use DoctrineMigrationsBundle to manage your database migrations, you
253+
will need to tell Doctrine to ignore this new ``rememberme_token`` table:
254+
255+
.. configuration-block::
256+
257+
.. code-block:: yaml
258+
259+
# config/packages/doctrine.yaml
260+
doctrine:
261+
dbal:
262+
schema_filter: ~^(?!rememberme_token)~
263+
264+
.. code-block:: xml
265+
266+
# config/packages/doctrine.xml
267+
<doctrine:dbal schema-filter="~^(?!rememberme_token)~" .../>
268+
269+
.. code-block:: php
270+
271+
# config/packages/doctrine.php
272+
$container->loadFromExtension('doctrine', [
273+
'dbal' => [
274+
'schema_filter' => '~^(?!rememberme_token)~',
275+
// ...
276+
],
277+
// ...
278+
]);
279+
250280
Finally, set the ``token_provider`` option of the ``remember_me`` config to the
251281
service you just created:
252282

0 commit comments

Comments
 (0)