Class EventDispatcher
- java.lang.Object
-
- io.debezium.outbox.quarkus.internal.EventDispatcher
-
@ApplicationScoped public class EventDispatcher extends Object
An application-scope component that is responsible for observingExportedEventevents and when detected, persists those events to the underlying database allowing Debezium to then capture and emit those change events.- Author:
- Chris Cranford
-
-
Field Summary
Fields Modifier and Type Field Description private static StringAGGREGATE_IDprivate static StringAGGREGATE_TYPE(package private) DebeziumOutboxRuntimeConfigconfigDebezium runtime configuration(package private) javax.persistence.EntityManagerentityManagerprivate static org.slf4j.LoggerLOGGERprivate static StringOPERATION_NAMEprivate static StringPAYLOADprivate static StringTIMESTAMP(package private) io.opentracing.Tracertracerprivate static StringTRACING_COMPONENTstatic StringTRACING_SPAN_CONTEXTprivate static StringTYPE
-
Constructor Summary
Constructors Constructor Description EventDispatcher()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidonExportedEvent(ExportedEvent<?,?> event)An event handler forExportedEventevents and will be called when the event fires.
-
-
-
Field Detail
-
OPERATION_NAME
private static final String OPERATION_NAME
- See Also:
- Constant Field Values
-
TIMESTAMP
private static final String TIMESTAMP
- See Also:
- Constant Field Values
-
PAYLOAD
private static final String PAYLOAD
- See Also:
- Constant Field Values
-
TYPE
private static final String TYPE
- See Also:
- Constant Field Values
-
AGGREGATE_ID
private static final String AGGREGATE_ID
- See Also:
- Constant Field Values
-
AGGREGATE_TYPE
private static final String AGGREGATE_TYPE
- See Also:
- Constant Field Values
-
TRACING_SPAN_CONTEXT
public static final String TRACING_SPAN_CONTEXT
- See Also:
- Constant Field Values
-
TRACING_COMPONENT
private static final String TRACING_COMPONENT
- See Also:
- Constant Field Values
-
LOGGER
private static final org.slf4j.Logger LOGGER
-
entityManager
@Inject javax.persistence.EntityManager entityManager
-
config
@Inject DebeziumOutboxRuntimeConfig config
Debezium runtime configuration
-
tracer
@Inject io.opentracing.Tracer tracer
-
-
Method Detail
-
onExportedEvent
public void onExportedEvent(@Observes ExportedEvent<?,?> event)An event handler forExportedEventevents and will be called when the event fires.- Parameters:
event- the exported event
-
-