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 | Description | Default |
---|---|---|
Server Mode | Select this check box to have the adapter operate in server mode, listening for and accepting incoming connections from remote clients. | cleared |
Max Connection Count | The maximum number of simultaneous connections the adapter accepts when in server mode. | false |
Host Name | The host or IP address to connect to when not in server mode. | localhost |
Port | The TCP port to connect to or, when in server mode, to listen on. | 9000 |
Use Default Charset | 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. | Selected |
Character Set | The name of the character set encoding that the adapter is to use to read input or write output. | None |
Capture Transform Strategy | The strategy to use when transforming capture fields for this operator: FLATTEN or NEST. | FLATTEN |
Field Delimiter | The delimiter used to separate tokens. | , |
String Quote Character | Matching pairs of the quote character used to delimit string constants. | " |
Flush Interval | How often, in seconds, controls flushing tuples to the network. Set this value to zero to flush immediately. | 1 |
Null Value Representation | String to write when a field is null. | null |
Throttle Error Messages | Only show a given error message once. | false |
String Quote Option | Determines when string fields are quoted in the CSV file: Quote if necessary, Always quote, or Never quote. | Quote if necessary |
Reconnect Count | The number of times the adapter should try to reconnect to the socket when not in server mode. 0 means attempt to reconnect indefinitely. | 0 |
Poll Frequency | The time, in seconds, to wait between reconnect attempts. | 5 |
Log Level | Controls the level of verbosity the adapter uses to send notifications to the console. This setting can be higher than the containing application's log level. If set lower, the system log level will be used. Available values, in increasing order of verbosity, are: OFF, ERROR, WARN, INFO, DEBUG, TRACE, and ALL. | INFO |
Connection Target Enabled | 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. | cleared |
Connection Target Enabled | 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. | cleared |
Remote Hostname Identifier Field Name | The name of the field used to identify the host of the conection 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.