Key Capabilities
- Generic TCP/IP server endpoint with TLS/SSL and plain text support for arbitrary data streams
- Configurable message delimitation using static delimiters or length-based parsing
- Bidirectional communication with Connection ID-based routing and connection event messaging
Overview
Each TCP Server connector listens on a specified port for incoming TCP traffic, either with TLS/SSL encryption or plain text. Use this connector when needs to receive arbitrary data that does not necessarily fit into the constraints provided by other standard protocols. Since TCP traffic is a constant stream that does not intrinsically have a start or end point, you must configure the connector to determine where one message ends and the next begins. The connector supports two approaches:- A static string/character delimiter that ends the current message or begins the next message
- Reading a value in the incoming TCP data to determine how long the message should be
Connector Settings
Settings Tab
Configuration
Settings related to the core configuration of the connector.| Setting | Description |
|---|---|
| Connector Id | The static, unique identifier for the connector. |
| Connector Type | Displays the connector name and a description of what it does. |
| Connector Description | An optional field to provide a free-form description of the connector and its role in the flow. |
| Port | The port on which to listen for incoming TCP connections. |
Message Decoding
Settings related to distinguishing individual messages from the TCP stream.| Setting | Description |
|---|---|
| Message Start Delimiter | The single character or hexadecimal value (prefixed by 0x) indicating the start of a new message. |
| Message End Delimiter | The single character or hexadecimal value (prefixed by 0x) indicating the end of the current message. |
| Message Length Offset | The number of bytes to skip before beginning to read the length of the message from the incoming data. |
| Message Length Size | The size in bytes of the length value in the incoming data. |
TLS Settings
Settings related to TLS/SSL transport security.| Setting | Description |
|---|---|
| Enable TLS | Whether clients must negotiate TLS/SSL encryption to connect to the TCP server. |
| Server Certificate | The TLS/SSL certificate that identifies the TCP server. |
| Certificate Password | The password to access the server certificate’s private key. |
Advanced Tab
Keep Alive
Settings related to keep-alive packets sent by the server to maintain an idle connection.| Setting | Description |
|---|---|
| Keep Alive | Whether to send keep-alive packets periodically to ensure that idle connections are not closed due to inactivity. |
| Keep Alive Time | The length of inactivity that should elapse before sending the first keep-alive packet. |
| Keep Alive Interval | The interval between consecutive keep-alive packets. |
Advanced Settings
Settings not included in the previous categories.| Setting | Description |
|---|---|
| Connected Messages | Whether the connector should generate an message when a client connects. See the Connected and Disconnected Messages section for more information. |
| Disconnected Messages | Whether the connector should generate an message when a client disconnects. See the Connected and Disconnected Messages section for more information. |
| Idle Timeout | The length of time (in seconds) the server should wait for an idle client before disconnecting them due to inactivity. |
| Local File Scheme | A scheme for assigning filenames to messages that are output by the connector. You can use macros in your filenames dynamically to include information such as identifiers and timestamps. For more information, see Macros. |
| Local Host | The binding address of the local server, if not the default network interface. |
| Max Connections | The maximum number of concurrent connectors. |
| TLS Enabled Protocols | The list of TLS/SSL protocols supported when establishing outgoing connections. Best practice is to only use TLS protocols. SSL v2 and SSL v3 are considered vulnerable and should only be used if your partner does not support higher versions. Keep in mind that TLS v1.3 is not universally adopted, and might be refused if the destination server does not support it. |
Message
Logging
Miscellaneous
Server Tab
Trusted IP Addresses
Automation Tab
Automation
Settings related to the automatic processing of files by the connector.| Setting | Description |
|---|---|
| Send | Whether messages arriving at the connector are automatically processed. |
Performance
Alerts Tab
SLAs Tab
Connected and Disconnected Messages
By default, the TCP Server connector only generates messages when clients transfer data that the connector recognizes as a full message (according to the settings in the Message Decoding section). The connector can also generate messages when a client connects to the server (if Connected Messages is enabled on the Advanced tab) or disconnects from the server (if Disconnected Messages is enabled on the Advanced tab). When these special messages are generated, a special header is added to the message:x-tcpserver-event
This header is set to the value connected when clients are connecting, and disconnected when clients are disconnecting.
This header value must be checked by later connectors in the flow to detect whether a message written to the output folder of a TCP Server connector is one of these special messages.
Sending Messages
The TCP Server connector also uses a special header value to send messages back to connected clients:x-tcpserver-connectionid
This header is added to any output messages generated by the connector, and is set to a Connection ID value that uniquely identifies the connected client. Messages that should be sent back to this client must have this header set to the same value to ensure that the message is sent to the appropriate client.
Since this header is already present on any messages written out by the connector, if the message passes through an flow and arrives back at the Transactions for the TCP Server connector, it still has the same Connection ID value and is returned to the client that sent the original message. If the message cannot be directly routed back to the TCP Server connector, the Connection ID value must be saved and applied as a header (with the name shown above) to any new messages that should be returned to the client.