@SupportsBatching @InputRequirement(value=INPUT_FORBIDDEN) @Tags(value={"listen","tcp","tls","ssl"}) @CapabilityDescription(value="Listens for incoming TCP connections and reads data from each connection using a line separator as the message demarcator. The default behavior is for each message to produce a single FlowFile, however this can be controlled by increasing the Batch Size to a larger value for higher throughput. The Receive Buffer Size must be set as large as the largest messages expected to be received, meaning if every 100kb there is a line separator, then the Receive Buffer Size must be greater than 100kb.") @WritesAttribute(attribute="tcp.sender",description="The sending host of the messages.") @WritesAttribute(attribute="tcp.port",description="The sending port the messages were received.") public class ListenTCP extends AbstractListenEventBatchingProcessor<StandardEvent>
AbstractListenEventBatchingProcessor.FlowFileEventBatch
Modifier and Type | Field and Description |
---|---|
static PropertyDescriptor |
CLIENT_AUTH |
static PropertyDescriptor |
SSL_CONTEXT_SERVICE |
MAX_BATCH_SIZE, MESSAGE_DELIMITER, messageDemarcatorBytes
charset, 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 |
---|
ListenTCP() |
Modifier and Type | Method and Description |
---|---|
protected ChannelDispatcher |
createDispatcher(ProcessContext context,
BlockingQueue<StandardEvent> events) |
protected Collection<ValidationResult> |
customValidate(ValidationContext validationContext) |
protected List<PropertyDescriptor> |
getAdditionalProperties() |
protected Map<String,String> |
getAttributes(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch) |
protected String |
getTransitUri(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch) |
getBatches, getBatchKey, init, onScheduled, onTrigger, postProcess
createBufferPool, getAdditionalRelationships, getDispatcherPort, getErrorQueueSize, getLongPollTimeout, getMessage, getQueueSize, getRelationships, getSupportedPropertyDescriptors, onUnscheduled
onTrigger
getControllerServiceLookup, getIdentifier, getLogger, getNodeTypeProvider, initialize, isConfigurationRestored, isScheduled, toString, updateConfiguredRestoredTrue, updateScheduledFalse, updateScheduledTrue
equals, getPropertyDescriptor, getPropertyDescriptors, getSupportedDynamicPropertyDescriptor, hashCode, onPropertyModified, validate
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getPropertyDescriptor, getPropertyDescriptors, onPropertyModified, validate
public static final PropertyDescriptor SSL_CONTEXT_SERVICE
public static final PropertyDescriptor CLIENT_AUTH
protected List<PropertyDescriptor> getAdditionalProperties()
getAdditionalProperties
in class AbstractListenEventProcessor<StandardEvent>
protected Collection<ValidationResult> customValidate(ValidationContext validationContext)
customValidate
in class AbstractConfigurableComponent
protected ChannelDispatcher createDispatcher(ProcessContext context, BlockingQueue<StandardEvent> events) throws IOException
createDispatcher
in class AbstractListenEventProcessor<StandardEvent>
IOException
protected Map<String,String> getAttributes(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch)
getAttributes
in class AbstractListenEventBatchingProcessor<StandardEvent>
protected String getTransitUri(AbstractListenEventBatchingProcessor.FlowFileEventBatch batch)
getTransitUri
in class AbstractListenEventBatchingProcessor<StandardEvent>
Copyright © 2020 Apache NiFi Project. All rights reserved.