Class ConnectorServer

java.lang.Object
org.identityconnectors.framework.server.ConnectorServer
Direct Known Subclasses:
ConnectorServerImpl

public abstract class ConnectorServer extends Object
Connector server interface.
  • Constructor Details Link icon

    • ConnectorServer Link icon

      public ConnectorServer()
  • Method Details Link icon

    • newInstance Link icon

      public static ConnectorServer newInstance()
      Get the singleton instance of the ConnectorServer.
    • getPort Link icon

      public int getPort()
      Returns the port to listen on.
      Returns:
      The port to listen on.
    • setPort Link icon

      public void setPort(int port)
      Sets the port to listen on.
      Parameters:
      port - The port to listen on
    • getMaxConnections Link icon

      public int getMaxConnections()
      Returns the max connections to queue.
      Returns:
      The max connections to queue
    • setMaxConnections Link icon

      public void setMaxConnections(int max)
      Sets the max connections to queue.
      Parameters:
      max - The max connections to queue.
    • getMaxWorkers Link icon

      public int getMaxWorkers()
      Returns the max worker threads to allow.
      Returns:
      The max worker threads to allow.
    • setMaxWorkers Link icon

      public void setMaxWorkers(int maxWorkers)
      Sets the max worker thread to allow.
      Parameters:
      maxWorkers - The max worker threads to allow.
    • getMinWorkers Link icon

      public int getMinWorkers()
      Returns the min worker threads to allow.
      Returns:
      The min worker threads to allow.
    • setMinWorkers Link icon

      public void setMinWorkers(int minWorkers)
      Sets the min worker thread to allow.
      Parameters:
      minWorkers - The min worker threads to allow.
    • getIfAddress Link icon

      public InetAddress getIfAddress()
      Returns the network interface address to bind to. May be null.
      Returns:
      The network interface address to bind to or null.
    • setIfAddress Link icon

      public void setIfAddress(InetAddress addr)
      Sets the interface address to bind to.
      Parameters:
      addr - The network interface address to bind to or null.
    • getUseSSL Link icon

      public boolean getUseSSL()
      Returns true if we are to use SSL.
      Returns:
      true if we are to use SSL.
    • setUseSSL Link icon

      public void setUseSSL(boolean ssl)
      Sets whether we should use ssl.
      Parameters:
      ssl - true if we are to use SSL.
    • getKeyHash Link icon

      public String getKeyHash()
      Returns the base-64 encoded SHA1 hash of the key.
      Returns:
      the base-64 encoded SHA1 hash of the key.
    • setKeyHash Link icon

      public void setKeyHash(String hash)
      Sets the base-64 encoded SHA1 hash of the key.
      Parameters:
      hash - the base-64 encoded SHA1 hash of the key.
    • getKeyManagers Link icon

      public List<KeyManager> getKeyManagers()
      Returns the key managers to use for the SSL connection. If empty, use the JVM default.
      Returns:
      the key managers to use for the SSL connection.
    • setKeyManagers Link icon

      public void setKeyManagers(List<KeyManager> keyManagers)
      Sets the key managers to use for the SSL connection.
      Parameters:
      keyManagers - the key managers to use for the SSL connection. If null or empty, uses the JVM default.
    • getBundleURLs Link icon

      public List<URL> getBundleURLs()
      Gets the bundle URLs for connectors to expose by this server.
      Returns:
      The bundle URLs for connectors to expose by this server.
    • setBundleURLs Link icon

      public void setBundleURLs(List<URL> urls)
      Sets the bundle URLs for connectors to expose by this server.
      Parameters:
      urls - The bundle URLs for connectors to expose by this server.
    • getBundleParentClassLoader Link icon

      public ClassLoader getBundleParentClassLoader()
      Gets the class loader that will be used as the parent of the bundle class loaders.
      Returns:
      the class loader that will be used as the parent of the bundle class loaders.
    • setBundleParentClassLoader Link icon

      public void setBundleParentClassLoader(ClassLoader bundleParentClassLoader)
      Sets the class loader that will be used as the parent of the bundle class loaders.
      Parameters:
      bundleParentClassLoader - the class loader that will be used as the parent of the bundle class loaders.
    • getStartTime Link icon

      public abstract Long getStartTime()
      Gets the time when the servers was started last time.

      System.currentTimeMillis()

      Returns:
      last start dateTime in milliseconds
    • start Link icon

      public abstract void start()
      Starts the server. All server settings must be configured prior to calling. The following methods are required to be called:
    • stop Link icon

      public abstract void stop()
      Stops the server gracefully. Returns when all in-progress connections have been serviced.
    • isStarted Link icon

      public abstract boolean isStarted()
      Return true if the server is started. Note that started is a logical state (start method has been called). It does not necessarily reflect the health of the server
      Returns:
      true if the server is started.
    • awaitStop Link icon

      public abstract void awaitStop() throws InterruptedException
      Waits for the server to stop. Similarly to the isStarted() method, this method depends on the server's logical state. The trigger that wakes up waiting threads is a call to the stop() method, not the health of the server.
      Throws:
      InterruptedException - if the waiting thread is interrupted.