Class OClientConnectionManager

java.lang.Object
com.orientechnologies.orient.server.OClientConnectionManager

public class OClientConnectionManager extends Object
  • Field Details

  • Constructor Details

    • OClientConnectionManager

      public OClientConnectionManager(OServer server)
  • Method Details

    • cleanExpiredConnections

      public void cleanExpiredConnections()
    • connect

      public OClientConnection connect(ONetworkProtocol iProtocol)
      Create a connection.
      Parameters:
      iProtocol - protocol which will be used by connection
      Returns:
      new connection
    • connect

      public OClientConnection connect(ONetworkProtocol iProtocol, OClientConnection connection, byte[] tokenBytes)
      Create a connection.
      Parameters:
      iProtocol - protocol which will be used by connection
      Returns:
      new connection
    • reConnect

      public OClientConnection reConnect(ONetworkProtocol iProtocol, byte[] tokenBytes)
    • getConnection

      public OClientConnection getConnection(int iChannelId, ONetworkProtocol protocol)
      Retrieves the connection by id.
      Parameters:
      iChannelId - id of connection
      Returns:
      The connection if any, otherwise null
    • getConnection

      public OClientConnection getConnection(String iAddress)
      Retrieves the connection by address/port.
      Parameters:
      iAddress - The address as string in the format address as format :
      Returns:
      The connection if any, otherwise null
    • kill

      public void kill(int iChannelId)
      Disconnects and kill the associated network manager.
      Parameters:
      iChannelId - id of connection
    • kill

      public void kill(OClientConnection connection)
      Disconnects and kill the associated network manager.
      Parameters:
      connection - connection to kill
    • has

      public boolean has(int id)
    • interrupt

      public void interrupt(int iChannelId)
      Interrupt the associated network manager.
      Parameters:
      iChannelId - id of connection
    • disconnect

      public boolean disconnect(int iChannelId)
      Disconnects a client connections
      Parameters:
      iChannelId - id of connection
      Returns:
      true if was last one, otherwise false
    • disconnect

      public void disconnect(OClientConnection iConnection)
    • getConnections

      public List<OClientConnection> getConnections()
    • getTotal

      public int getTotal()
    • shutdown

      public void shutdown()
    • killAllChannels

      public void killAllChannels()
    • getSession

      public OClientSessions getSession(OClientConnection connection)