Skip to content

Commit

Permalink
fix(sqs inbound): fix NPE when deactivate (#712)
Browse files Browse the repository at this point in the history
  • Loading branch information
Oleksiivanov authored Jun 8, 2023
1 parent 71cd24d commit 6bf618e
Showing 1 changed file with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,10 @@ public void activate(final InboundConnectorContext context) {
properties.getAuthentication().getSecretKey(),
properties.getQueue().getRegion());
LOGGER.debug("SQS client created successfully");

executorService.execute(
sqsQueueConsumer == null
? new SqsQueueConsumer(amazonSQS, properties, context)
: sqsQueueConsumer);

if (sqsQueueConsumer == null) {
sqsQueueConsumer = new SqsQueueConsumer(amazonSQS, properties, context);
}
executorService.execute(sqsQueueConsumer);
LOGGER.debug("SQS queue consumer started successfully");
}

Expand Down

0 comments on commit 6bf618e

Please sign in to comment.