activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From TrainTime <>
Subject C# Consumers Disconnecting
Date Mon, 27 Aug 2012 19:48:06 GMT
            I've been trying to figure out this problem I've been having with
apache NMS for at least a week now, so I decided maybe I would try to post
here and see if anyone has experienced similar issues.  In my situation, we
have about 5-7 producers all producing to one topic, and then we have one
consumer consuming data from the same topic.  However, this singular
consumer will suddenly disconnect from the broker with no indication to me
(that i've been able to find) and stop receiving anything, the only way to
tell is by checking the broker and seeing that the topic has no consumers. I
have been searching around these forums for a solution and here's a few
things I tried that didn't seem to make any difference:

         1. Set ?wireFormat.maxInactivityDuration=0 on my openWire transport
         2. Set my IConnection and ISession to be auto acknowledge
         3. Changed the memory limit of topics to 100mb from 1 mb
         4. Call IMessage.Acknowledge after receiving a message
         5. Changed IConnection and ISession to be persistent object along
with the consumer

      I'm not sure what else at this point I have to try.  I'm using
activeMQ 5.6 SNAPSHOT which runs as a service, Apache.NMS, and
Apache.NMS.ActiveMQ  Also one last thing, here's how I'm
creating my consumer in the C# code:

 //setup jms
                        IConnectionFactory factory = new

                        _connection = factory.CreateConnection();
                        _connection.AcknowledgementMode =
                        _connection.ConnectionInterruptedListener +=

                        _session =

                        _consumer = _session.CreateConsumer(new
                        _consumer.Listener += ProcessItem;

                        _status.Status = ConnectorStatus.Running;
                        _status.Details = "JMS Connector is running";

And here's what the consumer listener function looks like:

public void ProcessItem(IMessage message)
             /*  code */

I also tried looking at Apache logging a bit, but it didn't seem to output
anything useful.  I think I need to change what its logging, is ERROR the
correct syntax for the sl4j logging properties file?  Thanks in advance for
any help anyone can offer, this has been driving me nuts ><

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message