|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
T
- AbstractEntry implementation storing the data for sharing during exchange or parallel coordination of an event.public interface BatchHandler<T extends AbstractEntry>
Callback interface to be implemented for processing AbstractEntry
s as they become available in the RingBuffer
if you want to handle exceptions propigated out of the handler.
Method Summary | |
---|---|
void |
onAvailable(T entry)
Called when a publisher has committed an AbstractEntry to the RingBuffer |
void |
onEndOfBatch()
Called after each batch of items has been have been processed before the next waitFor call on a ConsumerBarrier . |
Method Detail |
---|
void onAvailable(T entry) throws java.lang.Exception
AbstractEntry
to the RingBuffer
entry
- committed to the RingBuffer
java.lang.Exception
- if the BatchHandler would like the exception handled further up the chain.void onEndOfBatch() throws java.lang.Exception
ConsumerBarrier
.
This can be taken as a hint to do flush type operations before waiting once again on the ConsumerBarrier
.
The user should not expect any pattern or frequency to the batch size.
java.lang.Exception
- if the BatchHandler would like the exception handled further up the chain.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |