Class DSInfo


  • @Immutable
    public final class DSInfo
    extends Object
    This class holds information about a DS connected to the topology. This information is to be exchanged through the replication protocol in topology messages, to keep every member (RS or DS) of the topology aware of the DS topology.
    • Constructor Detail

      • DSInfo

        public DSInfo​(ReplicaId replicaId,
                      com.forgerock.opendj.util.HostPort hostPort,
                      ReplicationServerId rsId,
                      long generationId,
                      ServerStatus status,
                      com.forgerock.opendj.discovery.GroupId groupId,
                      ProcessId processId,
                      Set<String> refUrls,
                      Set<String> eclIncludes,
                      Set<String> eclIncludesForDeletes,
                      short protocolVersion,
                      Set<com.forgerock.opendj.util.HostPort> adminHostPorts,
                      Map<ConnectionSecurity,​Set<com.forgerock.opendj.util.HostPort>> ldapHostPorts)
        Creates a new instance of DSInfo with every given info.
        Parameters:
        replicaId - The DS replica id
        hostPort - the DS host port
        rsId - The RS id the DS is connected to
        generationId - The generation id the DS is using
        status - The DS status
        groupId - DS group id
        processId - The DS process ID
        refUrls - DS exported referrals URLs
        eclIncludes - The set of entry attributes to include in the ECL.
        eclIncludesForDeletes - The set of entry attributes to include in the ECL for deletes.
        protocolVersion - Protocol version supported by this server.
        adminHostPorts - Admin host ports supported by this server.
        ldapHostPorts - LDAP host ports supported by this server.
    • Method Detail

      • getReplicaId

        public ReplicaId getReplicaId()
        Get the replica id.
        Returns:
        the replica id
      • getHostPort

        public com.forgerock.opendj.util.HostPort getHostPort()
        Get the host port.
        Returns:
        the host port
      • getRsId

        public ReplicationServerId getRsId()
        Get the RS id the DS is connected to.
        Returns:
        the RS id the DS is connected to
      • getGenerationId

        public long getGenerationId()
        Get the generation id DS is using.
        Returns:
        the generation id DS is using.
      • getStatus

        public ServerStatus getStatus()
        Get the DS status.
        Returns:
        the DS status
      • getGroupId

        public com.forgerock.opendj.discovery.GroupId getGroupId()
        Get the DS group id.
        Returns:
        The DS group id
      • getProcessId

        public ProcessId getProcessId()
        Get the DS process id.
        Returns:
        The DS process id
      • getRefUrls

        public Set<String> getRefUrls()
        Get the DS exported URLs for referrals.
        Returns:
        The DS exported URLs for referrals
      • getEclIncludes

        public Set<String> getEclIncludes()
        Get the entry attributes to be included in the ECL.
        Returns:
        The entry attributes to be included in the ECL.
      • getEclIncludesForDeletes

        public Set<String> getEclIncludesForDeletes()
        Get the entry attributes to be included in the ECL for delete operations.
        Returns:
        The entry attributes to be included in the ECL.
      • getProtocolVersion

        public short getProtocolVersion()
        Get the protocol version supported by this server. Returns ProtocolVersion.UNKNOWN_VERSION when the protocol version is not known (too old version).
        Returns:
        The protocol version.
      • getAdminHostPorts

        public Set<com.forgerock.opendj.util.HostPort> getAdminHostPorts()
        Returns all the admin host ports opened by this server.
        Returns:
        all the admin host ports opened by this server
      • getLdapHostPorts

        public Map<ConnectionSecurity,​Set<com.forgerock.opendj.util.HostPort>> getLdapHostPorts()
        Returns all the LDAP(s) host port(s) opened by this server.
        Returns:
        all the LDAP(s) host port(s) opened by this server
      • cloneWithReplicationServerId

        public DSInfo cloneWithReplicationServerId​(ReplicationServerId rsId)
        Returns a new instance of DSInfo with the specified replication server Id.
        Parameters:
        rsId - the replication server Id to set on the new DSInfo object.
        Returns:
        a new instance of DSInfo with the specified replication server Id.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object