public class MockProvenanceReporter extends java.lang.Object implements ProvenanceReporter
Constructor and Description |
---|
MockProvenanceReporter(MockProcessSession session,
SharedSessionState sharedState,
java.lang.String processorId,
java.lang.String processorType) |
Modifier and Type | Method and Description |
---|---|
void |
associate(FlowFile flowFile,
java.lang.String alternateIdentifierNamespace,
java.lang.String alternateIdentifier)
Emits a Provenance Event of type
ADDINFO that provides a linkage
between the given FlowFile and alternate identifier. |
void |
clone(FlowFile parent,
FlowFile child)
Emits a Provenance Event of type
CLONE
that establishes that the given child is an exact replica of the parent. |
void |
create(FlowFile flowFile)
Emits a Provenance Event of type
CREATE that indicates that the given
FlowFile was created by NiFi from data that was not received from an
external entity. |
void |
create(FlowFile flowFile,
java.lang.String details)
Emits a Provenance Event of type
CREATE that indicates that the given
FlowFile was created by NiFi from data that was not received from an
external entity. |
void |
fetch(FlowFile flowFile,
java.lang.String transitUri)
Emits a Provenance Event of type
FETCH that indicates that the content of the given
FlowFile was overwritten with the data received from an external source. |
void |
fetch(FlowFile flowFile,
java.lang.String transitUri,
long transmissionMillis)
Emits a Provenance Event of type
FETCH that indicates that the content of the given
FlowFile was overwritten with the data received from an external source. |
void |
fetch(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String details,
long transmissionMillis)
Emits a Provenance Event of type
FETCH that indicates that the content of the given
FlowFile was overwritten with the data received from an external source. |
void |
fork(FlowFile parent,
java.util.Collection<FlowFile> children)
Emits a Provenance Event of type
FORK
that establishes that the given parent was split into multiple child
FlowFiles. |
void |
fork(FlowFile parent,
java.util.Collection<FlowFile> children,
long forkDuration)
Emits a Provenance Event of type
FORK
that establishes that the given parent was split into multiple child
FlowFiles. |
void |
fork(FlowFile parent,
java.util.Collection<FlowFile> children,
java.lang.String details)
Emits a Provenance Event of type
FORK
that establishes that the given parent was split into multiple child
FlowFiles. |
void |
fork(FlowFile parent,
java.util.Collection<FlowFile> children,
java.lang.String details,
long forkDuration)
Emits a Provenance Event of type
FORK
that establishes that the given parent was split into multiple child
FlowFiles. |
void |
join(java.util.Collection<FlowFile> parents,
FlowFile child)
Emits a Provenance Event of type
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. |
void |
join(java.util.Collection<FlowFile> parents,
FlowFile child,
long joinDuration)
Emits a Provenance Event of type
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. |
void |
join(java.util.Collection<FlowFile> parents,
FlowFile child,
java.lang.String details)
Emits a Provenance Event of type
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. |
void |
join(java.util.Collection<FlowFile> parents,
FlowFile child,
java.lang.String details,
long joinDuration)
Emits a Provenance Event of type
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. |
void |
modifyAttributes(FlowFile flowFile)
Emits a Provenance Event of type
ATTRIBUTES_MODIFIED that
indicates that the Attributes of the given FlowFile were updated. |
void |
modifyAttributes(FlowFile flowFile,
java.lang.String details)
Emits a Provenance Event of type
ATTRIBUTES_MODIFIED that
indicates that the Attributes of the given FlowFile were updated. |
void |
modifyContent(FlowFile flowFile)
Emits a Provenance Event of type
CONTENT_MODIFIED that
indicates that the content of the given FlowFile has been modified. |
void |
modifyContent(FlowFile flowFile,
long processingMillis)
Emits a Provenance Event of type
CONTENT_MODIFIED that
indicates that the content of the given FlowFile has been modified. |
void |
modifyContent(FlowFile flowFile,
java.lang.String details)
Emits a Provenance Event of type
CONTENT_MODIFIED that
indicates that the content of the given FlowFile has been modified. |
void |
modifyContent(FlowFile flowFile,
java.lang.String details,
long processingMillis)
Emits a Provenance Event of type
CONTENT_MODIFIED that
indicates that the content of the given FlowFile has been modified. |
void |
receive(FlowFile flowFile,
java.lang.String transitUri)
Emits a Provenance Event of type
RECEIVE that indicates that the given
FlowFile was created from data received from an external source. |
void |
receive(FlowFile flowFile,
java.lang.String transitUri,
long transmissionMillis)
Emits a Provenance Event of type
RECEIVE that indicates that the given
FlowFile was created from data received from an external source. |
void |
receive(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String sourceSystemFlowFileIdentifier)
Emits a Provenance Event of type
RECEIVE that indicates that the given
FlowFile was created from data received from the specified URI and that
the source system used the specified identifier (a URI with namespace) to
refer to the data. |
void |
receive(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String sourceSystemFlowFileIdentifier,
long transmissionMillis)
Emits a Provenance Event of type
RECEIVE that indicates that the given
FlowFile was created from data received from an external source and
provides additional details about the receipt of the FlowFile, such as a
remote system's Distinguished Name. |
void |
receive(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String sourceSystemFlowFileIdentifier,
java.lang.String details,
long transmissionMillis)
Emits a Provenance Event of type
RECEIVE that indicates that the given
FlowFile was created from data received from an external source and
provides additional details about the receipt of the FlowFile, such as a
remote system's Distinguished Name. |
void |
route(FlowFile flowFile,
Relationship relationship)
Emits a Provenance Event of type
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship . |
void |
route(FlowFile flowFile,
Relationship relationship,
long processingDuration)
Emits a Provenance Event of type
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship . |
void |
route(FlowFile flowFile,
Relationship relationship,
java.lang.String details)
Emits a Provenance Event of type
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship . |
void |
route(FlowFile flowFile,
Relationship relationship,
java.lang.String details,
long processingDuration)
Emits a Provenance Event of type
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship . |
void |
send(FlowFile flowFile,
java.lang.String transitUri)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
void |
send(FlowFile flowFile,
java.lang.String transitUri,
boolean force)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
void |
send(FlowFile flowFile,
java.lang.String transitUri,
long transmissionMillis)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
void |
send(FlowFile flowFile,
java.lang.String transitUri,
long transmissionMillis,
boolean force)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
void |
send(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String details)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
void |
send(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String details,
boolean force)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
void |
send(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String details,
long transmissionMillis)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
void |
send(FlowFile flowFile,
java.lang.String transitUri,
java.lang.String details,
long transmissionMillis,
boolean force)
Emits a Provenance Event of type
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. |
public MockProvenanceReporter(MockProcessSession session, SharedSessionState sharedState, java.lang.String processorId, java.lang.String processorType)
public void receive(FlowFile flowFile, java.lang.String transitUri)
ProvenanceReporter
RECEIVE
that indicates that the given
FlowFile was created from data received from an external source.receive
in interface ProvenanceReporter
flowFile
- the FlowFile that was receivedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.public void receive(FlowFile flowFile, java.lang.String transitUri, java.lang.String sourceSystemFlowFileIdentifier)
ProvenanceReporter
RECEIVE
that indicates that the given
FlowFile was created from data received from the specified URI and that
the source system used the specified identifier (a URI with namespace) to
refer to the data.receive
in interface ProvenanceReporter
flowFile
- the FlowFile that was receivedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.sourceSystemFlowFileIdentifier
- the URI/identifier that the source
system uses to refer to the data; if this value is non-null and is not a
URI, the prefix "urn:tdo:" will be used to form a URI.public void receive(FlowFile flowFile, java.lang.String transitUri, long transmissionMillis)
ProvenanceReporter
RECEIVE
that indicates that the given
FlowFile was created from data received from an external source.receive
in interface ProvenanceReporter
flowFile
- the FlowFile that was receivedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.transmissionMillis
- the number of milliseconds taken to transfer
the datapublic void receive(FlowFile flowFile, java.lang.String transitUri, java.lang.String sourceSystemFlowFileIdentifier, long transmissionMillis)
ProvenanceReporter
RECEIVE
that indicates that the given
FlowFile was created from data received from an external source and
provides additional details about the receipt of the FlowFile, such as a
remote system's Distinguished Name.receive
in interface ProvenanceReporter
flowFile
- the FlowFile that was receivedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.sourceSystemFlowFileIdentifier
- details about the receive event; for example, it may be
relevant to include the DN of the sending systemtransmissionMillis
- the number of milliseconds taken to transfer
the datapublic void receive(FlowFile flowFile, java.lang.String transitUri, java.lang.String sourceSystemFlowFileIdentifier, java.lang.String details, long transmissionMillis)
ProvenanceReporter
RECEIVE
that indicates that the given
FlowFile was created from data received from an external source and
provides additional details about the receipt of the FlowFile, such as a
remote system's Distinguished Name.receive
in interface ProvenanceReporter
flowFile
- the FlowFile that was receivedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.sourceSystemFlowFileIdentifier
- the URI/identifier that the source
system uses to refer to the data; if this value is non-null and is not a
URI, the prefix "urn:tdo:" will be used to form a URI.details
- details about the receive event; for example, it may be
relevant to include the DN of the sending systemtransmissionMillis
- the number of milliseconds taken to transfer
the datapublic void fetch(FlowFile flowFile, java.lang.String transitUri)
ProvenanceReporter
FETCH
that indicates that the content of the given
FlowFile was overwritten with the data received from an external source.fetch
in interface ProvenanceReporter
flowFile
- the FlowFile whose content was replacedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred.public void fetch(FlowFile flowFile, java.lang.String transitUri, long transmissionMillis)
ProvenanceReporter
FETCH
that indicates that the content of the given
FlowFile was overwritten with the data received from an external source.fetch
in interface ProvenanceReporter
flowFile
- the FlowFile whose content was replacedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred.transmissionMillis
- the number of milliseconds taken to transfer the datapublic void fetch(FlowFile flowFile, java.lang.String transitUri, java.lang.String details, long transmissionMillis)
ProvenanceReporter
FETCH
that indicates that the content of the given
FlowFile was overwritten with the data received from an external source.fetch
in interface ProvenanceReporter
flowFile
- the FlowFile whose content was replacedtransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred.details
- details about the eventtransmissionMillis
- the number of milliseconds taken to transfer
the datapublic void send(FlowFile flowFile, java.lang.String transitUri, long transmissionMillis)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.transmissionMillis
- the number of milliseconds spent sending the
data to the remote systempublic void send(FlowFile flowFile, java.lang.String transitUri)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.public void send(FlowFile flowFile, java.lang.String transitUri, java.lang.String details)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.details
- additional details related to the SEND event, such as a
remote system's Distinguished Namepublic void send(FlowFile flowFile, java.lang.String transitUri, long transmissionMillis, boolean force)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.transmissionMillis
- the number of milliseconds spent sending the
data to the remote systemforce
- if true
, this event will be added to the
Provenance Repository immediately and will still be persisted if the
ProcessSession
to which this
ProvenanceReporter is associated is rolled back. Otherwise, the Event
will be recorded only on a successful session commit.public void send(FlowFile flowFile, java.lang.String transitUri, java.lang.String details, boolean force)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.details
- additional details related to the SEND event, such as a
remote system's Distinguished Nameforce
- if true
, this event will be added to the
Provenance Repository immediately and will still be persisted if the
ProcessSession
to which this
ProvenanceReporter is associated is rolled back. Otherwise, the Event
will be recorded only on a successful session commit.public void send(FlowFile flowFile, java.lang.String transitUri, java.lang.String details, long transmissionMillis)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.details
- additional details related to the SEND event, such as a
remote system's Distinguished NametransmissionMillis
- the number of milliseconds spent sending the
data to the remote systempublic void send(FlowFile flowFile, java.lang.String transitUri, java.lang.String details, long transmissionMillis, boolean force)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.details
- additional details related to the SEND event, such as a
remote system's Distinguished NametransmissionMillis
- the number of milliseconds spent sending the
data to the remote systemforce
- if true
, this event will be added to the
Provenance Repository immediately and will still be persisted if the
ProcessSession
to which this
ProvenanceReporter is associated is rolled back. Otherwise, the Event
will be recorded only on a successful session commit.public void send(FlowFile flowFile, java.lang.String transitUri, boolean force)
ProvenanceReporter
SEND
that indicates that a copy of the given FlowFile was sent to an external
destination. The external destination may be a remote system or may be a
local destination, such as the local file system but is external to NiFi.send
in interface ProvenanceReporter
flowFile
- the FlowFile that was senttransitUri
- A URI that provides information about the System and
Protocol information over which the transfer occurred. The intent of this
field is such that both the sender and the receiver can publish the
events to an external Enterprise-wide system that is then able to
correlate the SEND and RECEIVE events.force
- if true
, this event will be added to the
Provenance Repository immediately and will still be persisted if the
ProcessSession
to which this
ProvenanceReporter is associated is rolled back. Otherwise, the Event
will be recorded only on a successful session commit.public void associate(FlowFile flowFile, java.lang.String alternateIdentifierNamespace, java.lang.String alternateIdentifier)
ProvenanceReporter
ADDINFO
that provides a linkage
between the given FlowFile and alternate identifier. This information can
be useful if published to an external, enterprise-wide Provenance
tracking system that is able to associate the data between different
processes.associate
in interface ProvenanceReporter
flowFile
- the FlowFile for which the association should be madealternateIdentifierNamespace
- the namespace of the alternate systemalternateIdentifier
- the identifier that the alternate system uses
when referring to the data that is encompassed by this FlowFilepublic void fork(FlowFile parent, java.util.Collection<FlowFile> children)
ProvenanceReporter
FORK
that establishes that the given parent was split into multiple child
FlowFiles. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.fork
in interface ProvenanceReporter
parent
- the FlowFile from which the children are derivedchildren
- the FlowFiles that are derived from the parent.public void fork(FlowFile parent, java.util.Collection<FlowFile> children, long forkDuration)
ProvenanceReporter
FORK
that establishes that the given parent was split into multiple child
FlowFiles. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.fork
in interface ProvenanceReporter
parent
- the FlowFile from which the children are derivedchildren
- the FlowFiles that are derived from the parent.forkDuration
- the number of milliseconds that it took to perform
the taskpublic void fork(FlowFile parent, java.util.Collection<FlowFile> children, java.lang.String details)
ProvenanceReporter
FORK
that establishes that the given parent was split into multiple child
FlowFiles. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.fork
in interface ProvenanceReporter
parent
- the FlowFile from which the children are derivedchildren
- the FlowFiles that are derived from the parent.details
- any details pertinent to the forkpublic void fork(FlowFile parent, java.util.Collection<FlowFile> children, java.lang.String details, long forkDuration)
ProvenanceReporter
FORK
that establishes that the given parent was split into multiple child
FlowFiles. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.fork
in interface ProvenanceReporter
parent
- the FlowFile from which the children are derivedchildren
- the FlowFiles that are derived from the parent.details
- any details pertinent to the forkforkDuration
- the number of milliseconds that it took to perform
the taskpublic void join(java.util.Collection<FlowFile> parents, FlowFile child)
ProvenanceReporter
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.join
in interface ProvenanceReporter
parents
- the FlowFiles that are being joined together to create the
childchild
- the FlowFile that is being created by joining the parentspublic void join(java.util.Collection<FlowFile> parents, FlowFile child, long joinDuration)
ProvenanceReporter
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.join
in interface ProvenanceReporter
parents
- the FlowFiles that are being joined together to create the
childchild
- the FlowFile that is being created by joining the parentsjoinDuration
- the number of milliseconds that it took to join the
FlowFilespublic void join(java.util.Collection<FlowFile> parents, FlowFile child, java.lang.String details)
ProvenanceReporter
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.join
in interface ProvenanceReporter
parents
- the FlowFiles that are being joined together to create the
childchild
- the FlowFile that is being created by joining the parentsdetails
- any details pertinent to the eventpublic void join(java.util.Collection<FlowFile> parents, FlowFile child, java.lang.String details, long joinDuration)
ProvenanceReporter
JOIN
that establishes that the given parents were joined together to create a
new child FlowFile. In general, this method does not need to be called by
Processors, as the ProcessSession will handle this automatically for you
when calling ProcessSession.create(FlowFile)
.join
in interface ProvenanceReporter
parents
- the FlowFiles that are being joined together to create the
childchild
- the FlowFile that is being created by joining the parentsdetails
- any details pertinent to the eventjoinDuration
- the number of milliseconds that it took to join the
FlowFilespublic void clone(FlowFile parent, FlowFile child)
ProvenanceReporter
CLONE
that establishes that the given child is an exact replica of the parent.
In general, this method does not need to be called by Processors, as the
ProcessSession
will handle this automatically for you when
calling ProcessSession.clone(FlowFile)
clone
in interface ProvenanceReporter
parent
- the FlowFile that was clonedchild
- the clonepublic void modifyContent(FlowFile flowFile)
ProvenanceReporter
CONTENT_MODIFIED
that
indicates that the content of the given FlowFile has been modified. One
of the modifyContent
methods should be called any time that
the contents of a FlowFile are modified.modifyContent
in interface ProvenanceReporter
flowFile
- the FlowFile whose content is being modifiedpublic void modifyContent(FlowFile flowFile, java.lang.String details)
ProvenanceReporter
CONTENT_MODIFIED
that
indicates that the content of the given FlowFile has been modified. One
of the modifyContent
methods should be called any time that
the contents of a FlowFile are modified.modifyContent
in interface ProvenanceReporter
flowFile
- the FlowFile whose content is being modifieddetails
- Any details about how the content of the FlowFile has been
modified. Details should not be specified if they can be inferred by
other information in the event, such as the name of the Processor, as
specifying this information will add undue overheadpublic void modifyContent(FlowFile flowFile, long processingMillis)
ProvenanceReporter
CONTENT_MODIFIED
that
indicates that the content of the given FlowFile has been modified. One
of the modifyContent
methods should be called any time that
the contents of a FlowFile are modified.modifyContent
in interface ProvenanceReporter
flowFile
- the FlowFile whose content is being modifiedprocessingMillis
- the number of milliseconds spent processing the
FlowFilepublic void modifyContent(FlowFile flowFile, java.lang.String details, long processingMillis)
ProvenanceReporter
CONTENT_MODIFIED
that
indicates that the content of the given FlowFile has been modified. One
of the modifyContent
methods should be called any time that
the contents of a FlowFile are modified.modifyContent
in interface ProvenanceReporter
flowFile
- the FlowFile whose content is being modifieddetails
- Any details about how the content of the FlowFile has been
modified. Details should not be specified if they can be inferred by
other information in the event, such as the name of the Processor, as
specifying this information will add undue overheadprocessingMillis
- the number of milliseconds spent processing the
FlowFilepublic void modifyAttributes(FlowFile flowFile)
ProvenanceReporter
ATTRIBUTES_MODIFIED
that
indicates that the Attributes of the given FlowFile were updated. It is
not necessary to emit such an event for a FlowFile if other Events are
already emitted by a Processor. For example, one should call both
ProvenanceReporter.modifyContent(FlowFile)
and ProvenanceReporter.modifyAttributes(FlowFile)
for the same FlowFile in the same Processor. Rather, the Processor should
call just the ProvenanceReporter.modifyContent(FlowFile)
, as the call to
ProvenanceReporter.modifyContent(FlowFile)
will generate a Provenance Event that
already contains all FlowFile attributes. As such, emitting another event
that contains those attributes is unneeded and can result in a
significant amount of overhead for storage and processing.modifyAttributes
in interface ProvenanceReporter
flowFile
- the FlowFile whose attributes were modifiedpublic void modifyAttributes(FlowFile flowFile, java.lang.String details)
ProvenanceReporter
ATTRIBUTES_MODIFIED
that
indicates that the Attributes of the given FlowFile were updated. It is
not necessary to emit such an event for a FlowFile if other Events are
already emitted by a Processor. For example, one should call both
ProvenanceReporter.modifyContent(FlowFile)
and ProvenanceReporter.modifyAttributes(FlowFile)
for the same FlowFile in the same Processor. Rather, the Processor should
call just the ProvenanceReporter.modifyContent(FlowFile)
, as the call to
ProvenanceReporter.modifyContent(FlowFile)
will generate a Provenance Event that
already contains all FlowFile attributes. As such, emitting another event
that contains those attributes is unneeded and can result in a
significant amount of overhead for storage and processing.modifyAttributes
in interface ProvenanceReporter
flowFile
- the FlowFile whose attributes were modifieddetails
- any details should be provided about the attribute
modificationpublic void route(FlowFile flowFile, Relationship relationship)
ProvenanceReporter
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship
. Note: this Event is intended for Processors
whose sole job it is to route FlowFiles and should NOT be used as a way
to indicate that the given FlowFile was routed to a standard 'success' or
'failure' relationship. Doing so can be problematic, as DataFlow Managers
often will loop 'failure' relationships back to the same processor. As
such, emitting a Route event to indicate that a FlowFile was routed to
'failure' can result in creating thousands of Provenance Events for a
given FlowFile, resulting in a very difficult-to- understand lineage.route
in interface ProvenanceReporter
flowFile
- the FlowFile being routedrelationship
- the Relationship to which the FlowFile was routedpublic void route(FlowFile flowFile, Relationship relationship, long processingDuration)
ProvenanceReporter
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship
. Note: this Event is intended ONLY for
Processors whose sole job it is to route FlowFiles and should NOT be used
as a way to indicate that hte given FlowFile was routed to a standard
'success' or 'failure' relationship. Doing so can be problematic, as
DataFlow Managers often will loop 'failure' relationships back to the
same processor. As such, emitting a Route event to indicate that a
FlowFile was routed to 'failure' can result in creating thousands of
Provenance Events for a given FlowFile, resulting in a very difficult-to-
understand lineage.route
in interface ProvenanceReporter
flowFile
- the FlowFile being routedrelationship
- the Relationship to which the FlowFile was routedprocessingDuration
- the number of milliseconds that it took to
determine how to route the FlowFilepublic void route(FlowFile flowFile, Relationship relationship, java.lang.String details)
ProvenanceReporter
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship
. Note: this Event is intended ONLY for
Processors whose sole job it is to route FlowFiles and should NOT be used
as a way to indicate that hte given FlowFile was routed to a standard
'success' or 'failure' relationship. Doing so can be problematic, as
DataFlow Managers often will loop 'failure' relationships back to the
same processor. As such, emitting a Route event to indicate that a
FlowFile was routed to 'failure' can result in creating thousands of
Provenance Events for a given FlowFile, resulting in a very difficult-to-
understand lineage.route
in interface ProvenanceReporter
flowFile
- the FlowFile being routedrelationship
- the Relationship to which the FlowFile was routeddetails
- any details pertinent to the Route event, such as why the
FlowFile was routed to the specified Relationshippublic void route(FlowFile flowFile, Relationship relationship, java.lang.String details, long processingDuration)
ProvenanceReporter
ROUTE
that indicates that the given FlowFile was routed to the given
Relationship
. Note: this Event is intended ONLY for
Processors whose sole job it is to route FlowFiles and should NOT be used
as a way to indicate that hte given FlowFile was routed to a standard
'success' or 'failure' relationship. Doing so can be problematic, as
DataFlow Managers often will loop 'failure' relationships back to the
same processor. As such, emitting a Route event to indicate that a
FlowFile was routed to 'failure' can result in creating thousands of
Provenance Events for a given FlowFile, resulting in a very difficult-to-
understand lineage.route
in interface ProvenanceReporter
flowFile
- the FlowFile being routedrelationship
- the Relationship to which the FlowFile was routeddetails
- any details pertinent to the Route event, such as why the
FlowFile was routed to the specified RelationshipprocessingDuration
- the number of milliseconds that it took to
determine how to route the FlowFilepublic void create(FlowFile flowFile)
ProvenanceReporter
CREATE
that indicates that the given
FlowFile was created by NiFi from data that was not received from an
external entity. If the data was received from an external source, use
the ProvenanceReporter.receive(FlowFile, String)
event insteadcreate
in interface ProvenanceReporter
flowFile
- the FlowFile that was createdpublic void create(FlowFile flowFile, java.lang.String details)
ProvenanceReporter
CREATE
that indicates that the given
FlowFile was created by NiFi from data that was not received from an
external entity. If the data was received from an external source, use
the ProvenanceReporter.receive(FlowFile, String, String, long)
event insteadcreate
in interface ProvenanceReporter
flowFile
- the FlowFile that was createddetails
- any relevant details about the CREATE event