Interface TableDataProtocolDriver

All Known Implementing Classes:
TableDataProtocolDriverImpl

public interface TableDataProtocolDriver
Interface for protocol drivers that handle table data communication with remote servers.
  • Method Details

    • authenticate

      void authenticate()
      Authenticates with the remote server.
    • connect

      void connect(@NotNull InetSocketAddress address) throws IOException
      Connect to a remote server.
      Parameters:
      address - The host/port to connect to
      Throws:
      IOException - if an I/O error occurs during connection
    • connect

      void connect(@NotNull String host, int port) throws IOException
      Connect to a remote server.
      Parameters:
      host - The host to connect to
      port - The port to connect to
      Throws:
      IOException - if an I/O error occurs during connection
    • connect

      void connect(@NotNull Supplier<SocketAddress> addressSupplier) throws IOException
      Connect to a remote server by address supplier, allowing fallback to different server addresses.
      Parameters:
      addressSupplier - The address supplier to determine each connection attempt's host and port
      Throws:
      IOException - if an I/O error occurs during connection
    • shutdown

      void shutdown()
      Shuts down the protocol driver and releases any resources.
    • removePendingRequest

      @Nullable TableDataRequest removePendingRequest(long requestKey)
      Removes and returns a pending request by its key.
      Parameters:
      requestKey - the unique key identifying the request
      Returns:
      the removed request, or null if no request exists for the given key
    • takeOrAllocateFreeRequest

      @NotNull TableDataRequest takeOrAllocateFreeRequest()
      Takes an available free request from the pool or allocates a new one if none are available.
      Returns:
      a table data request ready for use
    • getLogPrefix

      String getLogPrefix()
      Returns the log prefix used for logging messages from this driver.
      Returns:
      the log prefix string