Skip to Main Content

The destination message count limit (maxNumMsgs) of 100000 has been reached

950368Jul 18 2012 — edited Jul 20 2012
So I seem to be getting this error when trying to send JMS messages in Glassfish to a topic after our application has been up and running for about 18 hours. We're using a topic, so a message is being published to the topic and one of two things should be happening if I understand things correctly: 1) Subscribers on the topic should receive a copy of the message, then the message is deleted from the topic or 2) there are no subscribers so the message doesn't get stored in the topic. However, based on the stack trace below, it is quite clear that the topic queueing up messages. The messages we send are non-persistent and the subscribers are non-durable so if no one is listening to the topic there's no reason to queue up the message. And if someone is listening, when the message is sent to the subscriber then it should be removed from the topic. Maybe I'm not understanding how topics work.

Here's the stack trace:
[#|2012-07-18T08:47:58.976-0400|SEVERE|oracle-glassfish3.1.2|javax.jms.Session.mqjmsra|_ThreadID=47;_ThreadName=Thread-2;|MQJMSRA_DS4001: JMSServiceException on send message:sendMessage: Sending message failed. Connection ID: 5710626523942584577|#]

[#|2012-07-18T08:47:58.976-0400|INFO|oracle-glassfish3.1.2|javax.enterprise.system.std.com.sun.enterprise.server.logging|_ThreadID=47;_ThreadName=Thread-2;|2012-07-18 08:47:58,976 [Session5710626523942588672] ERROR com.foo.ejb.session.RealtimeCacheEJB$RealtimeCacheResourceChangeListener.onMessage(RealtimeCacheEJB.java:328): Failed to resend the resource change message
javax.jms.JMSException: MQJMSRA_DS4001: JMSServiceException on send message:sendMessage: Sending message failed. Connection ID: 5710626523942584577
                at com.sun.messaging.jms.ra.DirectSession._sendMessage(DirectSession.java:1844)
                at com.sun.messaging.jms.ra.DirectProducer._send(DirectProducer.java:1085)
                at com.sun.messaging.jms.ra.DirectProducer.send(DirectProducer.java:453)
                at com.foo.jms.JMSPublisher.send(JMSPublisher.java:81)
                at com.foo.ejb.session.RealtimeCacheEJB$RealtimeCacheResourceChangeListener.onMessage(RealtimeCacheEJB.java:324)
                at com.sun.messaging.jms.ra.DirectSession._deliverMessage(DirectSession.java:1895)
                at com.sun.messaging.jms.ra.DirectConsumer.deliver(DirectConsumer.java:369)
                at com.sun.messaging.jmq.jmsserver.service.imq.SessionListener.process(IMQDirectService.java:2928)
                at com.sun.messaging.jmq.jmsserver.service.imq.SessionListener.run(IMQDirectService.java:2866)
                at java.lang.Thread.run(Thread.java:662)
Caused by: com.sun.messaging.jmq.jmsservice.JMSServiceException: sendMessage: Sending message failed. Connection ID: 5710626523942584577
                at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.sendMessage(IMQDirectService.java:1955)
                at com.sun.messaging.jms.ra.DirectSession._sendMessage(DirectSession.java:1839)
                ... 9 more
Caused by: com.sun.messaging.jmq.jmsserver.util.BrokerException: [B4120]: Can not add message 800910-192.168.21.136(da:25:a2:a:c8:c6)-1-1342615678976 to destination fooRealtimeChange [Topic]. The destination message count limit (maxNumMsgs) of 100000 has been reached.
                at com.sun.messaging.jmq.jmsserver.core.Destination.queueMessage(Destination.java:3202)
                at com.sun.messaging.jmq.jmsserver.core.Destination.queueMessage(Destination.java:3087)
                at com.sun.messaging.jmq.jmsserver.core.Topic.queueMessage(Topic.java:211)
                at com.sun.messaging.jmq.jmsserver.data.handlers.DataHandler.queueMessage(DataHandler.java:440)
                at com.sun.messaging.jmq.jmsserver.data.protocol.ProtocolImpl.processMessage(ProtocolImpl.java:939)
                at com.sun.messaging.jmq.jmsserver.service.imq.IMQDirectService.sendMessage(IMQDirectService.java:1948)
                ... 10 more
Caused by: com.sun.messaging.jmq.util.lists.OutOfLimitsException: Capacity Exceeded was 100001 expected 100000
                at com.sun.messaging.jmq.util.lists.SimpleNFLHashMap.put(SimpleNFLHashMap.java:359)
                at com.sun.messaging.jmq.util.lists.SimpleNFLHashMap.put(SimpleNFLHashMap.java:291)
                at com.sun.messaging.jmq.jmsserver.core.Destination.putMessage(Destination.java:3271)
                at com.sun.messaging.jmq.jmsserver.core.Destination.queueMessage(Destination.java:3137)
                ... 15 more
|#]
Comments
Post Details
Added on Jul 18 2012
4 comments
3,912 views