File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -276,22 +276,22 @@ you can disable them like this:
276
276
Using Middleware Factories
277
277
~~~~~~~~~~~~~~~~~~~~~~~~~~
278
278
279
- Sometimes middleware are configurable using factories. There are two types of
280
- factories and they are based on Symfony's :doc: ` dependency injection < /service_container >`
281
- features:
279
+ Some third-party bundles and libraries provide configurable middleware via
280
+ factories. Using them requires a two-step configuration based on Symfony's
281
+ :doc: ` dependency injection < /service_container >` features:
282
282
283
283
.. code-block :: yaml
284
284
285
285
services :
286
286
287
- # Type 1: a factory class is registered as a service with the required
287
+ # Step 1: a factory class is registered as a service with the required
288
288
# dependencies to instantiate a middleware
289
289
doctrine.orm.messenger.middleware_factory.transaction :
290
290
class : Symfony\Bridge\Doctrine\Messenger\DoctrineTransactionMiddlewareFactory
291
291
arguments : ['@doctrine']
292
292
293
- # Type 2: an abstract definition that will call the factory with default arguments
294
- # or the one provided in the middleware config
293
+ # Step 2: an abstract definition that will call the factory with default
294
+ # arguments or the one provided in the middleware config
295
295
messenger.middleware.doctrine_transaction_middleware :
296
296
class : Symfony\Bridge\Doctrine\Messenger\DoctrineTransactionMiddleware
297
297
factory : ['@doctrine.orm.messenger.middleware_factory.transaction', 'createMiddleware']
You can’t perform that action at this time.
0 commit comments