mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

fdorson
03.11.2008 5fde69a235be87ad20d48f3569eb9d0bc8e9c4e4
opends/src/server/org/opends/server/replication/server/ReplicationServer.java
@@ -627,13 +627,9 @@
  {
    // Changing those properties don't need specific code.
    // They will be applied for next connections.
    disconnectRemovedReplicationServers(configuration.getReplicationServer());
    replicationServers = configuration.getReplicationServer();
    if (replicationServers == null)
      replicationServers = new ArrayList<String>();
    queueSize = configuration.getQueueSize();
    long newPurgeDelay = configuration.getReplicationPurgeDelay();
    if (newPurgeDelay != purgeDelay)
@@ -1028,30 +1024,4 @@
      }
    }
  }
  /**
   * Compute the list of replication servers that are not any
   * more connected to this Replication Server and stop the
   * corresponding handlers.
   * @param newReplServers the list of the new replication servers configured.
   */
  private void disconnectRemovedReplicationServers(
      Collection<String> newReplServers)
  {
    Collection<String> serversToDisconnect = new ArrayList<String>();
    for (String server: replicationServers)
    {
      if (!newReplServers.contains(server))
        serversToDisconnect.add(server);
    }
    if (serversToDisconnect.isEmpty())
      return;
    for (ReplicationServerDomain replicationServerDomain: baseDNs.values())
    {
      replicationServerDomain.stopServers(serversToDisconnect);
    }
  }
}