| | |
| | | } |
| | | |
| | | if (debugEnabled()) |
| | | TRACER.debugInfo("[IE] In " + getReplicationMonitorInstanceName() |
| | | TRACER.debugInfo("[IE] In " + broker.getReplicationMonitorInstanceName() |
| | | + " export ends with " + " connected=" + broker.isConnected() |
| | | + " exportRootException=" + exportRootException); |
| | | |
| | |
| | | } |
| | | } |
| | | |
| | | private String getReplicationMonitorInstanceName() |
| | | { |
| | | return broker.getReplicationMonitor().getMonitorInstanceName(); |
| | | } |
| | | |
| | | /** |
| | | * For all remote servers in the start list: |
| | | * - wait it has finished the import and present the expected generationID, |
| | |
| | | msg = broker.receive(false, false, true); |
| | | |
| | | if (debugEnabled()) |
| | | TRACER.debugInfo("[IE] In " + getReplicationMonitorInstanceName() |
| | | TRACER.debugInfo("[IE] In " |
| | | + broker.getReplicationMonitorInstanceName() |
| | | + ", receiveEntryBytes " + msg); |
| | | |
| | | if (msg == null) |
| | |
| | | broker.publish(amsg, false); |
| | | if (debugEnabled()) |
| | | TRACER.debugInfo("[IE] In " |
| | | + getReplicationMonitorInstanceName() |
| | | + broker.getReplicationMonitorInstanceName() |
| | | + ", publish InitializeRcvAckMsg" + amsg); |
| | | } |
| | | } |
| | |
| | | TRACER.debugInfo("[IE] Entering exportLDIFEntry pub entry=" |
| | | + Arrays.toString(lDIFEntry)); |
| | | |
| | | // publish the message |
| | | boolean sent = broker.publish(entryMessage, false); |
| | | |
| | | // process any publish error |
| | | if (((!sent)|| |
| | | (broker.hasConnectionError()))|| |
| | | (broker.getNumLostConnections() != ieContext.initNumLostConnections)) |
| | | if (!sent |
| | | || broker.hasConnectionError() |
| | | || broker.getNumLostConnections() != ieContext.initNumLostConnections) |
| | | { |
| | | // publish failed - store the error in the ieContext ... |
| | | DirectoryException de = new DirectoryException(ResultCode.OTHER, |
| | |
| | | * @throws DirectoryException If it was not possible to publish the |
| | | * Initialization message to the Topology. |
| | | */ |
| | | public void initializeFromRemote(int source) |
| | | throws DirectoryException |
| | | public void initializeFromRemote(int source) throws DirectoryException |
| | | { |
| | | initializeFromRemote(source, null); |
| | | } |
| | |
| | | * @throws ConfigException If the DirectoryServer configuration was |
| | | * incorrect. |
| | | */ |
| | | public void startPublishService( |
| | | Collection<String> replicationServers, int window, |
| | | public void startPublishService(Set<String> replicationServers, int window, |
| | | long heartbeatInterval, long changetimeHeartbeatInterval) |
| | | throws ConfigException |
| | | { |
| | |
| | | /** |
| | | * Change some ReplicationDomain parameters. |
| | | * |
| | | * @param replicationServers The new list of Replication Servers that this |
| | | * @param replicationServers The new set of Replication Servers that this |
| | | * domain should now use. |
| | | * @param windowSize The window size that this domain should use. |
| | | * @param heartbeatInterval The heartbeatInterval that this domain should |
| | | * use. |
| | | * @param groupId The new group id to use |
| | | */ |
| | | public void changeConfig( |
| | | Collection<String> replicationServers, |
| | | int windowSize, |
| | | long heartbeatInterval, |
| | | byte groupId) |
| | | public void changeConfig(Set<String> replicationServers, int windowSize, |
| | | long heartbeatInterval, byte groupId) |
| | | { |
| | | this.groupId = groupId; |
| | | |
| | |
| | | Set<String> s2 = new HashSet<String>(s1); |
| | | s2.addAll(includeAttributesForDeletes); |
| | | |
| | | Set<String> s = eclIncludesByServer.get(serverId); |
| | | if (!s1.equals(s)) |
| | | if (!s1.equals(eclIncludesByServer.get(serverId))) |
| | | { |
| | | configurationChanged = true; |
| | | eclIncludesByServer.put(serverId, Collections.unmodifiableSet(s1)); |
| | | } |
| | | |
| | | s = eclIncludesForDeletesByServer.get(serverId); |
| | | if (!s2.equals(s)) |
| | | if (!s2.equals(eclIncludesForDeletesByServer.get(serverId))) |
| | | { |
| | | configurationChanged = true; |
| | | eclIncludesForDeletesByServer.put(serverId, |
| | |
| | | } |
| | | |
| | | // and rebuild the global list to be ready for usage |
| | | s = new HashSet<String>(); |
| | | Set<String> s = new HashSet<String>(); |
| | | for (Set<String> attributes : eclIncludesByServer.values()) |
| | | { |
| | | s.addAll(attributes); |