Configuring the Web Socket transport
The Web Socket transport allows the probe to connect to the target device to send the following types of HTTP requests:
loginRequest
: This is sent after the OAuth access token request to log into the target system.loginRefresh
This is sent periodically to refresh the login on the target device.logoutRequest
This is sent before disconnecting from the target device.resynchRequest
This is sent to request an event resynchronization with the target device.subscribeRequest
This is sent to subscribe to received events from the target device as they are created.subscribeRefresh
This is sent periodically to refresh the event subscription on the target device.
Web Socket transport properties
The following table describes the properties in the restWebSocketTransport.properties file. The restWebSocketTransport.properties file controls the integration with the Message Bus Probe using Web Socket.
Property name |
Description |
---|---|
httpVersion |
Use this property to specify the version of the HTTP protocol that the target system supports. The default is 1.1. |
httpHeaders |
Use this property to specify the HTTP header
options to use in all HTTP requests. This property accepts a comma
separated list of key-value pairs using the equals sign ( For options that accept multiple values,
use the double-quote (") character around the value and a use semi-colon
(;) as the value separator; for example: For the authorization
header option, the credentials that follow the single whitespace after The default value is "". Note: The httpHeaders property
sets the headers for all HTTP requests. However, you can override
these global HTTP header options using the following properties:
|
responseTimeout |
Use this property to specify how long (in seconds) the probe waits for a response from the target system before timing out. The default is 60 seconds. |
loginRequestURI |
Use this property to specify the URI that the probe uses to request a login. |
loginRequestMethod |
Use this property to specify the message type that the probe sends to request a login. |
loginRequestContent |
Use this property to specify any additional information that the probe sends with the login request. |
loginRequestHeaders |
Use this property to specify an HTTP header to send with all login requests. This overrides the global HTTP header options configured by the httpHeader property. |
loginRefreshURI |
Use this property to specify the URI that the probe uses to refresh the login on the target device. |
loginRefreshMethod |
Use this property to specify the message type that the probe sends to refresh the login on the target device. |
loginRefreshContent |
Use this property to specify any additional information that the probe sends with the login refresh request. |
loginRefreshHeaders |
Use this property to specify an HTTP header to send with all login refresh requests. This overrides the global HTTP header options configured by the httpHeader property. |
loginRefreshInterval |
Use this property to specify the interval (in seconds) that the probe leaves between successive login refresh requests. This can be disabled by setting it to "" or leaving it commented out. If set to a negative value or an valid value such as String, it will default to 60 seconds. |
logoutRequestURI |
Use this property to specify the URI that the probe uses to request a logout from the target device. |
logoutRequestMethod |
Use this property to specify the message type that the probe sends to request a logout from the target device. |
logoutRequestContent |
Use this property to specify any additional information that the probe sends with the logout request. |
logoutRequestHeaders |
Use this property to specify an HTTP header to send with all logout requests. This overrides the global HTTP header options configured by the httpHeader property. |
resyncRequestURI |
Use this property to specify the URI that the probe uses to request a resynchronization with the target system at startup. You can append the URI that you specify with this property with a query filter that limits the scope of the events that are returned by the request. Note: resyncRequestURI and resyncRequestMethod=GET can
be used independently, together with httpversion and responsetimeout,
to perform the resynchornization. However, either initialResync or resyncinterval must
also be specified.
|
resyncRequestMethod |
Use this property to specify the message type that the probe sends to request a resynchronization with the target system. Note: resyncRequestURI and resyncRequestMethod=GET can
be used independently, together with httpversion and responsetimeout,
to perform the resynchornization. However, either initialResync or resyncinterval must
also be specified.
|
resyncRequestContent |
Use this property to specify any additional information that the probe sends with the resynchronization request. |
resyncRequestHeaders |
Use this property to specify an HTTP header to send with all resynchronization requests. This overrides the global HTTP header options configured by the httpHeader property. |
subscribeRequestURI |
Use this property to specify the URI that the probe uses to request a subscription to receive new alarms as they are created in the target system. |
subscribeRequestMethod |
Use this property to specify the message type that the probe sends to request a subscription to receive new alarms. |
subscribeRequestContent |
Use this property to specify any additional information that the probe sends with the subscription request. |
subscribeRequestHeaders |
Use this property to specify an HTTP header to send with all subscription requests. This overrides the global HTTP header options configured by the httpHeader property. |
subscribeRefreshURI |
Use this property to specify the URI that the probe uses to request a subscription refresh. |
subscribeRefreshMethod |
Use this property to specify the message type that the probe sends to request a subscription refresh. |
subscribeRefreshContent |
Use this property to specify any additional information that the probe sends with the subscription refresh request. |
subscribeRefreshHeaders |
Use this property to specify an HTTP header to send with all subscription refresh requests. This overrides the global HTTP header options configured by the httpHeader property. |
subscribeRefreshInterval |
Use this property to specify the interval (in seconds) that the probe leaves between successive subscription refresh requests. This can be disabled by setting it to "" or leaving it commented out. If it is set to a negative value or an valid value such as String, it will default to 60 seconds. |
keepTokens |
Use this property to specify a comma-separated list of the attributes that the probe extracts from the incoming JSON data. These data items can be used in token substitution throughout the runtime of the probe. |
webSocketHeaders |
Use this property to specify a comma-separated list of HTTP headers to send with the initial Websocket handshake request. This overrides the global HTTP header options configured by the httpHeader property. Example use: By setting |
webSocketURI |
Use this property to specify the URI that the probe uses to request a WebSocket connection with the REST API. Note: webSocketURI can
work independently allowing the probe to subscribe to the target system.
|
webSocketPeristentURI |
Use this property to specify the persistent URI that the probe uses to re-establish a WebSocket connection. Note: This
property takes precedence over webSocketURI if
both are set. But, the probe uses webSocketURI if webSocketPeristentURI contains
tokens that can not be resolved to construct the final URI to use
to establish the WebSocket connection.
|
webSocketSubProtocol |
Use this property to specify the WebSocket subprotocol to use. |
webSocketSubscribeMessage |
Use this property to specify the subscribe message that the probe sends to the server through the WebSocket channel after successfully establishing the connection. |
webSocketRefreshMessage |
Use this property to specify the refresh message to send in the Ping frame that the probe sends to the WebSocket. |
webSocketRefreshInterval |
Use this property to specify the interval (in seconds) that the probe leaves between sending successive refresh requests to the WebSocket. This can be disabled by setting it to "" or leaving it commented out. If it is set to a negative value or an valid value such as String, it will default to 60 seconds. |
webSocketMaxFramePayloadLength |
Use this property to configure the size in bytes of the payload frame of the WebSocket. Specify a value between 1 and 512000 bytes (512KB). The default value is 65536 (bytes). If the probe receives a websocket frame that is bigger than the value set for this property, the probe fails and writes a message to the error log. |
refreshRetryCount |
Use this property to specify the maximum number of times that the probes sends a refresh request. If set to an invalid value such as a string or a value less than zero, it will default to zero and no limit is applied. The default is 0. |
securityProtocol |
Use this property to specify the security protocol to use when retrieving events from the REST API. |
tokenEndpointURI |
Use this property to specify the URI that the probe uses to obtain an access token for the target device. This is the path on the remote host to request an access token, for example:
By default, this property is not set, which disables the OAuth token request; no access token request will be sent to the server. |
basicAuthenticationUsername |
Use this property to specify the basic authentication username that the probe should use in the authentication header to gain access to the target device. |
basicAuthenticationPassword |
Use this property to specify the password associated with the basic authentication username that the probe should use in the authentication header. |
clientId |
Use this property to specify the |
clientSecret |
Use this property to specify the |
scope |
Use this property to specify the level of access to the target server that the probe is requesting. You can specify a comma-separated list of scopes, for example:
|
# Example format of Web Socket properties file
#httpVersion=1.1
#httpHeaders=
#responseTimeout=60
#loginRequestURI=
#loginRequestMethod=
#loginRequestContent
#loginRequestHeaders=
#loginRefreshURI=
#loginRefreshMethod=
#loginRefreshContent=
#loginRefreshHeaders=
#loginRefreshInterval=
#logoutRequestURI=
#logoutRequestMethod=
#logoutRequestContent=
#logoutRequestHeaders=
#resyncRequestURI=
#resyncRequestMethod=
#resyncRequestContent=
#resyncRequestHeaders=
#subscribeRequestURI=
#subscribeRequestMethod=
#subscribeRequestContent=
#subscribeRequestHeaders=
#subscribeRefreshURI=
#subscribeRefreshMethod=
#subscribeRefreshContent=
#subscribeRefreshHeaders=
#subscribeRefreshInterval=
#keepTokens=
#webSocketURI=
#webSocketPersistentURI=
#webSocketSubProtocol=
#webSocketSubscribeMessage=
#webSocketRefreshMessage=
#webSocketRefreshInterval=
#webSocketMaxFramePayloadLength=65536
#refreshRetryCount=0
#securityProtocol=
#tokenEndpointURI=
#basicAuthenticationUsername=
#basicAuthenticationPassword=
#clientId=
#clientSecret=
#scope=