Class DndSessionFactoryBarrage

java.lang.Object
io.deephaven.enterprise.dnd.client.DndSessionFactoryBarrage

public class DndSessionFactoryBarrage extends Object
A factory class for creating barrage sessions.
  • Constructor Details

    • DndSessionFactoryBarrage

      public DndSessionFactoryBarrage(@NotNull String serverUrl) throws IOException
      Create a new DndSessionFactoryBarrage for fetching barrage tables from a Persistent Query
      Parameters:
      serverUrl - the url to the server
      Throws:
      IOException - if there was a problem connecting to the server
  • Method Details

    • doOnAuthenticated

      protected void doOnAuthenticated()
    • makeSession

      protected DndSessionBarrage makeSession(io.deephaven.proto.controller.PersistentQueryInfoMessage qConfig, String trustStore, io.deephaven.enterprise.auth.AuthToken authToken, ScheduledExecutorService executor, boolean deleteOnClose, ControllerClientGrpc controllerClientGrpc, int maxInboundMessageSize) throws IOException
      Throws:
      IOException
    • close

      public void close()
      Close all resources and connections with the server.
    • password

      public void password(@NotNull String user, @NotNull String password)
      Authenticate with the server using a username and password
      Parameters:
      user - the username
      password - the password
    • privateKey

      public void privateKey(@NotNull String keyFile)
      Authenticate to the server using a private key file.
      Parameters:
      keyFile - the private key file
    • delegateToken

      public void delegateToken(@NotNull io.deephaven.enterprise.auth.AuthToken delegateToken)
      Use a delegate token to authenticate.
    • delegateToken

      public void delegateToken()
      Use a delegate token to authenticate; automatically calling the default AuthenticationClientManager.

      This is suitable for use within a single Deephaven cluster, when one authenticated worker should connect as the same user to another worker.

    • createPersistentQueryConfig

      public io.deephaven.proto.controller.PersistentQueryConfigMessage.Builder createPersistentQueryConfig(@NotNull String name, float heapSizeGb, long autoDeleteTimeoutMillis)
      Create a new Interactive Console Persistent Query configuration with a language set to `Python`
      Parameters:
      name - the name to create with
      heapSizeGb - the desired heap size in GB
      autoDeleteTimeoutMillis - how long the query should remain if all clients disconnect
      Returns:
      a new PersistentQueryConfigMessage.Builder to use with newWorker(PersistentQueryConfigMessage, long)
    • newWorker

      public DndSessionBarrage newWorker(@NotNull String name, float heapSizeGb, long autoDeleteTimeoutMillis, long startupTimeoutMillis) throws IOException
      Throws:
      IOException
    • newWorker

      public DndSessionBarrage newWorker(@NotNull io.deephaven.proto.controller.PersistentQueryConfigMessage message, long startupTimeoutMillis) throws IOException
      Create a new Interactive Console Persistent Query session.
      Parameters:
      message - the PersistentQueryInfoMessage to create the Persistent Query with
      startupTimeoutMillis - the timeout for starting the query
      Returns:
      a new DndSessionFactoryBase for communicating with the Persistent Query.
      Throws:
      IOException - if there was a problem creating the Persistent Query
    • persistentQuery

      public DndSessionBarrage persistentQuery(@NotNull String name) throws IOException
      Create a new DndSession to the specified Persistent Query by name.
      Parameters:
      name - the name of the Persistent Query
      Returns:
      a new DndSession for communicating with the Persistent Query.
      Throws:
      IOException - if there was a problem creating the Persistent Query
    • persistentQuery

      public DndSessionBarrage persistentQuery(long serial) throws IOException
      Create a new DndSession to the specified Persistent Query by serial.
      Parameters:
      serial - the name of the Persistent Query
      Returns:
      a new DndSession for communicating with the Persistent Query.
      Throws:
      IOException - if there was a problem creating the Persistent Query
    • setMaxInboundMessageSize

      public void setMaxInboundMessageSize(int maxInboundMessageSize)