<font face="arial" size="2"><p style="margin:0;padding:0;font-family: arial; font-size: 10pt;">Hey All,</p>
<p style="margin:0;padding:0;font-family: arial; font-size: 10pt;"> </p>
<p style="margin:0;padding:0;font-family: arial; font-size: 10pt;">I am attempting to set the message ID (on a producer) and see that AMQP.BasicProperties.setMessageId() is deprecated. I believe that I should/could be using builder but the messageID is returning as null.</p>
<p style="margin:0;padding:0;font-family: arial; font-size: 10pt;"> </p>
<p style="margin:0;padding:0;">
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;"> AMQP.BasicProperties props = new AMQP.BasicProperties(); </span></p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;"> </span><span style="font-family: arial; font-size: small;"> props.builder().messageId("</span> <span style="font-family: arial; font-size: small;">yadada</span> <span style="font-family: arial; font-size: small;">");</span></p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;"><span style="white-space: pre;"> </span> props.builder().build();</span></p>
<p style="margin:0;padding:0;"> </p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;">channel.basicPublish(EXCHANGE_NAME, routingKey, props, message.getBytes());</span></p>
<p style="margin:0;padding:0;"> </p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;">does not return a messageID using:</span></p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;">
<p style="margin:0;padding:0;"><span style="white-space: pre;"> </span> QueueingConsumer.Delivery delivery = consumer.nextDelivery();</p>
<p style="margin:0;padding:0;"><span style="white-space: pre;"> </span> delivery.getProperties().getMessageId()</p>
</span></p>
<p style="margin:0;padding:0;"> </p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;">Using the deprecated AMQP.BasicProperties.setMessageId() works fine:</span></p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;"> props.setMessageId("yadada");</span></p>
<p style="margin:0;padding:0;"> </p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;">can someone point me in the right direction please.</span></p>
<p style="margin:0;padding:0;"> </p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;">Thanks,</span></p>
<p style="margin:0;padding:0;"><span style="font-family: arial; font-size: 10pt;">Matthew</span></p>
</p></font>