I'm trying to read reply_to param from message with no success. I'm using rabbitcpp C++ library for Message Queue Server RabbitMQ https://github.com/akalend/amqpcpp
AMQPQueue * qu2 = amqp.createQueue();
qu2->Declare("test", AMQP_DURABLE);
qu2->Get(AMQP_NOACK);
AMQPMessage * m = qu2->getMessage();
if (m->getMessageCount() > -1) {
uint32_t j = 0;
std::string response = m->getMessage(&j);
std::string replyTo = m->getHeader("reply_to");
}
And m->getHeader("reply_to")
is empty.
You should use the parameter with a capital letter "Reply-to", additional information about headers you can find in AMQPExchange.cpp.