Package org.apache.nifi.cdc.event.io
Interface EventWriter<T extends EventInfo>
- All Known Implementing Classes:
AbstractEventWriter
public interface EventWriter<T extends EventInfo>
An interface to write an event to the process session. Note that a single event may produce multiple flow files.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionlongwriteEvent(org.apache.nifi.processor.ProcessSession session, String transitUri, T eventInfo, long currentSequenceId, org.apache.nifi.processor.Relationship relationship, EventWriterConfiguration eventWriterConfiguration) Writes the given event to the process session, possibly via transferring it to the specified relationship (usually used for success)
-
Field Details
-
APPLICATION_JSON
- See Also:
-
SEQUENCE_ID_KEY
- See Also:
-
CDC_EVENT_TYPE_ATTRIBUTE
- See Also:
-
-
Method Details
-
writeEvent
long writeEvent(org.apache.nifi.processor.ProcessSession session, String transitUri, T eventInfo, long currentSequenceId, org.apache.nifi.processor.Relationship relationship, EventWriterConfiguration eventWriterConfiguration) Writes the given event to the process session, possibly via transferring it to the specified relationship (usually used for success)- Parameters:
session- The session to write the event totransitUri- The URI indicating the source MySQL system from which the specified event is associatedeventInfo- The event datacurrentSequenceId- The current sequence IDrelationship- A relationship to transfer any flowfile(s) toeventWriterConfiguration- A configuration object used for FlowFile management (how many events to write to each FlowFile, e.g.)- Returns:
- a sequence ID, usually incremented from the specified current sequence ID by the number of FlowFiles transferred and/or committed
-