@EventDriven @SupportsBatching @InputRequirement(value=INPUT_REQUIRED) @SideEffectFree @Tags(value={"split","generic","schema","json","csv","avro","log","logs","freeform","text"}) @WritesAttribute(attribute="mime.type",description="Sets the mime.type attribute to the MIME Type specified by the Record Writer for the FlowFiles routed to the \'splits\' Relationship.") @WritesAttribute(attribute="record.count",description="The number of records in the FlowFile. This is added to FlowFiles that are routed to the \'splits\' Relationship.") @WritesAttribute(attribute="fragment.identifier",description="All split FlowFiles produced from the same parent FlowFile will have the same randomly generated UUID added for this attribute") @WritesAttribute(attribute="fragment.index",description="A one-up number that indicates the ordering of the split FlowFiles that were created from a single parent FlowFile") @WritesAttribute(attribute="fragment.count",description="The number of split FlowFiles generated from the parent FlowFile") @WritesAttribute(attribute="segment.original.filename ",description="The filename of the parent FlowFile") @CapabilityDescription(value="Splits up an input FlowFile that is in a record-oriented data format into multiple smaller FlowFiles") public class SplitRecord extends AbstractProcessor
| Modifier and Type | Field and Description |
|---|---|
static String |
FRAGMENT_COUNT |
static String |
FRAGMENT_ID |
static String |
FRAGMENT_INDEX |
(package private) static PropertyDescriptor |
RECORD_READER |
(package private) static PropertyDescriptor |
RECORD_WRITER |
(package private) static PropertyDescriptor |
RECORDS_PER_SPLIT |
(package private) static Relationship |
REL_FAILURE |
(package private) static Relationship |
REL_ORIGINAL |
(package private) static Relationship |
REL_SPLITS |
static String |
SEGMENT_ORIGINAL_FILENAME |
| Constructor and Description |
|---|
SplitRecord() |
| Modifier and Type | Method and Description |
|---|---|
Set<Relationship> |
getRelationships() |
protected List<PropertyDescriptor> |
getSupportedPropertyDescriptors() |
void |
onTrigger(ProcessContext context,
ProcessSession session) |
onTriggergetControllerServiceLookup, getIdentifier, getLogger, getNodeTypeProvider, init, initialize, isConfigurationRestored, isScheduled, toString, updateConfiguredRestoredTrue, updateScheduledFalse, updateScheduledTruecustomValidate, equals, getPropertyDescriptor, getPropertyDescriptors, getSupportedDynamicPropertyDescriptor, hashCode, onPropertyModified, validateclone, finalize, getClass, notify, notifyAll, wait, wait, waitisStatefulgetPropertyDescriptor, getPropertyDescriptors, onPropertyModified, validatepublic static final String FRAGMENT_ID
public static final String FRAGMENT_INDEX
public static final String FRAGMENT_COUNT
public static final String SEGMENT_ORIGINAL_FILENAME
static final PropertyDescriptor RECORD_READER
static final PropertyDescriptor RECORD_WRITER
static final PropertyDescriptor RECORDS_PER_SPLIT
static final Relationship REL_SPLITS
static final Relationship REL_ORIGINAL
static final Relationship REL_FAILURE
protected List<PropertyDescriptor> getSupportedPropertyDescriptors()
getSupportedPropertyDescriptors in class AbstractConfigurableComponentpublic Set<Relationship> getRelationships()
getRelationships in interface ProcessorgetRelationships in class AbstractSessionFactoryProcessorpublic void onTrigger(ProcessContext context, ProcessSession session) throws ProcessException
onTrigger in class AbstractProcessorProcessExceptionCopyright © 2023 Apache NiFi Project. All rights reserved.