Skip to content

Commit

Permalink
Make SNS/SQS procuders to respect outputConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
ciscorn committed Apr 4, 2022
1 parent c584bb2 commit f977051
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public void setClient(AmazonSNSAsync client) {

@Override
public void sendAsync(RowMap r, CallbackCompleter cc) throws Exception {
String value = r.toJSON();
String value = r.toJSON(outputConfig);
// Publish a message to an Amazon SNS topic.
final PublishRequest publishRequest = new PublishRequest(topic, value);
Map<String, MessageAttributeValue> messageAttributes = new HashMap<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public MaxwellSQSProducer(MaxwellContext context, String queueUri) {

@Override
public void sendAsync(RowMap r, CallbackCompleter cc) throws Exception {
String value = r.toJSON();
String value = r.toJSON(outputConfig);
SendMessageRequest messageRequest = new SendMessageRequest(queueUri, value);
if ( queueUri.endsWith(".fifo")) {
messageRequest.setMessageGroupId(r.getDatabase());
Expand Down

0 comments on commit f977051

Please sign in to comment.