Trading Networks 10.3 | Administering and Monitoring B2B Transactions | Service Development Help | Working with WebSocket Endpoints
 
Working with WebSocket Endpoints
 
Creating a WebSocket Server Endpoints
Creating a WebSocket Client Endpoint
A WebSocket endpoint represents an element on Integration Server that handles WebSocket connections. Every WebSocket endpoint has an address associated with it, which is used to locate and identify the endpoint. This address consists primarily of a Uniform Resource Identifier (URI), which specifies the location of the endpoint.
The WebSocket endpoint is registered either as a server endpoint or a client endpoint. In simple terms, a WebSocket server endpoint is a web address (URL) at which clients of a specific service can gain access to it. By referencing that URL, WebSocket clients can get to operations provided by that service.
The WebSocket endpoint contains callback services for both server and client. These services trigger notification, which allows applications to perform some action as a part of the event processing. There are a number of callback services handled by the WebSocket application and they include:
Service
Description
_onConnect
Invoked when the WebSocket connection is successfully established.
_onText
Invoked when a text message is received by the WebSocket endpoint.
_onBinary
Invoked when a binary message is received by the WebSocket endpoint.
_onClose
Invoked when a WebSocket connection is closed.
_onError
Invoked when a WebSocket endpoint encounters an error.