使DefaultMessageListenerContainer具有subscriptionShared和subscriptionDurable [英] Make DefaultMessageListenerContainer with subscriptionShared and subscriptionDurable

查看:182
本文介绍了使DefaultMessageListenerContainer具有subscriptionShared和subscriptionDurable的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在 DefaultMessageListenerContainer subscriptionShared subscriptionDurable

I want to use subscriptionShared and subscriptionDurable in DefaultMessageListenerContainer due to having a shared durable subscription between all consumers.

Tomcat启动后,我多次看到此日志消息,看来我的主题有问题:

After Tomcat start I see this log message many times and it seems my topic has a problem:

Setup of JMS message listener invoker failed for destination x.y.z trying to recover. cause:org.apache.activemq.ActiveMQSession.createSharedDurableConsumer (Ljavax/jms/Topic;Ljava/lang/String;)Ljavax/jms/MessageConsumer"

我的Spring版本是 4.3.8 。我使用ActiveMQ Artemis 2.9.0 和JMS 2.0

My Spring version is 4.3.8. I use ActiveMQ Artemis 2.9.0 and JMS 2.0.

推荐答案

基于以下事实:该消息包含 org.apache.activemq.ActiveMQSession 在我看来您正在使用ActiveMQ 5.x的OpenWire JMS客户端。此JMS客户端不支持JMS 2.0因此不支持共享的持久订阅。您需要使用ActiveMQ Artemis的JMS客户端。

Based on the fact that the error message contains org.apache.activemq.ActiveMQSession it appears to me that you're using the OpenWire JMS client from ActiveMQ 5.x. This JMS client doesn't support JMS 2.0 and therefore doesn't support shared durable subscriptions. You need to use the JMS client from ActiveMQ Artemis.

这篇关于使DefaultMessageListenerContainer具有subscriptionShared和subscriptionDurable的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆