Send Images using RabbitMQ

9.8k views Asked by At

I want to transfer an image from a client to the server using RabbitMQ. However, from whatever I read, I understood that RabbitMQ can only transfer a stream of text. So how to transfer an image?

1

There are 1 answers

2
Gabriele Santomaggio On

The amqp body is a buffer, you can send what you want.

In general, if you want to send a file, you have to read it and send the buffers.

You should send the file using more publish and not just one, then recreate the file on the consumer side.

You should avoid sending big buffer.