命令“symfony 控制台信使:失败:显示”不起作用

问题描述

framework:
    messenger:
        # Uncomment this (and the Failed transport below) to send Failed messages to this transport for later handling.
        # failure_transport: Failed

        transports:
            # https://symfony.com/doc/current/messenger.html#transport-configuration
            async: 
                dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
                options:
                    auto_setup: false
                    use_notify: true
                    check_delayed_interval: 60000
                retry_strategy:
                    max_retries: 3
                    multiplier: 2
            Failed: 
                dsn: 'doctrine://default?queue_name=Failed'
            # sync: 'sync://'

        routing:
            # Route your messages to the transports
            # 'App\Message\YourMessage': async
            App\Message\CommentMessage: async
  • Messenger 守护进程已启动
  • 但是当我运行以下命令时,我收到以下错误消息:
jpmena@jpmena-300E4A-300E5A-300E7A-3430EA-3530EA:~/CONSULTANT/FASTTRACK/DEV/guestbook$ symfony console messenger:Failed:show

                                                                      
  There are no commands defined in the "messenger:Failed" namespace.  
                                                                      
  Did you mean this?                                                  
      messenger                                                       
                                                                      

  • 我的配置有什么问题?

解决方法

我认为您忘记删除对“failure_transport”行的评论

framework:
    messenger:
        # Uncomment this (and the failed transport below) to send failed messages to this transport for later handling.
        failure_transport: failed <-- remove comment here

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...