jai1 commented on a change in pull request #3991: [pulsar-storm] Fix NPE while emitting next tuple URL: https://github.com/apache/pulsar/pull/3991#discussion_r272762647
########## File path: pulsar-storm/src/main/java/org/apache/pulsar/storm/PulsarSpout.java ########## @@ -215,6 +204,36 @@ public void emitNextAvailableTuple() { } } + private boolean emitFailedMessage() { + Message<byte[]> msg; + + while ((msg = failedMessages.peek()) != null) { + MessageRetries messageRetries = pendingMessageRetries.get(msg.getMessageId()); + if (messageRetries != null) { Review comment: Move this if statement to a separate function. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services