Interface SessionManager

All Known Implementing Classes:
SessionManagerImpl

public interface SessionManager
Mange the lifecycle of the Session.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    closeSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle)
    Close the session with the specified identifier and releases the resources used by the session.
    create(DefaultContext defaultContext)
    Create the SessionManager with the default configuration.
    getSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle)
    Get the Session with the identifier.
    openSession(org.apache.flink.table.gateway.api.session.SessionEnvironment environment)
    Register a new Session.
    void
    Start the SessionManager and do the required initialization.
    void
    Destroy the SessionManager and releases used resources.
  • Method Details

    • create

      static SessionManager create(DefaultContext defaultContext)
      Create the SessionManager with the default configuration.
    • start

      void start()
      Start the SessionManager and do the required initialization.
    • stop

      void stop()
      Destroy the SessionManager and releases used resources.
    • getSession

      Session getSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException
      Get the Session with the identifier.
      Parameters:
      sessionHandle - identifier of the session.
      Returns:
      registered session.
      Throws:
      org.apache.flink.table.gateway.api.utils.SqlGatewayException
    • openSession

      Session openSession(org.apache.flink.table.gateway.api.session.SessionEnvironment environment) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException
      Register a new Session.
      Parameters:
      environment - the initialization environment.
      Returns:
      created session.
      Throws:
      org.apache.flink.table.gateway.api.utils.SqlGatewayException
    • closeSession

      void closeSession(org.apache.flink.table.gateway.api.session.SessionHandle sessionHandle) throws org.apache.flink.table.gateway.api.utils.SqlGatewayException
      Close the session with the specified identifier and releases the resources used by the session.
      Parameters:
      sessionHandle - the identifier of the session.
      Throws:
      org.apache.flink.table.gateway.api.utils.SqlGatewayException