framework:
    messenger:
        serializer:
            default_serializer: messenger.transport.symfony_serializer
            symfony_serializer:
                format: json
                context:
                    disable_type_enforcement: true
        failure_transport: failed
        buses:
            messenger.bus.default:
                # and/or add your own
                middleware:
                    - 'App\Middleware\SignatureMiddleware'
        transports:
            failed: 'doctrine://default?queue_name=failed'
            transactions:
                dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
                retry_strategy:
                    max_retries: 1
                    delay: 1000
                    multiplier: 1
                    max_delay: 0
                options:
                    exchange:
                        name: transactions
                    queues:
                        transactions: ~
            topup:
                dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
                retry_strategy:
                    max_retries: 0
                    delay: 1000
                    multiplier: 1
                    max_delay: 0
                options:
                    exchange:
                        name: topup
                    queues:
                        topup: ~
        routing:
            'App\Message\TopUpMessage': topup
