Call StreamBaseClient.status().
- If it returns, the Streaming server is up.
- If you get a StreamBaseException, it is likely that the Streaming server is not up or accessible at the requested URL.
Note that the status() call makes a
synchronous XML-RPC call to the server, so do not use it often, but only when a problem is suspected. Also do not have 1000 clients all calling for status in a short period of time. Calling status() every second from under 20 clients is not expected to be a performance problem for the server.
Additional information: The
ServerClosedException is a subtype of
StreamBaseNetworkException which is a subtype of
StreamBaseException. A catch(StreamBaseException) expression is effective around an enqueue() call.