@InputRequirement(value=INPUT_FORBIDDEN) @Tags(value={"listen","beats","tcp","logs"}) @CapabilityDescription(value="Listens for messages sent by libbeat compatible clients (e.g. filebeats, metricbeats, etc) using Libbeat\'s \'output.logstash\', writing its JSON formatted payload to the content of a FlowFile.This processor replaces the now deprecated ListenLumberjack") @WritesAttribute(attribute="beats.sender",description="The sending host of the messages.") @WritesAttribute(attribute="beats.port",description="The sending port the messages were received over.") @WritesAttribute(attribute="beats.sequencenumber",description="The sequence number of the message. Only included if <Batch Size> is 1.") @WritesAttribute(attribute="mime.type",description="The mime.type of the content which is application/json") @SeeAlso(classNames="org.apache.nifi.processors.standard.ParseSyslog") public class ListenBeats extends AbstractListenEventBatchingProcessor<BeatsEvent>
| Modifier and Type | Class and Description |
|---|---|
static class |
ListenBeats.beatsAttributes |
AbstractListenEventBatchingProcessor.FlowFileEventBatch| Modifier and Type | Field and Description |
|---|---|
private BeatsEncoder |
beatsEncoder |
static PropertyDescriptor |
CLIENT_AUTH |
static PropertyDescriptor |
SSL_CONTEXT_SERVICE |
messageDemarcatorBytescharset, CHARSET, descriptors, dispatcher, errorEvents, events, MAX_CONNECTIONS, MAX_MESSAGE_QUEUE_SIZE, MAX_SOCKET_BUFFER_SIZE, POLL_TIMEOUT_MS, port, PORT, RECV_BUFFER_SIZE, REL_SUCCESS, relationships| Constructor and Description |
|---|
ListenBeats() |
| Modifier and Type | Method and Description |
|---|---|
protected ChannelDispatcher |
createDispatcher(ProcessContext context,
BlockingQueue<BeatsEvent> events) |
protected Collection<ValidationResult> |
customValidate(ValidationContext validationContext) |
protected List<PropertyDescriptor> |
getAdditionalProperties() |
protected Map<String,String> |
getAttributes(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch) |
protected String |
getBatchKey(BeatsEvent event) |
protected String |
getTransitUri(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch) |
void |
onScheduled(ProcessContext context) |
protected void |
postProcess(ProcessContext context,
ProcessSession session,
List<BeatsEvent> events) |
protected void |
respond(BeatsEvent event,
BeatsResponse beatsResponse) |
getBatches, init, onTriggercloseDispatcher, getAdditionalRelationships, getDispatcherPort, getErrorQueueSize, getLongPollTimeout, getMessage, getQueueSize, getRelationships, getSupportedPropertyDescriptorsonTriggergetControllerServiceLookup, getIdentifier, getLogger, getNodeTypeProvider, initialize, isConfigurationRestored, isScheduled, toString, updateConfiguredRestoredTrue, updateScheduledFalse, updateScheduledTrueequals, getPropertyDescriptor, getPropertyDescriptors, getSupportedDynamicPropertyDescriptor, hashCode, onPropertyModified, validateclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetPropertyDescriptor, getPropertyDescriptors, onPropertyModified, validatepublic static final PropertyDescriptor SSL_CONTEXT_SERVICE
public static final PropertyDescriptor CLIENT_AUTH
private volatile BeatsEncoder beatsEncoder
protected List<PropertyDescriptor> getAdditionalProperties()
getAdditionalProperties in class AbstractListenEventProcessor<BeatsEvent>protected Collection<ValidationResult> customValidate(ValidationContext validationContext)
customValidate in class AbstractConfigurableComponent@OnScheduled public void onScheduled(ProcessContext context) throws IOException
onScheduled in class AbstractListenEventBatchingProcessor<BeatsEvent>IOExceptionprotected ChannelDispatcher createDispatcher(ProcessContext context, BlockingQueue<BeatsEvent> events) throws IOException
createDispatcher in class AbstractListenEventProcessor<BeatsEvent>IOExceptionprotected String getBatchKey(BeatsEvent event)
getBatchKey in class AbstractListenEventBatchingProcessor<BeatsEvent>protected void respond(BeatsEvent event, BeatsResponse beatsResponse)
protected void postProcess(ProcessContext context, ProcessSession session, List<BeatsEvent> events)
postProcess in class AbstractListenEventBatchingProcessor<BeatsEvent>protected String getTransitUri(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch)
getTransitUri in class AbstractListenEventBatchingProcessor<BeatsEvent>protected Map<String,String> getAttributes(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch)
getAttributes in class AbstractListenEventBatchingProcessor<BeatsEvent>Copyright © 2021 Apache NiFi Project. All rights reserved.