soaplee
soaplee

Reputation: 25

how to specify zmq swap file path

I am using the ZeroMQ C++ libary. The ZMQ_SWAP option puts outstanding messages to storage on disk. How can I specify a swap file? The zmq_setsokopt function only sets swap size like this:

uint64_t swap = 25000000;
zmq_setsockopt (publisher, ZMQ_SWAP, &swap, sizeof (swap));

Upvotes: 1

Views: 670

Answers (1)

SteveLove
SteveLove

Reputation: 3207

ZMQ_SWAP has been removed in v3.x of 0MQ, due to problems implementing it. As far as I can tell, the option to specify the path was never implemented.

If you're using this option in v2.1.x, you'll need to redesign in any case in order to upgrade to a more recent version of 0MQ.

See here and here for more details.

Upvotes: 3

Related Questions