@EventDriven @SideEffectFree @SupportsBatching @Tags(value={"attributes","logging"}) @InputRequirement(value=INPUT_REQUIRED) @CapabilityDescription(value="Emits attributes of the FlowFile at the specified log level") public class LogAttribute extends AbstractProcessor
Modifier and Type | Class and Description |
---|---|
static class |
LogAttribute.DebugLevels |
protected static class |
LogAttribute.FlowFilePayloadCallback |
Modifier and Type | Field and Description |
---|---|
static PropertyDescriptor |
ATTRIBUTES_TO_IGNORE_CSV |
static PropertyDescriptor |
ATTRIBUTES_TO_IGNORE_REGEX |
static PropertyDescriptor |
ATTRIBUTES_TO_LOG_CSV |
static PropertyDescriptor |
ATTRIBUTES_TO_LOG_REGEX |
static PropertyDescriptor |
CHARSET |
static String |
FIFTY_DASHES |
static PropertyDescriptor |
LOG_LEVEL |
static PropertyDescriptor |
LOG_PAYLOAD |
static PropertyDescriptor |
LOG_PREFIX |
static long |
ONE_MB |
static Relationship |
REL_SUCCESS |
private Set<Relationship> |
relationships |
private List<PropertyDescriptor> |
supportedDescriptors |
Constructor and Description |
---|
LogAttribute() |
Modifier and Type | Method and Description |
---|---|
private Set<String> |
getAttributesToLog(Set<String> flowFileAttrKeys,
ProcessContext context) |
Set<Relationship> |
getRelationships() |
protected List<PropertyDescriptor> |
getSupportedPropertyDescriptors() |
protected void |
init(ProcessorInitializationContext context) |
void |
onTrigger(ProcessContext context,
ProcessSession session) |
protected String |
processFlowFile(ComponentLog logger,
LogAttribute.DebugLevels logLevel,
FlowFile flowFile,
ProcessSession session,
ProcessContext context) |
private void |
transferChunk(ProcessSession session) |
onTrigger
getControllerServiceLookup, getIdentifier, getLogger, getNodeTypeProvider, initialize, isConfigurationRestored, isScheduled, toString, updateConfiguredRestoredTrue, updateScheduledFalse, updateScheduledTrue
customValidate, equals, getPropertyDescriptor, getPropertyDescriptors, getSupportedDynamicPropertyDescriptor, hashCode, onPropertyModified, validate
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getPropertyDescriptor, getPropertyDescriptors, onPropertyModified, validate
public static final PropertyDescriptor LOG_LEVEL
public static final PropertyDescriptor ATTRIBUTES_TO_LOG_CSV
public static final PropertyDescriptor ATTRIBUTES_TO_LOG_REGEX
public static final PropertyDescriptor ATTRIBUTES_TO_IGNORE_CSV
public static final PropertyDescriptor ATTRIBUTES_TO_IGNORE_REGEX
public static final PropertyDescriptor LOG_PAYLOAD
public static final PropertyDescriptor LOG_PREFIX
public static final PropertyDescriptor CHARSET
public static final String FIFTY_DASHES
public static final long ONE_MB
private Set<Relationship> relationships
private List<PropertyDescriptor> supportedDescriptors
public static final Relationship REL_SUCCESS
protected void init(ProcessorInitializationContext context)
init
in class AbstractSessionFactoryProcessor
public Set<Relationship> getRelationships()
getRelationships
in interface Processor
getRelationships
in class AbstractSessionFactoryProcessor
protected List<PropertyDescriptor> getSupportedPropertyDescriptors()
getSupportedPropertyDescriptors
in class AbstractConfigurableComponent
protected String processFlowFile(ComponentLog logger, LogAttribute.DebugLevels logLevel, FlowFile flowFile, ProcessSession session, ProcessContext context)
private Set<String> getAttributesToLog(Set<String> flowFileAttrKeys, ProcessContext context)
private void transferChunk(ProcessSession session)
public void onTrigger(ProcessContext context, ProcessSession session)
onTrigger
in class AbstractProcessor
Copyright © 2021 Apache NiFi Project. All rights reserved.