确认后,hornetq消息仍在队列中

时间:2013-12-17 12:30:51

标签: hornetq

我们正在使用hornetq-core 2.2.21.Final独立阅读非跨国消息后,该消息仍然保留在队列中,尽管它承认 会话是使用

创建的
sessionFactory.createSession(true, true, 0)

定位器设置:

val transConf = new TransportConfiguration(classOf[NettyConnectorFactory].getName,map)
val locator = HornetQClient.createServerLocatorWithoutHA(transConf) 
locator.setBlockOnDurableSend(false)
locator.setBlockOnNonDurableSend(false)
locator.setAckBatchSize(0) // also tried without this setting
locator.setConsumerWindowSize(0)// also tried without this setting

使用message.acknowledge()

确认消息

我认为问题可能是同一地址上的两个队列 还尝试设置消息过期但它没有帮助,消息仍然堆积在队列中 请指教

1 个答案:

答案 0 :(得分:1)

您似乎正在使用核心API。你明确地在消息上调用确认吗?

如果在同一地址上有两个队列,则ack只会识别您正在使用的队列中的消息。在这种情况下,系统正常运作。

相关问题