|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.flume.sink.kite.policy.RetryPolicy
public class RetryPolicy
A failure policy that logs the error and then forces a retry by throwing
EventDeliveryException
.
Nested Class Summary | |
---|---|
static class |
RetryPolicy.Builder
|
Method Summary | |
---|---|
void |
close()
Close this FailurePolicy and release any resources. |
void |
handle(Event event,
Throwable cause)
Handle a non-recoverable event. |
void |
sync()
Ensure any handled events are on stable storage. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public void handle(Event event, Throwable cause) throws EventDeliveryException
FailurePolicy
handle
in interface FailurePolicy
event
- The eventcause
- The cause of the failure
EventDeliveryException
- The policy failed to handle the event. When
this is thrown, the Flume transaction will
be rolled back and the event will be retried
along with the rest of the batch.public void sync() throws EventDeliveryException
FailurePolicy
Syncable.sync()
.
sync
in interface FailurePolicy
EventDeliveryException
- The policy failed while syncing data.
When this is thrown, the Flume transaction
will be rolled back and the batch will be
retried.public void close() throws EventDeliveryException
FailurePolicy
close
in interface FailurePolicy
EventDeliveryException
- The policy failed while closing resources.
When this is thrown, the Flume transaction
will be rolled back and the batch will be
retried.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |