The TIBCO StreamBase® CSV Socket Writer is an embedded adapter that writes comma-separated value (CSV) data to a socket. It closely resembles the CSV File Writer adapter. Unlike the CSV File Writer adapter, though, this socket adapter writes output data to a TCP socket connected to a specified external address.
Property | Default | Description |
---|---|---|
Server Mode | cleared | Select this check box to have the adapter operate in server mode, listening for and accepting incoming connections from remote clients. |
Max Connection Count | false | The maximum number of simultaneous connections the adapter accepts when in server mode. |
Host Name | localhost | The host or IP address to connect to when not in server mode. |
Port | 9000 | The TCP port to connect to or, when in server mode, to listen on. |
Use Default Charset | Selected | If selected, specifies whether the Java platform default character set is to be used. If cleared, a valid character set name must be specified for the Character Set property. |
Character Set | None | The name of the character set encoding that the adapter is to use to read input or write output. |
Capture Transform Strategy | FLATTEN | The strategy to use when transforming capture fields for this operator: FLATTEN or NEST. |
Field Delimiter | , | The delimiter used to separate tokens. |
String Quote Character | " | Matching pairs of the quote character used to delimit string constants. |
Flush Interval | 1 | How often, in seconds, controls flushing tuples to the network. Set this value to zero to flush immediately. |
Null Value Representation | null | String to write when a field is null. |
Throttle Error Messages | false | Only show a given error message once. |
String Quote Option | Quote if necessary | Determines when string fields are quoted in the CSV file: Quote if necessary, Always quote, or Never quote. |
Reconnect Count | 0 | The number of times the adapter should try to reconnect to the socket when not in server mode. 0 means attempt to reconnect indefinitely. |
Poll Frequency | 5 | The time, in seconds, to wait between reconnect attempts. |
Log Level | INFO | Controls the level of verbosity the adapter uses to issue informational traces to the console. This setting is independent of the containing application's overall log level. Available values, in increasing order of verbosity, are: OFF, ERROR, WARN, INFO, DEBUG, TRACE. |
Connection Target Enabled | cleared | Checking this box enables the use of the following two properties when in server mode. Unchecked, the CSV Socket Writer will behave as normal, and every tuple written will be written out on all existing connections.Checking this box will allow the adapter to identify which unique connection to write data to, based on two fields in the incoming tuple. |
Connection Target Enabled | cleared | Checking this box enables the use of the following two properties when in server mode. Unchecked, the CSV Socket Writer will behave as normal, and every tuple written will be written out on all existing connections.Checking this box will allow the adapter to identify which unique connection to write data to, based on two fields in the incoming tuple. |
Remote Hostname Identifier Field Name | The name of the field used to identify the host of the connection to which you will exclusively send data to, when in server mode. Instead of broadcasting to all current connection, targeting will cause only a certain connection to receive the data from the current tuple. This is determined by two fields in the incoming tuple, whose names are specified by this property and by the 'Remote Port Identifier Field Name' property. If this property is left blank it will be ignored and data will be sent to all connections. | |
Remote Port Identifier Field Name | The name of the field used to identify the port of the connection to which you will exclusively send data to, when in server mode. Instead of broadcasting to all current connections, targeting will cause only a certain connection to receive the data from the current tuple. This is determined by two fields in the incoming tuple, whose names are specified by this property and by the 'Remote Hostname Identifier Field Name' property. If this property is left blank it will be ignored and data will be sent to all connections. |
Typechecking fails in the following circumstances:
-
The Flush Interval is less than zero.
-
More than one string quote character is specified.
-
More than one field delimiter is specified.
-
An illegal string quote option is specified.
-
The Poll Frequency is less than zero.
-
If the adapter is unable to connect to the socket, it emits a warning and attempts to reconnect as per the Reconnect Count property. If it is unable to connect after the configured number of retries, it emits a warning and shuts down.