public class ExponentialBackoffMsgRetryManager extends Object implements FailedMsgRetryManager
| Constructor and Description |
|---|
ExponentialBackoffMsgRetryManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
acked(Long offset)
Message corresponding to the offset, was acked to kafka spout.
|
Set<Long> |
clearOffsetsBefore(Long kafkaOffset)
Clear any offsets before kafkaOffset.
|
void |
failed(Long offset)
Message corresponding to the offset failed in kafka spout.
|
Long |
nextFailedMessageToRetry()
The offset of message, which is to be re-emitted.
|
void |
prepare(SpoutConfig spoutConfig,
Map stormConf)
Initialization
|
boolean |
retryFurther(Long offset)
Spout will clean up the state for this offset if false is returned.
|
void |
retryStarted(Long offset)
Message corresponding to the offset, has been re-emitted and under transit.
|
boolean |
shouldReEmitMsg(Long offset) |
public void prepare(SpoutConfig spoutConfig, Map stormConf)
FailedMsgRetryManagerInitialization
prepare in interface FailedMsgRetryManagerpublic void failed(Long offset)
FailedMsgRetryManagerMessage corresponding to the offset failed in kafka spout.
failed in interface FailedMsgRetryManagerpublic void acked(Long offset)
FailedMsgRetryManagerMessage corresponding to the offset, was acked to kafka spout.
acked in interface FailedMsgRetryManagerpublic void retryStarted(Long offset)
FailedMsgRetryManagerMessage corresponding to the offset, has been re-emitted and under transit.
retryStarted in interface FailedMsgRetryManagerpublic Long nextFailedMessageToRetry()
FailedMsgRetryManagerThe offset of message, which is to be re-emitted. Spout will fetch messages starting from this offset and resend them, except completed messages.
nextFailedMessageToRetry in interface FailedMsgRetryManagerpublic boolean shouldReEmitMsg(Long offset)
shouldReEmitMsg in interface FailedMsgRetryManagerpublic boolean retryFurther(Long offset)
FailedMsgRetryManagerSpout will clean up the state for this offset if false is returned.
retryFurther in interface FailedMsgRetryManagerpublic Set<Long> clearOffsetsBefore(Long kafkaOffset)
FailedMsgRetryManagerClear any offsets before kafkaOffset. These offsets are no longer available in kafka.
clearOffsetsBefore in interface FailedMsgRetryManagerCopyright © 2019 The Apache Software Foundation. All Rights Reserved.