Package org.h2.server

Class TcpServerThread

java.lang.Object
org.h2.server.TcpServerThread
All Implemented Interfaces:
Runnable

public class TcpServerThread extends Object implements Runnable
One server thread is opened per client connection.
  • Field Details

  • Constructor Details

    • TcpServerThread

      TcpServerThread(Socket socket, TcpServer server, int id)
  • Method Details

    • trace

      private void trace(String s)
    • run

      public void run()
      Specified by:
      run in interface Runnable
    • closeSession

      private void closeSession()
    • close

      void close()
      Close a connection.
    • sendError

      private void sendError(Throwable t, boolean withStatus)
    • setParameters

      private void setParameters(Command command) throws IOException
      Throws:
      IOException
    • process

      private void process() throws IOException
      Throws:
      IOException
    • getState

      private int getState(int oldModificationId)
    • sendRows

      private void sendRows(ResultInterface result, long count) throws IOException
      Throws:
      IOException
    • setThread

      void setThread(Thread thread)
    • getThread

      Thread getThread()
    • cancelStatement

      void cancelStatement(String targetSessionId, int statementId)
      Cancel a running statement.
      Parameters:
      targetSessionId - the session id
      statementId - the statement to cancel