[rabbitmq-discuss] Channel and basicAck

54 views
Skip to first unread message

Philippe Kirsanov

unread,
Sep 15, 2009, 12:27:38 PM9/15/09
to rabbitmq...@lists.rabbitmq.com

I'm using Java library and basicConsume to receive messages.

Messages are retrieved and queued without ack and I need to ack messages before I start process it. Since channels are not thread-safe and I noticed that delivery tag is channel-specific (I cannot use different channel to ack message received by other channel), what is proper way to ack messages? Channel that receives messages leaves in Connection thread (this is the way Java lib works), but ack needs to be sent from another thread.

 

Matthias Radestock

unread,
Sep 17, 2009, 5:47:19 AM9/17/09
to Philippe Kirsanov, rabbitmq...@lists.rabbitmq.com
Philippe,

The use of a channel by the connection thread is thread-safe. So you
only have to ensure that there aren't multiple *application* threads
interacting with the channel concurrently.


Regards,

Matthias.

_______________________________________________
rabbitmq-discuss mailing list
rabbitmq...@lists.rabbitmq.com
http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss

Reply all
Reply to author
Forward
0 new messages