Skip to content

Commit

Permalink
Fix for Queue Headers
Browse files Browse the repository at this point in the history
  • Loading branch information
vinothon84 committed Apr 12, 2024
1 parent 7084fa0 commit c8a37e5
Showing 1 changed file with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,12 @@ private void sendMessage(NotifyCommand command, LogEvent event) {

private Map<String, MessageAttributeValue> getQueueHeaders(String eventType) {

return Map.of(EVENT_TYPE_HEADER,
MessageAttributeValue.builder()
.dataType(RequestData.CORRELATION_ID_HEADER).stringValue(requestData.correlationId())
.dataType(RequestData.USER_ID_HEADER).stringValue(requestData.userId())
.dataType(RequestData.USERNAME_HEADER).stringValue(requestData.username())
.dataType(RequestData.GROUP_HEADER).stringValue(requestData.groups())
.build());
return Map.of(
EVENT_TYPE_HEADER, MessageAttributeValue.builder().stringValue(eventType).build(),
RequestData.CORRELATION_ID_HEADER, MessageAttributeValue.builder().stringValue(requestData.correlationId()).build(),
RequestData.USER_ID_HEADER, MessageAttributeValue.builder().stringValue(requestData.userId()).build(),
RequestData.USERNAME_HEADER, MessageAttributeValue.builder().stringValue(requestData.username()).build(),
RequestData.GROUP_HEADER, MessageAttributeValue.builder().stringValue(requestData.groups()).build());

/*return Map.of(EVENT_TYPE_HEADER, new MessageAttributeValue(eventType),
RequestData.CORRELATION_ID_HEADER, new SqsStringMessageAttributeValue(requestData.correlationId()),
Expand Down

0 comments on commit c8a37e5

Please sign in to comment.