Shuts down the client and begins the process of release all native resources associated with the client and in-progress operations. It is critical that this function be called when finished with the client; otherwise, native resources will leak.
The client tracks unclosed operations and, as part of this process, closes them as well.
Attempts to open a network connection to the configured remote endpoint. Returned promise will be fulfilled if the transport-level connection is successfully established and the eventstream handshake completes without error.
Returns a promise that is resolved with additional context on a successful connection, otherwise rejected.
connect() may only be called once.
Optional
options: RpcClientConnectOptionsStatic
newFactory method to create a new client
configuration options that the new client must use
Returns a new client on success, otherwise throws an RpcError
Static
DISCONNECTIONEvent emitted when the client's underlying network connection is ended. Only emitted if the connection was previously successfully established, including a successful connect/connack handshake.
Listener type: DisconnectionListener
Generated using TypeDoc
Eventstream RPC client - uses an underlying eventstream connection to implement the eventstream RPC protocol