3

I'm interested in finding out if ZMQ already compresses messages before sending them out so as to not do this myself which would be redundant to compress a message twice.

If it does do this is it automatic, or is there an option param to specify?

I'm using java but it really doesn't matter I guess for libzmq it doesn't matter.

dtrihinas
  • 446
  • 1
  • 4
  • 11

2 Answers2

4

ZMQ is not performing any serialization. You can send messages via socket as String or byte[]. See example here: http://zguide.zeromq.org/java:wuserver

publisher.send(update, 0);

where update is String.

In general I recommend guide here http://zguide.zeromq.org/page:all

2

OK so based on the help by Szymon Wlodarczyk I've managed to solve this by first going to the docs enter link description here and then moving on to jeromq (which is a pure java implementation of jmq) and specifically follow the trace: SocketBase > Pub > XPub > Dist you'll find out that there is no compression.

shashwat
  • 7,851
  • 9
  • 57
  • 90
dtrihinas
  • 446
  • 1
  • 4
  • 11