首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >从Spring连接到部署在JBoss EAP7.1上的队列时收到警告/错误

从Spring连接到部署在JBoss EAP7.1上的队列时收到警告/错误
EN

Stack Overflow用户
提问于 2018-03-27 21:27:56
回答 1查看 385关注 0票数 0

我在运行在本地计算机上的QueueA EAP7.1服务器上部署了一个activemq (QueueA)。我有一个Spring应用程序,它也运行在同一台机器上,并为这个队列提供了一个监听器,它实现了"MessageListener“。我在Spring应用程序中使用了以下依赖项:

代码语言:javascript
复制
1. <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-jms</artifactId>
</dependency>

2.
<dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-activemq</artifactId>
</dependency>

3.
<dependency>
            <groupId>org.apache.activemq</groupId>
            <artifactId>activemq-broker</artifactId>
</dependency>

I have created connection factory the following way : 
ActiveMQConnectionFactory connectionFactory =
                new ActiveMQConnectionFactory();

        connectionFactory.setBrokerURL(tcp://localhost:8080);
        connectionFactory.setUserName("Username");
        connectionFactory.setPassword("Password");

Now when I start my Spring-Boot app it gives me the following error initially :
ERROR : Not Connected: [ClusterNode]

and following error repetitively until I stop the app:

ERROR : DefaultMessageListenerContainer: Error : Could not refresh JMS Connection for destination 'QueueA'.Cause: Cannot send, channel has already failed: tcp://127.0.0.1:8080


Can anyone please help in this regard ? or Point me to some documentation which would be helpful
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2018-03-29 20:04:17

我认为这里的问题是JBoss EAP 7嵌入了ActiveMQ Artemis,但是您的依赖关系是用于使用ActiveMQ 5.x (即不同的代理)的库。查看来自pom.xml的"Helloworld JMS“EAP 7.1的快速启动

显然,ActiveMQ Artemis 支持 5.x客户端,但我认为在EAP中默认禁用功能。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/49522688

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档