Open molinto opened 8 years ago
As your package is a wrapper based on node-amqp, thought this would help: https://github.com/postwait/node-amqp#exchangepublishroutingkey-message-options-callback
Added header object to the options param of publish:
RabbitMQ.exchanges.DelayedExchange.publish('survey.send', new Buffer(post_data), { persistent: true, headers: { "x-delay": delay } }, function (err, ok) {
if (err) {
console.error("[AMQP] publish", err);
return err;
} else {
return ok;
}
});
But still no msg, hmmm.
Hi, I have a NormalExchange & a DelayedExchange. I'm using delayed parameter to send surveys after x amount of milliseconds on the DelayedExchange. Where do I put the x value on the publish please?
On lib/startup.js:
surveys.js (methods):
This is what node uses:
Any help greatly appreciated.
Sharry