[rabbitmq-discuss] Durable Queues

Tony Garnock-Jones tonyg at lshift.net
Fri Dec 14 13:54:19 GMT 2007


Hi Varun,

You're on the right track. Messages published in persistent mode to
durable queues will survive server restarts. You may wish to consider
using TX mode (txSelect, txCommit etc) to get some acknowledgement of
publication.

You can consume such messages just as if they were transient, that is
with basicGet() or basicConsume(), at your option.

What is the problem you are experiencing?

Regards,
  Tony


Varun Samuel wrote:
> I think someone posted about this earlier, but I'm still a little  
> stuck. I want to save messages in a queue to disk. I made the queue  
> durable like so:
> 
> channel.queueDeclare(ticket, queueName, false, true, true, false, null)
> 
> where the first true indicates the queue is durable. My messages are  
> tagged as persistent like this:
> 
> new AMQP.BasicProperties("", "", null, 2, 0, "", "", "", "", new Date 
> (), "", userName, "", "")
> 
> when setting the BasicProperties object.
> 
> I assume if you want to read messages from a durable cue you would  
> use channel.basicGet. I'm not sure where I'm going wrong
> with these steps, so any help would be appreciated.
> 
> Thanks,
> Varun
> 
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com
> http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
> 


-- 
 [][][] Tony Garnock-Jones     | Mob: +44 (0)7905 974 211
   [][] LShift Ltd             | Tel: +44 (0)20 7729 7060
 []  [] http://www.lshift.net/ | Email: tonyg at lshift.net




More information about the rabbitmq-discuss mailing list