close
The close method closes the BarrageSession.
Note
A BarrageSession created by barrage_session owns its gRPC channel, so close shuts down the channel as well. If closing the session or shutting down the channel throws an exception, close raises a DHError. close waits up to 10 seconds for the channel to terminate.
BarrageSession is also a context manager: a with block closes the session when it exits.
Syntax
Parameters
This method does not take any parameters.
Returns
None.
Examples
The following examples use anonymous authentication, so the target server must allow it (-DAuthHandlers=io.deephaven.auth.AnonymousAuthenticationHandler). For a server that requires credentials, pass auth_type and auth_token to barrage_session and to Session.
The following example uses a with block to close both the publishing client session and the Barrage session automatically: