[rabbitmq-discuss] Can rabbitMQ publish an object to the queue?

Simon MacMullen simon at rabbitmq.com
Mon May 14 11:36:27 BST 2012


On 12/05/12 10:44, aluen wrote:
> the underline words is what I want to ask,how to  deal with it , can I
> put an object to the queue because I hope to do like this ,do you have
> other method? Thanks!!

Hi Aluen. RabbitMQ treats message bodies as opaque binary data. If you 
want to send objects you'll need to serialise them - if you're only 
using Python you could pickle the objects. Otherwise you would need to 
write out JSON or XML or similar.

Cheers, Simon

-- 
Simon MacMullen
RabbitMQ, VMware


More information about the rabbitmq-discuss mailing list