Open akberc opened 8 years ago
Hi @akberc
You can use the annotation @Header
or @Headers
in this case.
@SqsListener("queueName")
public void listenerMethod(@Header("MessageId") String messageId) {/*...*/}
// OR
@SqsListener("queueName")
public void listenerMethod(@Headers Map<String, String> headers) {/*...*/}
Hi @adriancole I need to get this message id, when I send a message, not get that when consumer message.
any update on tihs?
The
sendInternal
method of QueueMessageChannel only returns a boolean and the class is designed in a way that does not support extension.In addition,
SendMessageRequest
cannot be manually invoked as the auto-configured queue URL is not exposed or easily retrievable.We had a CQRS pattern project in which we needed to retrieve the message ID for status update from the queue consumer.