Adapter type: toolkit_socket_json_input. Set these properties for the Socket JSON Input adapter in the ESP Studio adapter properties dialog. The Socket JSON Input adapter uses SimpleDateFormat formatting codes.
If you use the CCL ATTACH ADAPTER statement to attach an adapter, you must supply the adapter type.
Property Label | Description |
---|---|
JSON Column Mapping List |
Property ID: jsonColsMappingList Type: string (Required) Specify JSONPath expressions which represent JSON data to map to ESP streams. Separate these values using commas. There are two types of JSON data: array or object. For example, if you had the following JSON data about a
person,
{ "firstName": "John", "lastName": "Smith", "phoneNumbers": [ { "type": "home", "number": "212 555-1234" }, { "type": "fax", "number": "646 555-4567" } ], "friends": [ ["female1","female2","female3"], ["male1","male2","male3"] ] } If you want the numbers and types of phone numbers, specify phoneNumbers as the jsonRootpath value and numbers and type as the JSONPath expressions in the jsonColsMappingList property. You can also specify * for jsonColsMappingList which indicates you want all the data in an array (that does not have key value data within it). For example, if you wanted all the female friends data, specify friends[1] for jsonRootpath and * for jsonColsMappingList. The first JSONPath expression is mapped to the first column of a stream, the second expression is mapped to the second column of a stream, and so on. |
JSON Root Path |
Property ID: jsonRootpath Type: string (Optional) Specify a root path for the JSON data. This must be an array. See examples in the jsonColsMappingList property description above. |
SecondDate Format |
Property ID: jsonSecondDateFormat Type: string (Advanced) Specify the format for parsing SecondDate values. For example, yyyy-MM-dd'T'HH:mm:ss is the default value. |
MsDate Format |
Property ID: jsonMsDateFormat Type: string (Advanced) Specify the format for parsing MsDate values. For example, yyyy-MM-dd'T'HH:mm:ss.SSS is the default value. |
Time Format |
Property ID: jsonTimeFormat Type: string (Advanced) Specify the format for parsing time values. For example, HH:mm:ss is the default value. |
Server |
Property ID: host Type: string (Required) Server host name. |
Port |
Property ID: port Type: int (Required) Server port. To read from the Ephemeral Port File, set to -1. |
Ephemeral Port File |
Property ID: epFile Type: filename (Advanced) File that will contain the server port number if Port is -1. If sandboxing is enabled, this file must reside in the <sandbox-base-directory>/adapters/<workspace-name> or $STREAMING_HOME/adapters/framework directory or one of their subdirectories. If the file is in a different location, the adapter will not be able to successfully connect to Event Stream Processor. |
Retry Period (seconds) |
Property ID: retryperiod Type: uint (Advanced) Period for trying to re-establish an outgoing connection. |
Buffer Size |
Property ID: inputBufferSize Type: uint (Advanced) The buffer size of the socket connection (bytes). |
Enable TCP keepalive |
Property ID: keepAlive Type: boolean (Advanced) Enable TCP keepalive on the socket connection. |
PropertySet |
Property ID: propertyset Type: string (Advanced) Specifies the name of the property set. Property sets are reusable sets of properties that are stored in the project configuration file. Using these sets allows you to move adapter configuration properties out of the CCL file and into the CCR file. If you specify the same properties in the project configuration file and the ATTACH ADAPTER statement, the values in the property set override the values defined in the ATTACH ADAPTER statement. No default value. |