Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Welcome to the jeromq wiki!
Please read the bible first.
JeroMQ ported guide examples.
- Context.term() must be called before interrupting a thread by Thread.interrupt. Otherwise internal pipe which is used to signal ZMQ commands will be shutdown unexpectedly.
- Sharing ZContext
zguide )Common mistakes (Already mentioned at the
- Close all the sockets properly otherwise Context.term() will wait forever
- Set a proper linger by using Socket.setLinger(millis) when you want to wait before socket termination. Otherwise some last messages could not be delivered.
- Set a propert HWM (High Water Mark). At 0MQ 3.x, you should set Socket.setSndHWM and setRcvHWM separately. The default value is 1000 each. -1 is unlimited but it could blow your memory.
- At PUB/SUB, PUB will drop messages silently when a connected sending pipe has more messages than HWM. Other available SUBs will can receive the messages.
- At PUSH/PULL, PUSH will block sending messages when there's no available PULL. Otherwise one of available PULL can receive the messages.
- If you're interested in LWM (Low Water Mark) also please refer compute_lwm at Pipe.java
- -server -XX:+UseConcMarkSweepGC
- -XX:+TieredCompilation (if you're using the latest JVM)
- At java7, tiered compilation is now the default mode for the server VM
- -XX:+UseCompressedOops might increase performance a little bit or not at 64bit OS
- enabled by default in Java SE 6u23 and later. In Java SE 7, use of compressed oops is the default for 64-bit JVM processes when -Xmx isn't specified and for values of -Xmx less than 32 gigabytes.
- -XX:+UseBiasedLocking might increase performance a little bit or not
- -XX:+UseNUMA could increase performance
Clone this wiki locally
Press h to open a hovercard with more details.