This documentation is for WSO2 Enterprise Service Bus version 5.0.0. For the latest ESB, view the latest WSO2 Enterprise Integrator documentation.

All docs This doc
Skip to end of metadata
Go to start of metadata

The WSO2 ESB WebSocket protocol implementation is based on the WebSocket protocol, and allows full-duplex message mediation.

Following is a sample WebSocket inbound endpoint configuration:

<inboundEndpoint name="WebSocketListenerEP" onError="fault" protocol=“ws" sequence=“TestIn" suspend="false”>
     <parameter name="">9091</parameter>
     <parameter name="ws.outflow.dispatch.sequence">TestOut</parameter> 
     <parameter name="ws.client.side.broadcast.level">0</parameter>
     <parameter name="ws.outflow.dispatch.fault.sequence">fault</parameter>

WebSocket inbound endpoint parameters

ParameterDescriptionRequired netty listener port on which the WebSocket inbound listens.Yes
ws.client.side.broadcast.level The client broadcast level that defines how WebSocket frames are broadcasted from the WebSocket inbound endpoint to the client. Broadcast happens based on the subscriber path client connected to the WebSocket inbound endpoint. The three possible levels are as follows:
0 - Only a unique client can receive the frame from a WebSocket inbound endpoint.
1 - All the clients connected with the same subscriber path receives the WebSocket frame.
2 - All the clients connected with the same subscriber path, except the one who publishes the frame to the inbound, receives the WebSocket frame.
ws.outflow.dispatch.sequenceThe sequence for the back-end to client mediation.Yes
ws.outflow.dispatch.fault.sequenceThe fault sequence for the back-end to client mediation path.Yes
ws.boss.thread.pool.sizeThe size of the netty boss pool.No
ws.worker.thread.pool.sizeThe size of the worker thread pool.No
ws.subprotocol.handler.classThe custom subprotocol handler classes separated by a semicolon.No

Specifies the content type of the Web Socket frames that are received from the inbound endpoint.

ws.shutdown.status.codeSpecifies the status code of the closed web socket frame sent when the inbound endpoint is closed.No
ws.shutdown.status.messageSpecifies the status message of the closed web socket frame when the inbound endpoint is closed.No
  • No labels