FME Flow: 2024.2
WebSocket Subscriber
The WebSocket subscriber receives notifications from topics and publishes them over TCP to WebSocket-supported clients that are connected to the FME Flow WebSocket Server or another target URL. Supported clients include:
- FME Form workspaces configured with WebSocketConnector transformers
- HTML5-based web browsers, such as:
- Microsoft Edge
- Firefox 11+
- Chrome 16+
- Safari 6+
- Opera 12.10+
Client Requirements
To receive data from the subscriber, clients must send the following preamble:
{
"ws_op" : "open",
"ws_stream_ids" : ["<stream_id1>", "<stream_id2>", "<stream_id3>", ...]
}
For more information, see WebSocket Server Messaging Protocol.
WebSocket Communication Channels
The WebSocket Server is located on the FME Flow Core. By default, FME Flow uses the following channels for WebSocket communication:
- Port: 7078
- URI: ws://<hostname>:7078/websocket
To configure the WebSocket server for SSL communication, see Configuring for HTTPS.
Configuring the Subscriber
- In the FME Flow Web User Interface, select Notifications > Subscriptions, and click New.
- Provide a name for the Subscription
- In the Protocol drop down menu, select WebSocket.
-
Specify the Topics you want to subscribe to using the drop-down selector. To create a topic and use it right away, click +.
- Target URL: This field is pre-populated with the URL of the WebSocket server on the FME Flow Core (included with your FME Flow installation). However, you can choose to connect to a different WebSocket server.
- Stream ID: Specify a Stream ID for the subscriber. The Stream ID allows the WebSocket server to uniquely identify message streams and connect them to the right requesting applications.
- Click OK.