Class SaRMIServerInfo

java.lang.Object
com.saperion.connector.rmi.SaRMIServerInfo

public class SaRMIServerInfo extends Object
Holds the information about the Saperion RMI Server state.
States are e.g.
- running
- stopped
Author:
rbo
  • Constructor Details

    • SaRMIServerInfo

      public SaRMIServerInfo(String serverName, int serverPort, boolean withSSL)
      Constructor.
      Parameters:
      serverName - Server name
      serverPort - Server port
      withSSL - With SSL
  • Method Details

    • getSystemApplication

      public SaRMISystemConnector getSystemApplication()
      Returns:
      System application of this server.
    • restart

      public void restart()
      Restart this server.
    • getName

      public String getName()
      Returns:
      Name
    • getPort

      public int getPort()
      Returns:
      Port
    • getState

      public SaRMIServerInfo.ServerState getState()
      Returns:
      Server state
    • isFailOverServer

      public boolean isFailOverServer()
      Returns:
      Is fail over server
    • isWithSsl

      public boolean isWithSsl()
      Returns:
      true, if is with ssl
    • setRunning

      public void setRunning()
      Set running.
    • setOverload

      public void setOverload()
      Set to overloaded.
    • setStopped

      public void setStopped()
      Set to stopped.
    • getLastOverload

      public long getLastOverload()
      Returns:
      Last overload time
    • getActualServer

      public SaRMIServerInfo getActualServer()
      Reads the actual server from the list of fail over servers.
      Returns:
      Actual server
    • getFailOvers

      public List<SaRMIServerInfo> getFailOvers()
      Returns:
      Failover list
    • getConnector

      public SaRMISystemConnector getConnector()
      Returns:
      Own connector
    • readSystemInfo

      public SaSystemInfo readSystemInfo(int threshold)
      Reads system info.
      Parameters:
      threshold - threshold
      Returns:
      SystemInfo
    • getSystemInfo

      public SaSystemInfo getSystemInfo()
      Returns:
      Last system info
    • getLoad

      public int getLoad()
      Returns:
      System load in percent
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
      See Also:
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
      See Also:
    • toString

      public String toString()
      Overrides:
      toString in class Object