Package org.openmetadata.service.events
Class AbstractEventPublisher
java.lang.Object
org.openmetadata.service.events.AbstractEventPublisher
- All Implemented Interfaces:
com.lmax.disruptor.EventHandler<EventPubSub.ChangeEventHolder>,com.lmax.disruptor.LifecycleAware,EventPublisher
- Direct Known Subclasses:
EventMonitorPublisher
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final intprotected static final intprotected static final intprotected static final intprotected static final intprotected static final intprotected final List<ChangeEvent>protected int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidonEvent(EventPubSub.ChangeEventHolder changeEventHolder, long sequence, boolean endOfBatch) protected voidMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.openmetadata.service.events.EventPublisher
publishMethods inherited from interface com.lmax.disruptor.LifecycleAware
onShutdown, onStart
-
Field Details
-
BACKOFF_NORMAL
protected static final int BACKOFF_NORMAL- See Also:
-
BACKOFF_3_SECONDS
protected static final int BACKOFF_3_SECONDS- See Also:
-
BACKOFF_30_SECONDS
protected static final int BACKOFF_30_SECONDS- See Also:
-
BACKOFF_5_MINUTES
protected static final int BACKOFF_5_MINUTES- See Also:
-
BACKOFF_1_HOUR
protected static final int BACKOFF_1_HOUR- See Also:
-
BACKOFF_24_HOUR
protected static final int BACKOFF_24_HOUR- See Also:
-
currentBackoffTime
protected int currentBackoffTime -
batch
-
-
Constructor Details
-
AbstractEventPublisher
protected AbstractEventPublisher(int batchSize)
-
-
Method Details
-
onEvent
public void onEvent(EventPubSub.ChangeEventHolder changeEventHolder, long sequence, boolean endOfBatch) throws Exception - Specified by:
onEventin interfacecom.lmax.disruptor.EventHandler<EventPubSub.ChangeEventHolder>- Throws:
Exception
-
setNextBackOff
protected void setNextBackOff()
-