Hi

I have written a windows service which subscribes to a RabbitMQ queue.
The process creates object of Subscription class and waits for
messages to arrive. This is the bit of code I am talking about :

using (_subscription = new Subscription(_channel, _queue, false))
{
foreach (BasicDeliverEventArgs e in _subscription)
{
yield return e;
}
}

I all works fine when I am running it in development and testing
environment. But when I am deploying the same windows service in
production which has rabbitmq deployed as cluster of 2 nodes with HA
queues, the channel is getting closed and the service stops if there
is considerable(around an hour) idle time on the queues. If there
messages being published to queues continuously, it works fine. I was
wondering if this has to do with some RabbitMQ configuration(allowed
idle time for channel or queue) ?

Thanks
Mayank

Search Discussions

  • Emile Joubert at Jan 18, 2012 at 1:54 pm
    Hi,
    On 18/01/12 13:39, mayank wrote:

    I all works fine when I am running it in development and testing
    environment. But when I am deploying the same windows service in
    production which has rabbitmq deployed as cluster of 2 nodes with HA
    queues, the channel is getting closed and the service stops if there
    is considerable(around an hour) idle time on the queues. If there
    messages being published to queues continuously, it works fine. I was
    wondering if this has to do with some RabbitMQ configuration(allowed
    idle time for channel or queue) ?
    Is the channel being closed with an error? Does anything get logged in
    the broker logfile? If the network configuration differs between the two
    environments then you might try to enable AMQP heartbeats to prevent and
    detect timeouts.



    -Emile
  • Jrob at Jan 18, 2012 at 5:19 pm
    I saw a similar error when connecting to nodes through a proxy, which
    automatically timed out the connection after 2 minutes. The AMQP gem I use
    allows me to set up reconnection logic in the event of a disconnection,
    does your client library allow for the same?

    - jrob
    -------------- next part --------------
    An HTML attachment was scrubbed...
    URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20120118/63580b0f/attachment.htm>

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprabbitmq-discuss @
categoriesrabbitmq
postedJan 18, '12 at 1:39p
activeJan 18, '12 at 5:19p
posts3
users3
websiterabbitmq.com
irc#rabbitmq

3 users in discussion

Emile Joubert: 1 post Mayank: 1 post Jrob: 1 post

People

Translate

site design / logo © 2021 Grokbase