activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dom <thephe...@gmail.com>
Subject ActiveMQ Session Task threads disappearing
Date Tue, 13 Sep 2011 17:18:38 GMT
Hi,

I've starting having unusual problems with my ActiveMQ consumers, we send
object messages via JMS 24 hours a day, peaking at around 10k per second to
various different consumers. All these consumers are consuming from the same
topic, however from different physical servers. The consumers are all based
on the same abstract class (from a shared JAR).

On our servers running Java 6 build 20 we haven't seen an issue. We have
some newer servers running in Java 6 build 26, and these servers some times
have the issue.

The problem is; Some of the consumers will randomly simply stop consuming -
still be sent messages from ActiveMQ, just stop passing them into our code
base. After a while this causes all consumers on that topic to stop
receiving messages (once our buffer on ActiveMQ fills up).

It seems (according to thread dumps) that when this happens we have "lost"
the ActiveMQ session task threads. The transport threads will still be
there, just not the session tasks. We have try catch (Exception) in all our
onMessage methods which *should* catch everything.

I have to restart the jvm to get it to work again, which is not ideal in a
production environment.

Does anybody have any ideas?

Thanks,

Dom

PS: This is our consumer create code;

ActiveMQConnectionFactory connectionFactory = new
ActiveMQConnectionFactory(jmsConfig.getUserName(), jmsConfig.getPassword(),
jmsConfig.getUrl());
connection = connectionFactory.createConnection();
if (clientID.length() > 0) {
    connection.setClientID(clientID);
}

connection.setExceptionListener(this);
connection.start();
// transacted is false and session is set to auto ack mode.
session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
			        
// our destination topic subject on which we receive objects.
Destination destination = session.createTopic(topicSubject);
consumer = session.createConsumer(destination);
			        
consumer.setMessageListener(this);


--
View this message in context: http://activemq.2283324.n4.nabble.com/ActiveMQ-Session-Task-threads-disappearing-tp3810649p3810649.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Mime
View raw message