Java连rabbitMQ 报错 An unexpected connection driver error occured

Java 项目中连接不上 rabbitMQ,报错内容如下

ERROR com.rabbitmq.client.impl.ForgivingExceptionHandler.log(ForgivingExceptionHandler.java:119) - An unexpected connection driver error occured

An unexpected connection driver error occured   是 发生意外的连接驱动程序错误

最大的可能是 新建的用户 没有 授权

一、 要确认 服务器安装上mq之后默认端口15672是浏览器浏览的端口,项目中则是需要配置成5672

在这里插入图片描述

二、新建用户需要授权 

添加用户

Java连rabbitMQ 报错 An unexpected connection driver error occured

 

Java连rabbitMQ 报错 An unexpected connection driver error occured

    或     

Java连rabbitMQ 报错 An unexpected connection driver error occured

创建成功之后,点进新创建的用户

Java连rabbitMQ 报错 An unexpected connection driver error occured

 用户授权

Java连rabbitMQ 报错 An unexpected connection driver error occured

这样就可以用新创建的用户连接了

Java连rabbitMQ 报错 An unexpected connection driver error occured

从 黄色的 No access  会变成  /     这样表明 授权 成功了。

Java连rabbitMQ 报错 An unexpected connection driver error occured

本文来自网络,不代表协通编程立场,如若转载,请注明出处:https://net2asp.com/5c94d94134.html