• 手动创建后仍然提示 topic[] not exist, apply first please


           昨天晚上同事碰到个问题,rocketMq 在test和dev环境创建的topic ,默认是自动创建的没有问题,但是在pre环境却不行。日志里面提示是 

         

    com.alibaba.rocketmq.client.exception.MQClientException: Send [5] times, still failed, cost [24]ms, Topic: astrict_driver_refresh_crowd, BrokersSent: [broker-a, broker-b, broker-a, broker-b, broker-a]
    See http://docs.aliyun.com/cn#/pub/ons/faq/exceptions&send_msg_failed for further details.
        at com.alibaba.rocketmq.client.impl.producer.DefaultMQProducerImpl.sendDefaultImpl(DefaultMQProducerImpl.java:577)
        at com.alibaba.rocketmq.client.impl.producer.DefaultMQProducerImpl.send(DefaultMQProducerImpl.java:1034)
        at com.alibaba.rocketmq.client.impl.producer.DefaultMQProducerImpl.send(DefaultMQProducerImpl.java:1028)
        at com.alibaba.rocketmq.client.producer.DefaultMQProducer.send(DefaultMQProducer.java:101)
        at com.zhuanche.common.rocketmq.CommonRocketProducer.publishMessage(CommonRocketProducer.java:69)
        at com.zhuanche.service.mpconfig.AstrictDriverRefreshCrowdService.refreshDriverCrowd(AstrictDriverRefreshCrowdService.java:74)
        at com.zhuanche.controller.config.AstrictDriverNotifyController$4.run(AstrictDriverNotifyController.java:101)
        at java.lang.Thread.run(Thread.java:745)
    Caused by: com.alibaba.rocketmq.client.exception.MQBrokerException: CODE: 17  DESC: topic[astrict_driver_refresh_crowd] not exist, apply first please!
    See http://rocketmq.apache.org/docs/faq/ for further details.
        at com.alibaba.rocketmq.client.impl.MQClientAPIImpl.processSendResponse(MQClientAPIImpl.java:345)
        at com.alibaba.rocketmq.client.impl.MQClientAPIImpl.sendMessageSync(MQClientAPIImpl.java:255)
        at com.alibaba.rocketmq.client.impl.MQClientAPIImpl.sendMessage(MQClientAPIImpl.java:236)
        at com.alibaba.rocketmq.client.impl.producer.DefaultMQProducerImpl.sendKernelImpl(DefaultMQProducerImpl.java:682)
    [dev@cn_bj_sjhl_docker-pre-g1_10-30-11-21 mp-config-rest_10.30.11.248]$ Connection to ops-jump1.01zhuanche.com closed by remote host.

        就是没有找到对应的topic,按说应该是自动创建的,但是手动创建后仍然不行。

       这好奇怪。  最后是通过添加了 instanceName 解决了,但是这里面的逻辑自己仍然没有理清楚。

      参考:https://www.jianshu.com/p/c8fd57a7f741

  • 相关阅读:
    IIS网站或系统验证码不显示问题——"使用了托管的处理程序,但是未安装或未完整安装 ASP.NET"
    Windows Server 2008 R2 下配置证书服务器和HTTPS方式访问网站
    RESTful API 设计指南
    Js计算当前日,当前周开始结束时间,当前月份,当前年份
    highcharts
    CSS布局 ——从display,position, float属性谈起
    CSS的选择器
    DOC窗口之cd命令(windows)
    Tomcat的启动与关闭以及启动时一闪而过的解决方法
    为什么安装jdk时,会安装两个jre?不用配置jre的环境变量
  • 原文地址:https://www.cnblogs.com/thinkingandworkinghard/p/13438081.html
Copyright © 2020-2023  润新知