From 5349c97806bb0a00038d8dc3dee4254fad187649 Mon Sep 17 00:00:00 2001
From: gbellato <gbellato@localhost>
Date: Wed, 25 Apr 2007 16:35:36 +0000
Subject: [PATCH] Second set of renaming for issue 1090 Rename org.opends.server.replication.changelog into org.opends.server.synchronization.changelog Use replication instead of synchronization in many places in the code/comment/file names
---
opends/src/server/org/opends/server/replication/protocol/HeartbeatMessage.java | 4
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java | 14
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogTest.java | 20
opends/src/server/org/opends/server/messages/MessageHandler.java | 2
opends/src/server/org/opends/server/replication/plugin/PersistentServerState.java | 12
opends/src/server/org/opends/server/replication/protocol/AddContext.java | 2
opends/src/server/org/opends/server/tasks/InitializeTask.java | 10
opends/src/server/org/opends/server/replication/server/ChangelogAckMessageList.java | 2
opends/src/server/org/opends/server/replication/protocol/ModifyDnContext.java | 2
opends/src/server/org/opends/server/replication/protocol/ErrorMessage.java | 2
opends/src/server/org/opends/server/replication/server/ChangelogData.java | 6
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ServerStateTest.java | 4
opends/src/server/org/opends/server/replication/server/ServerWriter.java | 4
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReSyncTest.java | 8
opends/src/server/org/opends/server/replication/server/AckMessageList.java | 2
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/InitOnLineTest.java | 48 +-
opends/src/server/org/opends/server/replication/protocol/SocketSession.java | 8
opends/src/server/org/opends/server/replication/plugin/ChangelogBroker.java | 18
opends/src/server/org/opends/server/replication/plugin/ReplicationMonitor.java | 14
opends/src/server/org/opends/server/replication/protocol/OperationContext.java | 4
opends/src/server/org/opends/server/replication/plugin/ModifyFakeOperation.java | 4
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ValueInfoTest.java | 4
opends/src/server/org/opends/server/replication/server/Changelog.java | 4
opends/src/server/org/opends/server/replication/protocol/ChangelogStartMessage.java | 2
opends/src/server/org/opends/server/replication/server/ServerReader.java | 8
opends/src/server/org/opends/server/replication/server/ChangelogCache.java | 4
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ModifyConflictTest.java | 8
opends/src/server/org/opends/server/replication/protocol/AckMessage.java | 2
opends/src/server/org/opends/server/replication/plugin/Historical.java | 4
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/StressTest.java | 29
opends/src/server/org/opends/server/replication/server/package-info.java | 8
opends/src/server/org/opends/server/replication/protocol/InitializeTargetMessage.java | 2
opends/src/server/org/opends/server/replication/protocol/ReplicationMessage.java | 12
opends/src/server/org/opends/server/replication/server/AckMessageListComparator.java | 2
opends/src/server/org/opends/server/replication/package-info.java | 3
opends/src/server/org/opends/server/replication/protocol/ProtocolSession.java | 30
opends/src/server/org/opends/server/replication/protocol/UpdateMessage.java | 6
opends/src/server/org/opends/server/replication/protocol/package-info.java | 6
opends/src/server/org/opends/server/replication/plugin/FakeOperation.java | 10
opends/src/server/org/opends/server/replication/server/ChangelogKey.java | 2
opends/src/server/org/opends/server/replication/protocol/ServerStartMessage.java | 4
opends/src/server/org/opends/server/replication/plugin/ReplLDIFInputStream.java | 14
opends/src/server/org/opends/server/replication/server/DbHandler.java | 6
opends/src/server/org/opends/server/replication/server/ChangelogDBException.java | 2
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberGeneratorTest.java | 4
opends/src/server/org/opends/server/replication/protocol/EntryMessage.java | 2
opends/src/server/org/opends/server/replication/plugin/HeartbeatMonitor.java | 4
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SchemaReplicationTest.java | 30 -
opends/src/server/org/opends/server/replication/plugin/ListenerThread.java | 10
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/protocol/SynchronizationMsgTest.java | 22
opends/src/server/org/opends/server/replication/plugin/ReplLDIFOutputStream.java | 10
opends/src/server/org/opends/server/replication/server/ServerHandler.java | 12
opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java | 118 +++---
opends/src/server/org/opends/server/tasks/InitializeTargetTask.java | 6
opends/src/server/org/opends/server/replication/server/ChangelogDbEnv.java | 4
opends/src/server/org/opends/server/messages/ReplicationMessages.java | 12
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogFakeConfiguration.java | 2
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ProtocolWindowTest.java | 26
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberTest.java | 4
opends/src/server/org/opends/server/replication/server/ChangelogIteratorComparator.java | 2
opends/src/server/org/opends/server/replication/server/ChangelogIterator.java | 4
opends/src/server/org/opends/server/replication/plugin/MultimasterReplication.java | 78 ++--
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/UpdateComparatorTest.java | 8
opends/src/server/org/opends/server/replication/server/ChangelogDB.java | 4
opends/src/server/org/opends/server/replication/common/package-info.java | 2
opends/src/server/org/opends/server/replication/protocol/DoneMessage.java | 2
opends/src/server/org/opends/server/replication/protocol/ModifyContext.java | 2
opends/src/server/org/opends/server/replication/protocol/RoutableMessage.java | 6
opends/tests/unit-tests-testng/src/server/org/opends/server/controls/ControlsTestCase.java | 2
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/UpdateOperationTest.java | 88 ++--
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/dbHandlerTest.java | 12
opends/src/server/org/opends/server/replication/plugin/ChangelogListener.java | 2
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReplicationTestCase.java | 30
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentServerStateTest.java | 4
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentStateTest.java | 4
opends/src/server/org/opends/server/replication/plugin/PendingChange.java | 2
opends/src/server/org/opends/server/replication/protocol/InitializeRequestMessage.java | 4
opends/src/server/org/opends/server/replication/protocol/HeartbeatThread.java | 2
opends/src/server/org/opends/server/replication/server/MsgQueue.java | 2
opends/src/server/org/opends/server/replication/plugin/package-info.java | 12
opends/src/server/org/opends/server/replication/protocol/WindowMessage.java | 2
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/AttrInfoTest.java | 4
opends/src/server/org/opends/server/replication/server/UpdateComparator.java | 2
83 files changed, 448 insertions(+), 460 deletions(-)
diff --git a/opends/src/server/org/opends/server/messages/MessageHandler.java b/opends/src/server/org/opends/server/messages/MessageHandler.java
index f6bceb4..baf2fe5 100644
--- a/opends/src/server/org/opends/server/messages/MessageHandler.java
+++ b/opends/src/server/org/opends/server/messages/MessageHandler.java
@@ -293,7 +293,7 @@
TaskMessages.registerMessages();
AdminMessages.registerMessages();
AciMessages.registerMessages();
- SynchronizationMessages.registerMessages();
+ ReplicationMessages.registerMessages();
}
diff --git a/opends/src/server/org/opends/server/messages/SynchronizationMessages.java b/opends/src/server/org/opends/server/messages/ReplicationMessages.java
similarity index 97%
rename from opends/src/server/org/opends/server/messages/SynchronizationMessages.java
rename to opends/src/server/org/opends/server/messages/ReplicationMessages.java
index 02124d4..a2dde6d 100644
--- a/opends/src/server/org/opends/server/messages/SynchronizationMessages.java
+++ b/opends/src/server/org/opends/server/messages/ReplicationMessages.java
@@ -30,9 +30,9 @@
/**
* This class defines the set of message IDs and default format strings for
- * messages associated with the Synchronization.
+ * messages associated with the Replication.
*/
-public class SynchronizationMessages {
+public class ReplicationMessages {
/**
* Name used to store attachment of historical information in the
@@ -240,7 +240,7 @@
/**
* Exception while receiving a message.
*/
- public static final int MSGID_EXCEPTION_RECEIVING_SYNCHRONIZATION_MESSAGE =
+ public static final int MSGID_EXCEPTION_RECEIVING_REPLICATION_MESSAGE =
CATEGORY_MASK_SYNC | SEVERITY_MASK_SEVERE_ERROR | 34;
/**
@@ -443,8 +443,8 @@
"An unexpected error happened sending an ack to %s." +
"This connection is going to be closed. ");
registerMessage(
- MSGID_EXCEPTION_RECEIVING_SYNCHRONIZATION_MESSAGE,
- "An Exception was caught while receiving synchronization message : %s");
+ MSGID_EXCEPTION_RECEIVING_REPLICATION_MESSAGE,
+ "An Exception was caught while receiving replication message : %s");
registerMessage(MSGID_LOOP_REPLAYING_OPERATION,
"A loop was detected while replaying operation: %s");
registerMessage(MSGID_FILE_CHECK_CREATE_FAILED,
@@ -468,7 +468,7 @@
" The Changelog servers will queue up to this number of messages" +
" in its memory queue and save the older messages to persistent" +
" storage. Using a larger size may improve performances when" +
- " The synchronization delay is larger than this size but at the cost" +
+ " The replication delay is larger than this size but at the cost" +
" of using more memory");
registerMessage(MSGID_CHANGELOG_DIR_PATH_ATTR,
"Specifies the Changelog Server directory. The Changelog server" +
diff --git a/opends/src/server/org/opends/server/replication/common/package-info.java b/opends/src/server/org/opends/server/replication/common/package-info.java
index 96d3f4d..563dbdd 100644
--- a/opends/src/server/org/opends/server/replication/common/package-info.java
+++ b/opends/src/server/org/opends/server/replication/common/package-info.java
@@ -38,7 +38,7 @@
* <li>
* <A HREF="ServerState.html"><B>ServerState</B></A>
* This class is used to define and store the updatedness of any component
- * of the synchronization architecture (i.e : to know which changes
+ * of the replication architecture (i.e : to know which changes
* it has already processed).
* </li>
* </ul>
diff --git a/opends/src/server/org/opends/server/replication/package-info.java b/opends/src/server/org/opends/server/replication/package-info.java
index bd0b285..3a79600 100644
--- a/opends/src/server/org/opends/server/replication/package-info.java
+++ b/opends/src/server/org/opends/server/replication/package-info.java
@@ -26,7 +26,6 @@
*/
/**
- * This package contains the code for the synchronization feature
- * which provides a Multi-Master replication system.
+ * This package contains the code for the Multi-Master replication.
*/
package org.opends.server.replication;
diff --git a/opends/src/server/org/opends/server/replication/plugin/ChangelogBroker.java b/opends/src/server/org/opends/server/replication/plugin/ChangelogBroker.java
index 7162149..11e817c 100644
--- a/opends/src/server/org/opends/server/replication/plugin/ChangelogBroker.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ChangelogBroker.java
@@ -30,7 +30,7 @@
import static org.opends.server.loggers.debug.DebugLogger.debugEnabled;
import static org.opends.server.loggers.debug.DebugLogger.debugInfo;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
import java.util.Collection;
@@ -56,7 +56,7 @@
import org.opends.server.replication.protocol.ProtocolSession;
import org.opends.server.replication.protocol.ServerStartMessage;
import org.opends.server.replication.protocol.SocketSession;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.replication.protocol.UpdateMessage;
import org.opends.server.replication.protocol.WindowMessage;
import org.opends.server.types.DN;
@@ -70,7 +70,7 @@
/**
- * The broker for Multimaster Synchronization.
+ * The broker for Multi-master Replication.
*/
public class ChangelogBroker implements InternalSearchListener
{
@@ -96,7 +96,7 @@
private int timeout = 0;
/**
- * The time in milliseconds between heartbeats from the synchronization
+ * The time in milliseconds between heartbeats from the replication
* server. Zero means heartbeats are off.
*/
private long heartbeatInterval = 0;
@@ -114,7 +114,7 @@
/**
- * Creates a new Changelog Broker for a particular SynchronizationDomain.
+ * Creates a new Changelog Broker for a particular ReplicationDomain.
*
* @param state The ServerState that should be used by this broker
* when negociating the session with the changelog servers.
@@ -411,7 +411,7 @@
if (heartbeatInterval > 0)
{
heartbeatMonitor =
- new HeartbeatMonitor("Synchronization Heartbeat Monitor", session,
+ new HeartbeatMonitor("Replication Heartbeat Monitor", session,
heartbeatInterval);
heartbeatMonitor.start();
}
@@ -460,7 +460,7 @@
* Publish a message to the other servers.
* @param msg the message to publish
*/
- public void publish(SynchronizationMessage msg)
+ public void publish(ReplicationMessage msg)
{
boolean done = false;
ProtocolSession failingSession = session;
@@ -496,14 +496,14 @@
* @throws SocketTimeoutException if the timeout set by setSoTimeout
* has expired
*/
- public SynchronizationMessage receive() throws SocketTimeoutException
+ public ReplicationMessage receive() throws SocketTimeoutException
{
while (shutdown == false)
{
ProtocolSession failingSession = session;
try
{
- SynchronizationMessage msg = session.receive();
+ ReplicationMessage msg = session.receive();
if (msg instanceof WindowMessage)
{
WindowMessage windowMsg = (WindowMessage) msg;
diff --git a/opends/src/server/org/opends/server/replication/plugin/ChangelogListener.java b/opends/src/server/org/opends/server/replication/plugin/ChangelogListener.java
index 98f1d03..c6a8451 100644
--- a/opends/src/server/org/opends/server/replication/plugin/ChangelogListener.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ChangelogListener.java
@@ -33,7 +33,7 @@
import org.opends.server.admin.std.server.ChangelogServerCfg;
import org.opends.server.admin.std.server.MultimasterSynchronizationProviderCfg;
import org.opends.server.config.ConfigException;
-import org.opends.server.replication.changelog.Changelog;
+import org.opends.server.replication.server.Changelog;
import org.opends.server.types.ConfigChangeResult;
import org.opends.server.types.ResultCode;
diff --git a/opends/src/server/org/opends/server/replication/plugin/FakeOperation.java b/opends/src/server/org/opends/server/replication/plugin/FakeOperation.java
index 115cff3..2e8b45e 100644
--- a/opends/src/server/org/opends/server/replication/plugin/FakeOperation.java
+++ b/opends/src/server/org/opends/server/replication/plugin/FakeOperation.java
@@ -27,7 +27,7 @@
package org.opends.server.replication.plugin;
import org.opends.server.replication.common.ChangeNumber;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.types.Modification;
@@ -65,14 +65,14 @@
}
/**
- * Generate a SynchronizationMessage from this fake operation.
- * The SynchronizationMessage is used to send the informations about
+ * Generate a ReplicationMessage from this fake operation.
+ * The ReplicationMessage is used to send the informations about
* this operation to the other servers.
*
- * @return A SynchronizationMessage that can be used to send information
+ * @return A ReplicationMessage that can be used to send information
* about this operation to remote servers.
*/
- abstract public SynchronizationMessage generateMessage();
+ abstract public ReplicationMessage generateMessage();
/**
* Add a modification to the list of modification included
diff --git a/opends/src/server/org/opends/server/replication/plugin/HeartbeatMonitor.java b/opends/src/server/org/opends/server/replication/plugin/HeartbeatMonitor.java
index 0987c81..767d197 100644
--- a/opends/src/server/org/opends/server/replication/plugin/HeartbeatMonitor.java
+++ b/opends/src/server/org/opends/server/replication/plugin/HeartbeatMonitor.java
@@ -37,7 +37,7 @@
/**
* This class implements a thread to monitor heartbeat messages from the
- * synchronization server. Each broker runs one of these threads.
+ * replication server. Each broker runs one of these threads.
*/
public class HeartbeatMonitor extends DirectoryThread
{
@@ -50,7 +50,7 @@
/**
- * The time in milliseconds between heartbeats from the synchronization
+ * The time in milliseconds between heartbeats from the replication
* server. Zero means heartbeats are off.
*/
private long heartbeatInterval;
diff --git a/opends/src/server/org/opends/server/replication/plugin/Historical.java b/opends/src/server/org/opends/server/replication/plugin/Historical.java
index a1213cc..40a27dc 100644
--- a/opends/src/server/org/opends/server/replication/plugin/Historical.java
+++ b/opends/src/server/org/opends/server/replication/plugin/Historical.java
@@ -248,7 +248,7 @@
* operation so there is no need to check the historical information
* for conflicts.
* If this is a local operation, the this code is run during
- * the pre-operation phase (TODO : should make sure that synchronization
+ * the pre-operation phase (TODO : should make sure that replication
* is always run after all other plugins)
* If this is a non-conflicting replicated operation, this code is run
* during the handleConflictResolution().
@@ -939,7 +939,7 @@
/**
* Get the Entry Unique Id from an add operation.
* This must be called after the entry uuid preop plugin (i.e no
- * sooner than the synchronization provider pre-op)
+ * sooner than the replication provider pre-op)
*
* @param op The operation
* @return The Entry Unique Id String form.
diff --git a/opends/src/server/org/opends/server/replication/plugin/ListenerThread.java b/opends/src/server/org/opends/server/replication/plugin/ListenerThread.java
index a44f245..5a05ef4 100644
--- a/opends/src/server/org/opends/server/replication/plugin/ListenerThread.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ListenerThread.java
@@ -28,7 +28,7 @@
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
import org.opends.server.api.DirectoryThread;
@@ -42,7 +42,7 @@
*/
public class ListenerThread extends DirectoryThread
{
- private SynchronizationDomain listener;
+ private ReplicationDomain listener;
private boolean shutdown = false;
/**
@@ -50,9 +50,9 @@
*
* @param listener the Plugin that created this thread
*/
- public ListenerThread(SynchronizationDomain listener)
+ public ListenerThread(ReplicationDomain listener)
{
- super("Synchronization Listener thread");
+ super("Replication Listener thread");
this.listener = listener;
}
@@ -83,7 +83,7 @@
* catch all exceptions happening in listener.receive and listener.replay
* so that the thread never dies even in case of problems.
*/
- int msgID = MSGID_EXCEPTION_RECEIVING_SYNCHRONIZATION_MESSAGE;
+ int msgID = MSGID_EXCEPTION_RECEIVING_REPLICATION_MESSAGE;
String message = getMessage(msgID, stackTraceToSingleLineString(e));
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.SEVERE_ERROR, message, msgID);
diff --git a/opends/src/server/org/opends/server/replication/plugin/ModifyFakeOperation.java b/opends/src/server/org/opends/server/replication/plugin/ModifyFakeOperation.java
index e795ab0..97c964f 100644
--- a/opends/src/server/org/opends/server/replication/plugin/ModifyFakeOperation.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ModifyFakeOperation.java
@@ -30,7 +30,7 @@
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.protocol.ModifyMsg;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.types.DN;
import org.opends.server.types.Modification;
@@ -79,7 +79,7 @@
* {@inheritDoc}
*/
@Override
- public SynchronizationMessage generateMessage()
+ public ReplicationMessage generateMessage()
{
return new ModifyMsg(super.getChangeNumber(), dn, mods, entryuuid);
}
diff --git a/opends/src/server/org/opends/server/replication/plugin/MultimasterSynchronization.java b/opends/src/server/org/opends/server/replication/plugin/MultimasterReplication.java
similarity index 86%
rename from opends/src/server/org/opends/server/replication/plugin/MultimasterSynchronization.java
rename to opends/src/server/org/opends/server/replication/plugin/MultimasterReplication.java
index 8a5365a..1662f88 100644
--- a/opends/src/server/org/opends/server/replication/plugin/MultimasterSynchronization.java
+++ b/opends/src/server/org/opends/server/replication/plugin/MultimasterReplication.java
@@ -59,17 +59,17 @@
import org.opends.server.types.ResultCode;
import org.opends.server.types.SynchronizationProviderResult;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
/**
- * This class is used to load the Synchronization code inside the JVM
- * and to trigger initialization of the synchronization.
+ * This class is used to load the Replication code inside the JVM
+ * and to trigger initialization of the replication.
*
* It also extends the SynchronizationProvider class in order to have some
- * synchronization code running during the operation process
+ * replication code running during the operation process
* as pre-op, conflictRsolution, and post-op.
*/
-public class MultimasterSynchronization
+public class MultimasterReplication
extends SynchronizationProvider<MultimasterSynchronizationProviderCfg>
implements ConfigurationAddListener<MultimasterDomainCfg>,
ConfigurationDeleteListener<MultimasterDomainCfg>,
@@ -82,8 +82,8 @@
"ds-cfg-synchronization-provider-config";
private ChangelogListener changelog = null;
- private static Map<DN, SynchronizationDomain> domains =
- new HashMap<DN, SynchronizationDomain>() ;
+ private static Map<DN, ReplicationDomain> domains =
+ new HashMap<DN, ReplicationDomain>() ;
/**
@@ -105,7 +105,7 @@
for (String name : configuration.listMultimasterDomains())
{
MultimasterDomainCfg domain = configuration.getMultimasterDomain(name);
- createNewSynchronizationDomain(domain);
+ createNewDomain(domain);
}
/*
@@ -131,7 +131,7 @@
public boolean isConfigurationAddAcceptable(
MultimasterDomainCfg configuration, List<String> unacceptableReasons)
{
- return SynchronizationDomain.isConfigurationAcceptable(
+ return ReplicationDomain.isConfigurationAcceptable(
configuration, unacceptableReasons);
}
@@ -143,7 +143,7 @@
{
try
{
- createNewSynchronizationDomain(configuration);
+ createNewDomain(configuration);
return new ConfigChangeResult(ResultCode.SUCCESS, false);
} catch (ConfigException e)
{
@@ -154,18 +154,18 @@
}
/**
- * Creates a New Synchronization domain from its configEntry, do the
+ * Creates a new domain from its configEntry, do the
* necessary initialization and starts it so that it is
* fully operational when this method returns.
* @param configuration The entry whith the configuration of this domain.
* @throws ConfigException When the configuration is not valid.
*/
- private void createNewSynchronizationDomain(
+ private void createNewDomain(
MultimasterDomainCfg configuration)
throws ConfigException
{
- SynchronizationDomain domain;
- domain = new SynchronizationDomain(configuration);
+ ReplicationDomain domain;
+ domain = new ReplicationDomain(configuration);
domains.put(domain.getBaseDN(), domain);
domain.start();
}
@@ -218,7 +218,7 @@
public SynchronizationProviderResult handleConflictResolution(
ModifyOperation modifyOperation)
{
- SynchronizationDomain domain =
+ ReplicationDomain domain =
findDomain(modifyOperation.getEntryDN(), modifyOperation);
if (domain == null)
return new SynchronizationProviderResult(true);
@@ -233,7 +233,7 @@
public SynchronizationProviderResult handleConflictResolution(
AddOperation addOperation) throws DirectoryException
{
- SynchronizationDomain domain =
+ ReplicationDomain domain =
findDomain(addOperation.getEntryDN(), addOperation);
if (domain == null)
return new SynchronizationProviderResult(true);
@@ -248,7 +248,7 @@
public SynchronizationProviderResult handleConflictResolution(
DeleteOperation deleteOperation) throws DirectoryException
{
- SynchronizationDomain domain =
+ ReplicationDomain domain =
findDomain(deleteOperation.getEntryDN(), deleteOperation);
if (domain == null)
return new SynchronizationProviderResult(true);
@@ -263,7 +263,7 @@
public SynchronizationProviderResult handleConflictResolution(
ModifyDNOperation modifyDNOperation) throws DirectoryException
{
- SynchronizationDomain domain =
+ ReplicationDomain domain =
findDomain(modifyDNOperation.getEntryDN(), modifyDNOperation);
if (domain == null)
return new SynchronizationProviderResult(true);
@@ -279,7 +279,7 @@
doPreOperation(ModifyOperation modifyOperation)
{
DN operationDN = modifyOperation.getEntryDN();
- SynchronizationDomain domain = findDomain(operationDN, modifyOperation);
+ ReplicationDomain domain = findDomain(operationDN, modifyOperation);
if ((domain == null) || (!domain.solveConflict()))
return new SynchronizationProviderResult(true);
@@ -324,7 +324,7 @@
@Override
public SynchronizationProviderResult doPreOperation(AddOperation addOperation)
{
- SynchronizationDomain domain =
+ ReplicationDomain domain =
findDomain(addOperation.getEntryDN(), addOperation);
if (domain == null)
return new SynchronizationProviderResult(true);
@@ -342,8 +342,8 @@
@Override
public void finalizeSynchronizationProvider()
{
- // shutdown all the Synchronization domains
- for (SynchronizationDomain domain : domains.values())
+ // shutdown all the domains
+ for (ReplicationDomain domain : domains.values())
{
domain.shutdown();
}
@@ -359,23 +359,23 @@
}
/**
- * Finds the Synchronization domain for a given DN.
+ * Finds the domain for a given DN.
*
* @param dn The DN for which the domain must be returned.
* @param op An optional operation for which the check is done.
* Can be null is the request has no associated operation.
- * @return The Synchronization domain for this DN.
+ * @return The domain for this DN.
*/
- public static SynchronizationDomain findDomain(DN dn, Operation op)
+ public static ReplicationDomain findDomain(DN dn, Operation op)
{
/*
- * Don't run the special synchronization code on Operation that are
+ * Don't run the special replication code on Operation that are
* specifically marked as don't synchronize.
*/
if ((op != null) && op.dontSynchronize())
return null;
- SynchronizationDomain domain = null;
+ ReplicationDomain domain = null;
DN temp = dn;
do
{
@@ -398,7 +398,7 @@
*/
private void genericPostOperation(Operation operation, DN dn)
{
- SynchronizationDomain domain = findDomain(dn, operation);
+ ReplicationDomain domain = findDomain(dn, operation);
if (domain == null)
return;
@@ -411,7 +411,7 @@
* This method is called whenever the server detects a modification
* of the schema done by directly modifying the backing files
* of the schema backend.
- * Call the schema Synchronization Domain if it exists.
+ * Call the schema Domain if it exists.
*
* @param modifications The list of modifications that was
* applied to the schema.
@@ -420,7 +420,7 @@
@Override
public void processSchemaChange(List<Modification> modifications)
{
- SynchronizationDomain domain =
+ ReplicationDomain domain =
findDomain(DirectoryServer.getSchemaDN(), null);
if (domain != null)
domain.synchronizeModifications(modifications);
@@ -433,7 +433,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.backupStart();
}
@@ -447,7 +447,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.backupEnd();
}
@@ -460,7 +460,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.disable();
}
@@ -474,7 +474,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.enable();
}
@@ -487,7 +487,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.disable();
}
@@ -501,7 +501,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.enable();
}
@@ -514,7 +514,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.backupStart();
}
@@ -528,7 +528,7 @@
{
for (DN dn : backend.getBaseDNs())
{
- SynchronizationDomain domain = findDomain(dn, null);
+ ReplicationDomain domain = findDomain(dn, null);
if (domain != null)
domain.backupEnd();
}
@@ -541,7 +541,7 @@
MultimasterDomainCfg configuration)
{
DN dn = configuration.getSynchronizationDN();
- SynchronizationDomain domain = domains.remove(dn);
+ ReplicationDomain domain = domains.remove(dn);
if (domain != null)
domain.shutdown();
diff --git a/opends/src/server/org/opends/server/replication/plugin/PendingChange.java b/opends/src/server/org/opends/server/replication/plugin/PendingChange.java
index 9eba25a..bb42a60 100644
--- a/opends/src/server/org/opends/server/replication/plugin/PendingChange.java
+++ b/opends/src/server/org/opends/server/replication/plugin/PendingChange.java
@@ -86,7 +86,7 @@
/**
* Get the message associated to this PendingChange.
- * @return the message if operation was a synchronization operation
+ * @return the message if operation was a replication operation
* null if the operation was a local operation
*/
public UpdateMessage getMsg()
diff --git a/opends/src/server/org/opends/server/replication/plugin/PersistentServerState.java b/opends/src/server/org/opends/server/replication/plugin/PersistentServerState.java
index 4ee6d09..64251e2 100644
--- a/opends/src/server/org/opends/server/replication/plugin/PersistentServerState.java
+++ b/opends/src/server/org/opends/server/replication/plugin/PersistentServerState.java
@@ -28,7 +28,7 @@
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import java.util.ArrayList;
import java.util.LinkedHashSet;
@@ -76,7 +76,7 @@
/**
* The attribute name used to store the state in the backend.
*/
- protected static final String SYNCHRONIZATION_STATE = "ds-sync-state";
+ protected static final String REPLICATION_STATE = "ds-sync-state";
/**
* create a new ServerState.
@@ -139,7 +139,7 @@
* save the ServerState
*/
LinkedHashSet<String> attributes = new LinkedHashSet<String>(1);
- attributes.add(SYNCHRONIZATION_STATE);
+ attributes.add(REPLICATION_STATE);
InternalSearchOperation search = conn.processSearch(asn1BaseDn,
SearchScope.BASE_OBJECT,
DereferencePolicy.DEREF_ALWAYS, 0, 0, false,
@@ -160,14 +160,14 @@
if (search.getResultCode() == ResultCode.SUCCESS)
{
/*
- * Read the serverState from the SYNCHRONIZATION_STATE attribute
+ * Read the serverState from the REPLICATION_STATE attribute
*/
LinkedList<SearchResultEntry> result = search.getSearchEntries();
resultEntry = result.getFirst();
if (resultEntry != null)
{
AttributeType synchronizationStateType =
- DirectoryServer.getAttributeType(SYNCHRONIZATION_STATE);
+ DirectoryServer.getAttributeType(REPLICATION_STATE);
List<Attribute> attrs =
resultEntry.getAttribute(synchronizationStateType);
if (attrs != null)
@@ -213,7 +213,7 @@
return ResultCode.SUCCESS;
LDAPAttribute attr =
- new LDAPAttribute(SYNCHRONIZATION_STATE, values);
+ new LDAPAttribute(REPLICATION_STATE, values);
LDAPModification mod = new LDAPModification(ModificationType.REPLACE, attr);
ArrayList<RawModification> mods = new ArrayList<RawModification>(1);
mods.add(mod);
diff --git a/opends/src/server/org/opends/server/replication/plugin/SynchroLDIFInputStream.java b/opends/src/server/org/opends/server/replication/plugin/ReplLDIFInputStream.java
similarity index 90%
rename from opends/src/server/org/opends/server/replication/plugin/SynchroLDIFInputStream.java
rename to opends/src/server/org/opends/server/replication/plugin/ReplLDIFInputStream.java
index 9252bb4..d886480 100644
--- a/opends/src/server/org/opends/server/replication/plugin/SynchroLDIFInputStream.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ReplLDIFInputStream.java
@@ -36,22 +36,22 @@
* This class creates an input stream that can be used to read entries generated
* by SynchroLDIF as if they were being read from another source like a file.
*/
-public class SynchroLDIFInputStream
+public class ReplLDIFInputStream
extends InputStream
{
// Indicates whether this input stream has been closed.
private boolean closed;
- // The synchronization domain associated to this import.
- SynchronizationDomain domain;
+ // The domain associated to this import.
+ ReplicationDomain domain;
/**
- * Creates a new SynchroLDIFInputStream that will import entries
+ * Creates a new ReplLDIFInputStream that will import entries
* for a synchronzation domain.
*
- * @param domain The synchronization domain
+ * @param domain The replication domain
*/
- public SynchroLDIFInputStream(SynchronizationDomain domain)
+ public ReplLDIFInputStream(ReplicationDomain domain)
{
this.domain = domain;
closed = false;
@@ -115,7 +115,7 @@
throws IOException
{
// This method is not supposed to be called to make an LDIF import
- // for synchronization.
+ // for replication.
throw new IOException("Not implemented");
}
}
diff --git a/opends/src/server/org/opends/server/replication/plugin/SynchroLDIFOutputStream.java b/opends/src/server/org/opends/server/replication/plugin/ReplLDIFOutputStream.java
similarity index 90%
rename from opends/src/server/org/opends/server/replication/plugin/SynchroLDIFOutputStream.java
rename to opends/src/server/org/opends/server/replication/plugin/ReplLDIFOutputStream.java
index 2516a7e..1f0e567 100644
--- a/opends/src/server/org/opends/server/replication/plugin/SynchroLDIFOutputStream.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ReplLDIFOutputStream.java
@@ -34,19 +34,19 @@
* This class creates an output stream that can be used to export entries
* to a synchonization domain.
*/
-public class SynchroLDIFOutputStream
+public class ReplLDIFOutputStream
extends OutputStream
{
- SynchronizationDomain domain;
+ ReplicationDomain domain;
String entryBuffer = "";
/**
- * Creates a new SynchroLDIFOutputStream related to a synchronization
+ * Creates a new ReplLDIFOutputStream related to a replication
* domain.
*
- * @param domain The synchronization domain
+ * @param domain The replication domain
*/
- public SynchroLDIFOutputStream(SynchronizationDomain domain)
+ public ReplLDIFOutputStream(ReplicationDomain domain)
{
this.domain = domain;
}
diff --git a/opends/src/server/org/opends/server/replication/plugin/SynchronizationDomain.java b/opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java
similarity index 95%
rename from opends/src/server/org/opends/server/replication/plugin/SynchronizationDomain.java
rename to opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java
index 3ff932c..24ef2b3 100644
--- a/opends/src/server/org/opends/server/replication/plugin/SynchronizationDomain.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java
@@ -36,7 +36,7 @@
import static org.opends.server.messages.ConfigMessages.*;
import static org.opends.server.messages.MessageHandler.getMessage;
import static org.opends.server.messages.ToolMessages.*;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.replication.plugin.Historical.ENTRYUIDNAME;
import static org.opends.server.replication.protocol.OperationContext.*;
import static org.opends.server.util.StaticUtils.createEntry;
@@ -62,7 +62,6 @@
import org.opends.server.backends.jeb.BackendImpl;
import org.opends.server.backends.task.Task;
import org.opends.server.backends.task.TaskState;
-import org.opends.server.config.ConfigAttribute;
import org.opends.server.config.ConfigEntry;
import org.opends.server.config.ConfigException;
import org.opends.server.config.DNConfigAttribute;
@@ -92,7 +91,7 @@
import org.opends.server.replication.protocol.ModifyDnContext;
import org.opends.server.replication.protocol.OperationContext;
import org.opends.server.replication.protocol.RoutableMessage;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.replication.protocol.UpdateMessage;
import org.opends.server.tasks.InitializeTargetTask;
import org.opends.server.tasks.InitializeTask;
@@ -118,16 +117,16 @@
/**
* This class implements the bulk part of the.of the Directory Server side
- * of the synchronization code.
+ * of the replication code.
* It contains the root method for publishing a change,
* processing a change received from the changelog service,
* handle conflict resolution,
* handle protocol messages from the changelog server.
*/
-public class SynchronizationDomain extends DirectoryThread
+public class ReplicationDomain extends DirectoryThread
implements ConfigurationChangeListener<MultimasterDomainCfg>
{
- private SynchronizationMonitor monitor;
+ private ReplicationMonitor monitor;
private ChangeNumberGenerator changeNumberGenerator;
private ChangelogBroker broker;
@@ -151,7 +150,7 @@
private int maxSendDelay = 0;
/**
- * The time in milliseconds between heartbeats from the synchronization
+ * The time in milliseconds between heartbeats from the replication
* server. Zero means heartbeats are off.
*/
private long heartbeatInterval = 0;
@@ -166,7 +165,7 @@
// The task that initiated the operation.
Task initializeTask;
// The input stream for the import
- SynchroLDIFInputStream ldifImportInputStream = null;
+ ReplLDIFInputStream ldifImportInputStream = null;
// The target in the case of an export
short exportTarget = RoutableMessage.UNKNOWN_SERVER;
// The source in the case of an import
@@ -253,9 +252,6 @@
private DN baseDN;
- private List<ConfigAttribute> configAttributes =
- new ArrayList<ConfigAttribute>();
-
private boolean shutdown = false;
private InternalClientConnection conn =
@@ -270,15 +266,15 @@
/**
- * Creates a new SynchronizationDomain using configuration from configEntry.
+ * Creates a new ReplicationDomain using configuration from configEntry.
*
- * @param configuration The configuration of this SynchronizationDomain.
+ * @param configuration The configuration of this ReplicationDomain.
* @throws ConfigException In case of invalid configuration.
*/
- public SynchronizationDomain(MultimasterDomainCfg configuration)
+ public ReplicationDomain(MultimasterDomainCfg configuration)
throws ConfigException
{
- super("Synchronization flush");
+ super("replication flush");
// Read the configuration parameters.
changelogServers = configuration.getChangelogServer();
@@ -314,15 +310,15 @@
state = new PersistentServerState(baseDN);
/*
- * Create a Synchronization monitor object responsible for publishing
+ * Create a replication monitor object responsible for publishing
* monitoring information below cn=monitor.
*/
- monitor = new SynchronizationMonitor(this);
+ monitor = new ReplicationMonitor(this);
DirectoryServer.registerMonitorProvider(monitor);
/*
* ChangeNumberGenerator is used to create new unique ChangeNumbers
- * for each operation done on the synchronization domain.
+ * for each operation done on the replication domain.
*/
changeNumberGenerator = new ChangeNumberGenerator(serverId, state);
@@ -358,9 +354,9 @@
/**
- * Returns the base DN of this SynchronizationDomain.
+ * Returns the base DN of this ReplicationDomain.
*
- * @return The base DN of this SynchronizationDomain
+ * @return The base DN of this ReplicationDomain
*/
public DN getBaseDN()
{
@@ -384,7 +380,7 @@
if (ctx != null)
{
/*
- * This is a synchronization operation
+ * This is a replication operation
* Check that the modified entry has the same entryuuid
* has was in the original message.
*/
@@ -409,8 +405,8 @@
}
else
{
- // There is no Synchronization context attached to the operation
- // so this is not a synchronization operation.
+ // There is no replication context attached to the operation
+ // so this is not a replication operation.
ChangeNumber changeNumber = generateChangeNumber(deleteOperation);
String modifiedEntryUUID = Historical.getEntryUuid(deletedEntry);
ctx = new DeleteContext(changeNumber, modifiedEntryUUID);
@@ -460,7 +456,7 @@
&& (!parentDnFromCtx.equals(parentDnFromEntryDn)))
{
// parentEntry has been renamed
- // Synchronization name conflict resolution is expected to fix that
+ // replication name conflict resolution is expected to fix that
// later in the flow
addOperation.setResultCode(ResultCode.NO_SUCH_OBJECT);
return new SynchronizationProviderResult(false);
@@ -485,7 +481,7 @@
if (ctx != null)
{
/*
- * This is a synchronization operation
+ * This is a replication operation
* Check that the modified entry has the same entryuuid
* as was in the original message.
*/
@@ -524,8 +520,8 @@
}
else
{
- // There is no Synchronization context attached to the operation
- // so this is not a synchronization operation.
+ // There is no replication context attached to the operation
+ // so this is not a replication operation.
ChangeNumber changeNumber = generateChangeNumber(modifyDNOperation);
String newParentId = null;
if (modifyDNOperation.getNewSuperior() != null)
@@ -557,8 +553,8 @@
Entry modifiedEntry = modifyOperation.getModifiedEntry();
if (ctx == null)
{
- // There is no Synchronization context attached to the operation
- // so this is not a synchronization operation.
+ // There is no replication context attached to the operation
+ // so this is not a replication operation.
ChangeNumber changeNumber = generateChangeNumber(modifyOperation);
String modifiedEntryUUID = Historical.getEntryUuid(modifiedEntry);
if (modifiedEntryUUID == null)
@@ -614,7 +610,7 @@
/**
* The preOperation phase for the add Operation.
- * Its job is to generate the Synchronization context associated to the
+ * Its job is to generate the replication context associated to the
* operation. It is necessary to do it in this phase because contrary to
* the other operations, the entry uid is not set when the handleConflict
* phase is called.
@@ -642,7 +638,7 @@
UpdateMessage update = null;
while (update == null)
{
- SynchronizationMessage msg;
+ ReplicationMessage msg;
try
{
msg = broker.receive();
@@ -784,7 +780,7 @@
}
UpdateMessage msg = null;
- // Note that a failed non-synchronization operation might not have a change
+ // Note that a failed non-replication operation might not have a change
// number.
ChangeNumber curChangeNumber = OperationContext.getChangeNumber(op);
@@ -792,7 +788,7 @@
if ((result == ResultCode.SUCCESS) && (!op.isSynchronizationOperation()))
{
- // Generate a synchronization message for a successful non-synchronization
+ // Generate a replication message for a successful non-replication
// operation.
msg = UpdateMessage.generateMsg(op, isAssured);
@@ -847,7 +843,7 @@
}
else if (!op.isSynchronizationOperation())
{
- // Remove an unsuccessful non-synchronization operation from the pending
+ // Remove an unsuccessful non-replication operation from the pending
// changes list.
if (curChangeNumber != null)
{
@@ -878,7 +874,7 @@
}
/**
- * get the number of updates received by the synchronization plugin.
+ * get the number of updates received by the replication plugin.
*
* @return the number of updates received
*/
@@ -888,7 +884,7 @@
}
/**
- * Get the number of updates sent by the synchronization plugin.
+ * Get the number of updates sent by the replication plugin.
*
* @return the number of updates sent
*/
@@ -916,9 +912,9 @@
}
/**
- * get the number of updates replayed by the synchronization.
+ * get the number of updates replayed by the replication.
*
- * @return The number of updates replayed by the synchronization
+ * @return The number of updates replayed by the replication
*/
public int getNumProcessedUpdates()
{
@@ -926,7 +922,7 @@
}
/**
- * get the number of updates replayed successfully by the synchronization.
+ * get the number of updates replayed successfully by the replication.
*
* @return The number of updates replayed successfully
*/
@@ -1012,7 +1008,7 @@
}
/**
- * Shutdown this SynchronizationDomain.
+ * Shutdown this ReplicationDomain.
*/
public void shutdown()
{
@@ -1684,8 +1680,8 @@
}
/**
- * Get the number of times the synchronization connection was lost.
- * @return The number of times the synchronization connection was lost.
+ * Get the number of times the replication connection was lost.
+ * @return The number of times the replication connection was lost.
*/
public int getNumLostConnections()
{
@@ -1703,8 +1699,8 @@
}
/**
- * Disable the Synchronization on this domain.
- * The session to the Synchronization server will be stopped.
+ * Disable the replication on this domain.
+ * The session to the replication server will be stopped.
* The domain will not be destroyed but call to the pre-operation
* methods will result in failure.
* The listener threads will be destroyed.
@@ -1725,7 +1721,7 @@
/**
* Enable back the domain after a previous disable.
- * The domain will connect back to a Synchronization Server and
+ * The domain will connect back to a replication Server and
* will recreate threads to listen for messages from the Sycnhronization
* server.
* The ServerState will also be read again from the local database.
@@ -1774,13 +1770,13 @@
/**
* Receives bytes related to an entry in the context of an import to
- * initialize the domain (called by SynchronizationDomainLDIFInputStream).
+ * initialize the domain (called by ReplLDIFInputStream).
*
* @return The bytes. Null when the Done or Err message has been received
*/
public byte[] receiveEntryBytes()
{
- SynchronizationMessage msg;
+ ReplicationMessage msg;
while (true)
{
try
@@ -1926,7 +1922,7 @@
int msgID = MSGID_UNKNOWN_TYPE;
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "SynchronizationDomain/ " + message, msgID);
+ "ReplicationDomain/ " + message, msgID);
}
}
@@ -1966,7 +1962,7 @@
ResultCode.OTHER, message, msgID, null);
}
- SynchroLDIFOutputStream os = new SynchroLDIFOutputStream(this);
+ ReplLDIFOutputStream os = new ReplLDIFOutputStream(this);
LDIFExportConfig exportConfig = new LDIFExportConfig(os);
@@ -2604,7 +2600,7 @@
preBackendImport(this.backend, this.backendConfigEntry);
DN[] baseDNs = {baseDN};
- ieContext.ldifImportInputStream = new SynchroLDIFInputStream(this);
+ ieContext.ldifImportInputStream = new ReplLDIFInputStream(this);
importConfig =
new LDIFImportConfig(ieContext.ldifImportInputStream);
importConfig.setIncludeBranches(this.branches);
@@ -2679,23 +2675,23 @@
}
/**
- * Retrieves a synchronization domain based on the baseDN.
+ * Retrieves a replication domain based on the baseDN.
*
* @param baseDN The baseDN of the domain to retrieve
* @return The domain retrieved
* @throws DirectoryException When an error occured.
*/
- public static SynchronizationDomain retrievesSynchronizationDomain(DN baseDN)
+ public static ReplicationDomain retrievesReplicationDomain(DN baseDN)
throws DirectoryException
{
- SynchronizationDomain synchronizationDomain = null;
+ ReplicationDomain replicationDomain = null;
// Retrieves the domain
DirectoryServer.getSynchronizationProviders();
for (SynchronizationProvider provider :
DirectoryServer.getSynchronizationProviders())
{
- if (!( provider instanceof MultimasterSynchronization))
+ if (!( provider instanceof MultimasterReplication))
{
int msgID = MSGID_INVALID_PROVIDER;
String message = getMessage(msgID);
@@ -2703,9 +2699,9 @@
message, msgID);
}
- // From the domainDN retrieves the synchronization domain
- SynchronizationDomain sdomain =
- MultimasterSynchronization.findDomain(baseDN, null);
+ // From the domainDN retrieves the replication domain
+ ReplicationDomain sdomain =
+ MultimasterReplication.findDomain(baseDN, null);
if (sdomain == null)
{
int msgID = MSGID_NO_MATCHING_DOMAIN;
@@ -2714,7 +2710,7 @@
message, msgID);
}
- if (synchronizationDomain != null)
+ if (replicationDomain != null)
{
// Should never happen
int msgID = MSGID_MULTIPLE_MATCHING_DOMAIN;
@@ -2722,9 +2718,9 @@
throw new DirectoryException(ResultCode.OTHER,
message, msgID);
}
- synchronizationDomain = sdomain;
+ replicationDomain = sdomain;
}
- return synchronizationDomain;
+ return replicationDomain;
}
/**
@@ -2791,7 +2787,7 @@
// Check that there is not already a domain with the same DN
// TODO : Check that the server id is a short
DN dn = configuration.getSynchronizationDN();
- if (MultimasterSynchronization.findDomain(dn,null) != null)
+ if (MultimasterReplication.findDomain(dn,null) != null)
{
String message = getMessage(MSGID_SYNC_INVALID_DN, dn.toString());
unacceptableReasons.add(message);
diff --git a/opends/src/server/org/opends/server/replication/plugin/SynchronizationMonitor.java b/opends/src/server/org/opends/server/replication/plugin/ReplicationMonitor.java
similarity index 93%
rename from opends/src/server/org/opends/server/replication/plugin/SynchronizationMonitor.java
rename to opends/src/server/org/opends/server/replication/plugin/ReplicationMonitor.java
index be8d9a2..cff5d05 100644
--- a/opends/src/server/org/opends/server/replication/plugin/SynchronizationMonitor.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ReplicationMonitor.java
@@ -37,19 +37,19 @@
import org.opends.server.types.AttributeValue;
/**
- * Class used to generate monitoring information for the Synchronization.
+ * Class used to generate monitoring information for the replication.
*/
-public class SynchronizationMonitor extends MonitorProvider
+public class ReplicationMonitor extends MonitorProvider
{
- private SynchronizationDomain domain; // the synchronization plugin
+ private ReplicationDomain domain; // the replication plugin
/**
- * Create a new Synchronization monitor.
+ * Create a new replication monitor.
* @param domain the plugin which created the monitor
*/
- public SynchronizationMonitor(SynchronizationDomain domain)
+ public ReplicationMonitor(ReplicationDomain domain)
{
- super("Synchronization monitor " + domain.getBaseDN().toString());
+ super("Replication monitor " + domain.getBaseDN().toString());
this.domain = domain;
}
@@ -73,7 +73,7 @@
@Override
public String getMonitorInstanceName()
{
- return "synchronization plugin " + domain.getBaseDN().toString();
+ return "Replication plugin " + domain.getBaseDN().toString();
}
/**
diff --git a/opends/src/server/org/opends/server/replication/plugin/package-info.java b/opends/src/server/org/opends/server/replication/plugin/package-info.java
index 297e465..d549149 100644
--- a/opends/src/server/org/opends/server/replication/plugin/package-info.java
+++ b/opends/src/server/org/opends/server/replication/plugin/package-info.java
@@ -26,21 +26,21 @@
*/
/**
- * This package contains the part of the Multimaster
- * synchronization code that works on the Directory Server side.
+ * This package contains the part of the Multi-master
+ * replication code that works on the Directory Server side.
* <br>
* The main classes of this core are :
* <ul>
* <li>
- * <A HREF="MultimasterSynchronization.html"><B>MultimasterSynchronization
+ * <A HREF="MultimasterReplication.html"><B>MultimasterReplication
* </B></A>contains the synchronization provider
* code and more generally all the code that makes the glue between the core
- * server and the synchronization code.
+ * server and the replication code.
* </li>
* <li>
- * <A HREF="SynchronizationDomain.html"><B>SynchronizationDomain</B></A>
+ * <A HREF="ReplicationDomain.html"><B>ReplicationDomain</B></A>
* contains the bulk of the Directory Server side of the
- * synchronization code. Most notably it contains the root method for
+ * replication code. Most notably it contains the root method for
* publishing a change, processing a change received from the changelog
* service, handle conflict resolution, handle protocol messages from the
* changelog server.
diff --git a/opends/src/server/org/opends/server/replication/protocol/AckMessage.java b/opends/src/server/org/opends/server/replication/protocol/AckMessage.java
index 9cc8e83..da71160 100644
--- a/opends/src/server/org/opends/server/replication/protocol/AckMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/AckMessage.java
@@ -34,7 +34,7 @@
/**
* Used to send acks between LDAP and changelog servers.
*/
-public class AckMessage extends SynchronizationMessage
+public class AckMessage extends ReplicationMessage
{
// ChangeNumber of the update that was acked.
private ChangeNumber changeNumber;
diff --git a/opends/src/server/org/opends/server/replication/protocol/AddContext.java b/opends/src/server/org/opends/server/replication/protocol/AddContext.java
index 43e0183..abaf9cc 100644
--- a/opends/src/server/org/opends/server/replication/protocol/AddContext.java
+++ b/opends/src/server/org/opends/server/replication/protocol/AddContext.java
@@ -29,7 +29,7 @@
import org.opends.server.replication.common.ChangeNumber;
/**
- * This class describe the Synchronization contexte that is attached to
+ * This class describe the contexte that is attached to
* Add Operation.
*/
public class AddContext extends OperationContext
diff --git a/opends/src/server/org/opends/server/replication/protocol/ChangelogStartMessage.java b/opends/src/server/org/opends/server/replication/protocol/ChangelogStartMessage.java
index 3853c92..e39f8a2 100644
--- a/opends/src/server/org/opends/server/replication/protocol/ChangelogStartMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/ChangelogStartMessage.java
@@ -37,7 +37,7 @@
/**
* Message sent by a changelog server to another changelog server at Startup.
*/
-public class ChangelogStartMessage extends SynchronizationMessage implements
+public class ChangelogStartMessage extends ReplicationMessage implements
Serializable
{
private static final long serialVersionUID = -5871385537169856856L;
diff --git a/opends/src/server/org/opends/server/replication/protocol/DoneMessage.java b/opends/src/server/org/opends/server/replication/protocol/DoneMessage.java
index 741558e..2732c99 100644
--- a/opends/src/server/org/opends/server/replication/protocol/DoneMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/DoneMessage.java
@@ -31,7 +31,7 @@
import java.util.zip.DataFormatException;
/**
- * This message is part of the synchronization protocol.
+ * This message is part of the replication protocol.
* This message is sent by a server to one or several other servers after the
* last entry sent in the context of a total update and signals to the server
* that receives it that the export is now finished.
diff --git a/opends/src/server/org/opends/server/replication/protocol/EntryMessage.java b/opends/src/server/org/opends/server/replication/protocol/EntryMessage.java
index 4c2b8d7..f47fe2d 100644
--- a/opends/src/server/org/opends/server/replication/protocol/EntryMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/EntryMessage.java
@@ -31,7 +31,7 @@
import java.util.zip.DataFormatException;
/**
- * This message is part of the synchronization protocol.
+ * This message is part of the replication protocol.
* This message is sent by a server to one or several other servers and
* contain one entry to be sent over the protocol in the context of
* an import/export over the protocol.
diff --git a/opends/src/server/org/opends/server/replication/protocol/ErrorMessage.java b/opends/src/server/org/opends/server/replication/protocol/ErrorMessage.java
index e530ee7..9f08305 100644
--- a/opends/src/server/org/opends/server/replication/protocol/ErrorMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/ErrorMessage.java
@@ -31,7 +31,7 @@
import java.util.zip.DataFormatException;
/**
- * This message is part of the synchronization protocol.
+ * This message is part of the replication protocol.
* This message is sent by a server or a changelog server when an error
* is detected in the context of a total update.
*/
diff --git a/opends/src/server/org/opends/server/replication/protocol/HeartbeatMessage.java b/opends/src/server/org/opends/server/replication/protocol/HeartbeatMessage.java
index 19bd4ff..1729a63 100644
--- a/opends/src/server/org/opends/server/replication/protocol/HeartbeatMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/HeartbeatMessage.java
@@ -30,12 +30,12 @@
import java.util.zip.DataFormatException;
/**
- * This message is sent at regular intervals by the synchronization server
+ * This message is sent at regular intervals by the replication server
* when it is sending no other messages. It allows the directory server to
* detect a problem sooner when a synchronization server has crashed or has
* been isolated from the network.
*/
-public class HeartbeatMessage extends SynchronizationMessage
+public class HeartbeatMessage extends ReplicationMessage
{
/**
* Create a new HeartbeatMessage.
diff --git a/opends/src/server/org/opends/server/replication/protocol/HeartbeatThread.java b/opends/src/server/org/opends/server/replication/protocol/HeartbeatThread.java
index ca45687..651bee5 100644
--- a/opends/src/server/org/opends/server/replication/protocol/HeartbeatThread.java
+++ b/opends/src/server/org/opends/server/replication/protocol/HeartbeatThread.java
@@ -36,7 +36,7 @@
/**
* This thread publishes a heartbeat message on a given protocol session at
- * regular intervals when there are no other synchronization messages being
+ * regular intervals when there are no other replication messages being
* published.
*/
public class HeartbeatThread extends DirectoryThread
diff --git a/opends/src/server/org/opends/server/replication/protocol/InitializeRequestMessage.java b/opends/src/server/org/opends/server/replication/protocol/InitializeRequestMessage.java
index a0c5246..ce04bea 100644
--- a/opends/src/server/org/opends/server/replication/protocol/InitializeRequestMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/InitializeRequestMessage.java
@@ -34,7 +34,7 @@
import org.opends.server.types.DirectoryException;
/**
- * This message is part of the synchronization protocol.
+ * This message is part of the replication protocol.
* This message is sent by a server to another server in order to
* request this other server to do an export to the server sender
* of this message.
@@ -49,7 +49,7 @@
/**
* Creates a InitializeRequestMessage message.
*
- * @param baseDn The base DN of the synchronization domain.
+ * @param baseDn The base DN of the replication domain.
* @param destination destination of this message
* @param senderID serverID of the server that will send this message
*/
diff --git a/opends/src/server/org/opends/server/replication/protocol/InitializeTargetMessage.java b/opends/src/server/org/opends/server/replication/protocol/InitializeTargetMessage.java
index ae211f3..d9811ab 100644
--- a/opends/src/server/org/opends/server/replication/protocol/InitializeTargetMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/InitializeTargetMessage.java
@@ -34,7 +34,7 @@
import org.opends.server.types.DirectoryException;
/**
- * This message is part of the synchronization protocol.
+ * This message is part of the replication protocol.
* This message is sent by a server to one or several servers as the
* first message of an export, before sending the entries.
*/
diff --git a/opends/src/server/org/opends/server/replication/protocol/ModifyContext.java b/opends/src/server/org/opends/server/replication/protocol/ModifyContext.java
index 05bbd9a..5a6f1ff 100644
--- a/opends/src/server/org/opends/server/replication/protocol/ModifyContext.java
+++ b/opends/src/server/org/opends/server/replication/protocol/ModifyContext.java
@@ -29,7 +29,7 @@
import org.opends.server.replication.common.ChangeNumber;
/**
- * This class describe the synchronization context that is attached to
+ * This class describe the replication context that is attached to
* Modify operation.
*/
public class ModifyContext extends OperationContext
diff --git a/opends/src/server/org/opends/server/replication/protocol/ModifyDnContext.java b/opends/src/server/org/opends/server/replication/protocol/ModifyDnContext.java
index 19e3d84..8697d40 100644
--- a/opends/src/server/org/opends/server/replication/protocol/ModifyDnContext.java
+++ b/opends/src/server/org/opends/server/replication/protocol/ModifyDnContext.java
@@ -29,7 +29,7 @@
import org.opends.server.replication.common.ChangeNumber;
/**
- * This class describe the synchronization context that is attached to
+ * This class describe the replication context that is attached to
* ModifyDN operation.
*/
public class ModifyDnContext extends OperationContext
diff --git a/opends/src/server/org/opends/server/replication/protocol/OperationContext.java b/opends/src/server/org/opends/server/replication/protocol/OperationContext.java
index 1487952..78e96e9 100644
--- a/opends/src/server/org/opends/server/replication/protocol/OperationContext.java
+++ b/opends/src/server/org/opends/server/replication/protocol/OperationContext.java
@@ -30,7 +30,7 @@
import org.opends.server.types.Operation;
/**
- * This class describe the Synchronization context that is attached
+ * This class describe the replication context that is attached
* to each Operation using the SYNCHROCONTEXT key.
*/
public abstract class OperationContext
@@ -38,7 +38,7 @@
/**
* The identifier used to attach the context to operations.
*/
- public static final String SYNCHROCONTEXT = "synchronizationContext";
+ public static final String SYNCHROCONTEXT = "replicationContext";
/**
* The change Number of the Operation.
diff --git a/opends/src/server/org/opends/server/replication/protocol/ProtocolSession.java b/opends/src/server/org/opends/server/replication/protocol/ProtocolSession.java
index 7cbac4a..36fa680 100644
--- a/opends/src/server/org/opends/server/replication/protocol/ProtocolSession.java
+++ b/opends/src/server/org/opends/server/replication/protocol/ProtocolSession.java
@@ -32,11 +32,11 @@
/**
* The ProtocolSession interface should be implemented by a class that
- * implement the send/reception part of the Multimaster synchronization
+ * implement the send/reception part of the Multi-master replication
* protocol.
*
* This interface is designed to make easy the move from one format
- * of the SynchronizationMessage on the wire to another format.
+ * of the ReplicationMessage on the wire to another format.
*/
public interface ProtocolSession
{
@@ -50,35 +50,35 @@
public abstract void close() throws IOException;
/**
- * This method is called when a SynchronizationMessage must be sent to
+ * This method is called when a ReplicationMessage must be sent to
* the remote entity.
*
* It can be called by several threads and must implement appropriate
- * synchronization (typically, this method or a part of it should be
+ * replication (typically, this method or a part of it should be
* synchronized).
*
- * @param msg The SynchronizationMessage that must be sent.
+ * @param msg The ReplicationMessage that must be sent.
* @throws IOException If an IO error happen during the publish process.
*/
- public abstract void publish(SynchronizationMessage msg)
+ public abstract void publish(ReplicationMessage msg)
throws IOException;
/**
- * Attempt to receive a SynchronizationMessage.
+ * Attempt to receive a ReplicationMessage.
* This method should block the calling thread until a
- * SynchronizationMessage is available or until an error condition.
+ * ReplicationMessage is available or until an error condition.
*
* This method can only be called by a single thread and therefore does not
- * neet to implement any synchronization.
+ * neet to implement any replication.
*
- * @return The SynchronizationMessage that was received.
+ * @return The ReplicationMessage that was received.
* @throws IOException When error happened durin IO process.
* @throws ClassNotFoundException When the data received does extend the
- * SynchronizationMessage class.
+ * ReplicationMessage class.
* @throws DataFormatException When the data received is not formatted as a
- * SynchronizationMessage.
+ * ReplicationMessage.
*/
- public abstract SynchronizationMessage receive()
+ public abstract ReplicationMessage receive()
throws IOException, ClassNotFoundException,
DataFormatException;
@@ -106,7 +106,7 @@
/**
- * Gets the time the last synchronization message was published on this
+ * Gets the time the last replication message was published on this
* session.
* @return The timestamp in milliseconds of the last message published.
*/
@@ -115,7 +115,7 @@
/**
- * Gets the time the last synchronization message was received on this
+ * Gets the time the last replication message was received on this
* session.
* @return The timestamp in milliseconds of the last message received.
*/
diff --git a/opends/src/server/org/opends/server/replication/protocol/SynchronizationMessage.java b/opends/src/server/org/opends/server/replication/protocol/ReplicationMessage.java
similarity index 94%
rename from opends/src/server/org/opends/server/replication/protocol/SynchronizationMessage.java
rename to opends/src/server/org/opends/server/replication/protocol/ReplicationMessage.java
index 44e112e..206094c 100644
--- a/opends/src/server/org/opends/server/replication/protocol/SynchronizationMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/ReplicationMessage.java
@@ -31,12 +31,12 @@
/**
* Abstract class that must be used when defining messages that can
- * be sent for synchronization purpose between servers.
+ * be sent for replication purpose between servers.
*
* When extending this class one should also create a new MSG_TYPE
* and should update the generateMsg() method.
*/
-public abstract class SynchronizationMessage
+public abstract class ReplicationMessage
{
static final byte MSG_TYPE_MODIFY_REQUEST = 1;
static final byte MSG_TYPE_ADD_REQUEST = 2;
@@ -79,17 +79,17 @@
/**
- * Generates a SynchronizationMessage from its encoded form.
+ * Generates a ReplicationMessage from its encoded form.
*
- * @param buffer The encode form of the SynchronizationMessage.
+ * @param buffer The encode form of the ReplicationMessage.
* @return the generated SycnhronizationMessage.
* @throws DataFormatException if the encoded form was not a valid msg.
* @throws UnsupportedEncodingException if UTF8 is not supported.
*/
- public static SynchronizationMessage generateMsg(byte[] buffer)
+ public static ReplicationMessage generateMsg(byte[] buffer)
throws DataFormatException, UnsupportedEncodingException
{
- SynchronizationMessage msg = null;
+ ReplicationMessage msg = null;
switch (buffer[0])
{
case MSG_TYPE_MODIFY_REQUEST:
diff --git a/opends/src/server/org/opends/server/replication/protocol/RoutableMessage.java b/opends/src/server/org/opends/server/replication/protocol/RoutableMessage.java
index 76f4939..581c096 100644
--- a/opends/src/server/org/opends/server/replication/protocol/RoutableMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/RoutableMessage.java
@@ -29,11 +29,11 @@
import java.io.Serializable;
/**
- * This is an abstract class of messages of the synchronization protocol
+ * This is an abstract class of messages of the replication protocol
* for message that needs to contain information about the server that
* send them and the destination servers to whitch they should be sent.
*/
-public abstract class RoutableMessage extends SynchronizationMessage implements
+public abstract class RoutableMessage extends ReplicationMessage implements
Serializable
{
@@ -47,7 +47,7 @@
*/
public static final short UNKNOWN_SERVER = -1;
/**
- * Specifies all servers in the synchronization domain.
+ * Specifies all servers in the replication domain.
*/
public static final short ALL_SERVERS = -2;
/**
diff --git a/opends/src/server/org/opends/server/replication/protocol/ServerStartMessage.java b/opends/src/server/org/opends/server/replication/protocol/ServerStartMessage.java
index 385b85a..a2842ab 100644
--- a/opends/src/server/org/opends/server/replication/protocol/ServerStartMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/ServerStartMessage.java
@@ -41,7 +41,7 @@
* to a changelog server to let them know who they are and what is their state
* (their RUV)
*/
-public class ServerStartMessage extends SynchronizationMessage implements
+public class ServerStartMessage extends ReplicationMessage implements
Serializable
{
private static final long serialVersionUID = 8649393307038290287L;
@@ -57,7 +57,7 @@
private ServerState serverState = null;
/**
- * The time in milliseconds between heartbeats from the synchronization
+ * The time in milliseconds between heartbeats from the replication
* server. Zero means heartbeats are off.
*/
private long heartbeatInterval = 0;
diff --git a/opends/src/server/org/opends/server/replication/protocol/SocketSession.java b/opends/src/server/org/opends/server/replication/protocol/SocketSession.java
index 6cd1f89..0c53005 100644
--- a/opends/src/server/org/opends/server/replication/protocol/SocketSession.java
+++ b/opends/src/server/org/opends/server/replication/protocol/SocketSession.java
@@ -35,7 +35,7 @@
/**
* This class Implement a protocol session using a basic socket and relying on
- * the innate encoding/decoding capabilities of the SynchronizationMessage
+ * the innate encoding/decoding capabilities of the ReplicationMessage
* by using the getBytes() and generateMsg() methods of those classes.
*
* TODO : should have some versioning in the packets so that
@@ -89,7 +89,7 @@
/**
* {@inheritDoc}
*/
- public synchronized void publish(SynchronizationMessage msg)
+ public synchronized void publish(ReplicationMessage msg)
throws IOException
{
byte[] buffer = msg.getBytes();
@@ -106,7 +106,7 @@
/**
* {@inheritDoc}
*/
- public SynchronizationMessage receive() throws IOException,
+ public ReplicationMessage receive() throws IOException,
ClassNotFoundException, DataFormatException
{
/* Read the first 8 bytes containing the packet length */
@@ -143,7 +143,7 @@
/* We do not want the heartbeat to close the session when */
/* we are processing a message even a time consuming one. */
lastReceiveTime=0;
- return SynchronizationMessage.generateMsg(buffer);
+ return ReplicationMessage.generateMsg(buffer);
}
catch (OutOfMemoryError e)
{
diff --git a/opends/src/server/org/opends/server/replication/protocol/UpdateMessage.java b/opends/src/server/org/opends/server/replication/protocol/UpdateMessage.java
index d468e10..805bcaa 100644
--- a/opends/src/server/org/opends/server/replication/protocol/UpdateMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/UpdateMessage.java
@@ -44,7 +44,7 @@
* Abstract class that must be extended to define a message
* used for sending Updates between servers.
*/
-public abstract class UpdateMessage extends SynchronizationMessage
+public abstract class UpdateMessage extends ReplicationMessage
implements Serializable,
Comparable<UpdateMessage>
{
@@ -71,7 +71,7 @@
/**
* Creates a new UpdateMessage with the given informations.
*
- * @param ctx The Synchronization Context of the operation for which the
+ * @param ctx The replication Context of the operation for which the
* update message must be created,.
* @param dn The dn of the entry on which the change
* that caused the creation of this object happened
@@ -180,7 +180,7 @@
/**
* Get a boolean indicating if the Update must be processed as an
- * Asynchronous or as an assured synchronization.
+ * Asynchronous or as an assured replication.
*
* @return Returns the assuredFlag.
*/
diff --git a/opends/src/server/org/opends/server/replication/protocol/WindowMessage.java b/opends/src/server/org/opends/server/replication/protocol/WindowMessage.java
index 27c7e03..738aa6e 100644
--- a/opends/src/server/org/opends/server/replication/protocol/WindowMessage.java
+++ b/opends/src/server/org/opends/server/replication/protocol/WindowMessage.java
@@ -36,7 +36,7 @@
* to a changelog server to let them know who they are and what is their state
* (their RUV)
*/
-public class WindowMessage extends SynchronizationMessage implements
+public class WindowMessage extends ReplicationMessage implements
Serializable
{
private static final long serialVersionUID = 8442267608764026867L;
diff --git a/opends/src/server/org/opends/server/replication/protocol/package-info.java b/opends/src/server/org/opends/server/replication/protocol/package-info.java
index 5f9b53c..32a85d2 100644
--- a/opends/src/server/org/opends/server/replication/protocol/package-info.java
+++ b/opends/src/server/org/opends/server/replication/protocol/package-info.java
@@ -37,10 +37,10 @@
* implements the ProtocolSession interface that is
* used by the changelog server and the directory server to communicate.
* This is done by using the innate encoding/decoding capabilities of the
- * SynchronizationMessages objects. This class is used by both the
- * changelog and the synchronization package.
+ * ReplicationMessages objects. This class is used by both the
+ * changelog and the replication package.
* </li>
- * <li><A HREF="SynchronizationMessage.html"><B>SynchronizationMessage</B></A>
+ * <li><A HREF="ReplicationMessage.html"><B>ReplicationMessage</B></A>
* This class and the class that inherit from it contain the
* messages that are used for communication between the changelog and the
* Directory Server as well as the methods fro encoding/decoding them.
diff --git a/opends/src/server/org/opends/server/replication/changelog/AckMessageList.java b/opends/src/server/org/opends/server/replication/server/AckMessageList.java
similarity index 98%
rename from opends/src/server/org/opends/server/replication/changelog/AckMessageList.java
rename to opends/src/server/org/opends/server/replication/server/AckMessageList.java
index 4d78f3d..0b4fdcb 100644
--- a/opends/src/server/org/opends/server/replication/changelog/AckMessageList.java
+++ b/opends/src/server/org/opends/server/replication/server/AckMessageList.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.util.LinkedList;
diff --git a/opends/src/server/org/opends/server/replication/changelog/AckMessageListComparator.java b/opends/src/server/org/opends/server/replication/server/AckMessageListComparator.java
similarity index 96%
rename from opends/src/server/org/opends/server/replication/changelog/AckMessageListComparator.java
rename to opends/src/server/org/opends/server/replication/server/AckMessageListComparator.java
index bf33e23..1c2c5dc 100644
--- a/opends/src/server/org/opends/server/replication/changelog/AckMessageListComparator.java
+++ b/opends/src/server/org/opends/server/replication/server/AckMessageListComparator.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.util.Comparator;
diff --git a/opends/src/server/org/opends/server/replication/changelog/Changelog.java b/opends/src/server/org/opends/server/replication/server/Changelog.java
similarity index 98%
rename from opends/src/server/org/opends/server/replication/changelog/Changelog.java
rename to opends/src/server/org/opends/server/replication/server/Changelog.java
index c4965c6..9a35989 100644
--- a/opends/src/server/org/opends/server/replication/changelog/Changelog.java
+++ b/opends/src/server/org/opends/server/replication/server/Changelog.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.ServerConstants.*;
import static org.opends.server.util.StaticUtils.getFileForPath;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogAckMessageList.java b/opends/src/server/org/opends/server/replication/server/ChangelogAckMessageList.java
similarity index 97%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogAckMessageList.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogAckMessageList.java
index 0df682f..cb82dc7 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogAckMessageList.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogAckMessageList.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import org.opends.server.replication.common.ChangeNumber;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogCache.java b/opends/src/server/org/opends/server/replication/server/ChangelogCache.java
similarity index 99%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogCache.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogCache.java
index ae0f158..127f0a3 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogCache.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogCache.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
import java.io.IOException;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogDB.java b/opends/src/server/org/opends/server/replication/server/ChangelogDB.java
similarity index 98%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogDB.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogDB.java
index ce1902d..a64e9e1 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogDB.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogDB.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
import java.util.List;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogDBException.java b/opends/src/server/org/opends/server/replication/server/ChangelogDBException.java
similarity index 97%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogDBException.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogDBException.java
index cdbd331..af853af 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogDBException.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogDBException.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogData.java b/opends/src/server/org/opends/server/replication/server/ChangelogData.java
similarity index 90%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogData.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogData.java
index bd0f4a1..71e1969 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogData.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogData.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import com.sleepycat.je.DatabaseEntry;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.replication.protocol.UpdateMessage;
/**
@@ -54,6 +54,6 @@
public static UpdateMessage generateChange(byte[] data)
throws Exception
{
- return (UpdateMessage) SynchronizationMessage.generateMsg(data);
+ return (UpdateMessage) ReplicationMessage.generateMsg(data);
}
}
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogDbEnv.java b/opends/src/server/org/opends/server/replication/server/ChangelogDbEnv.java
similarity index 98%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogDbEnv.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogDbEnv.java
index 397e3f9..777cd08 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogDbEnv.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogDbEnv.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
import java.io.File;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogIterator.java b/opends/src/server/org/opends/server/replication/server/ChangelogIterator.java
similarity index 96%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogIterator.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogIterator.java
index 891d427..682b373 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogIterator.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogIterator.java
@@ -24,13 +24,13 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import com.sleepycat.je.DatabaseException;
-import org.opends.server.replication.changelog.ChangelogDB.ChangelogCursor;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.protocol.UpdateMessage;
+import org.opends.server.replication.server.ChangelogDB.ChangelogCursor;
/**
* This class allows to iterate through the changes received from a given
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogIteratorComparator.java b/opends/src/server/org/opends/server/replication/server/ChangelogIteratorComparator.java
similarity index 97%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogIteratorComparator.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogIteratorComparator.java
index 9585f7b..671b05b 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogIteratorComparator.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogIteratorComparator.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.util.Comparator;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ChangelogKey.java b/opends/src/server/org/opends/server/replication/server/ChangelogKey.java
similarity index 96%
rename from opends/src/server/org/opends/server/replication/changelog/ChangelogKey.java
rename to opends/src/server/org/opends/server/replication/server/ChangelogKey.java
index 25d707b..b8003a0 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ChangelogKey.java
+++ b/opends/src/server/org/opends/server/replication/server/ChangelogKey.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.io.UnsupportedEncodingException;
diff --git a/opends/src/server/org/opends/server/replication/changelog/DbHandler.java b/opends/src/server/org/opends/server/replication/server/DbHandler.java
similarity index 98%
rename from opends/src/server/org/opends/server/replication/changelog/DbHandler.java
rename to opends/src/server/org/opends/server/replication/server/DbHandler.java
index 09e9949..ba37087 100644
--- a/opends/src/server/org/opends/server/replication/changelog/DbHandler.java
+++ b/opends/src/server/org/opends/server/replication/server/DbHandler.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
import java.util.ArrayList;
@@ -48,9 +48,9 @@
import org.opends.server.types.InitializationException;
import org.opends.server.util.TimeThread;
import org.opends.server.core.DirectoryServer;
-import org.opends.server.replication.changelog.ChangelogDB.ChangelogCursor;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.protocol.UpdateMessage;
+import org.opends.server.replication.server.ChangelogDB.ChangelogCursor;
import com.sleepycat.je.DatabaseException;
diff --git a/opends/src/server/org/opends/server/replication/changelog/MsgQueue.java b/opends/src/server/org/opends/server/replication/server/MsgQueue.java
similarity index 98%
rename from opends/src/server/org/opends/server/replication/changelog/MsgQueue.java
rename to opends/src/server/org/opends/server/replication/server/MsgQueue.java
index 585c2f0..7b29469 100644
--- a/opends/src/server/org/opends/server/replication/changelog/MsgQueue.java
+++ b/opends/src/server/org/opends/server/replication/server/MsgQueue.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.util.SortedMap;
import java.util.TreeMap;
diff --git a/opends/src/server/org/opends/server/replication/changelog/ServerHandler.java b/opends/src/server/org/opends/server/replication/server/ServerHandler.java
similarity index 98%
rename from opends/src/server/org/opends/server/replication/changelog/ServerHandler.java
rename to opends/src/server/org/opends/server/replication/server/ServerHandler.java
index 4a90410..0f918a1 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ServerHandler.java
+++ b/opends/src/server/org/opends/server/replication/server/ServerHandler.java
@@ -24,13 +24,13 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.loggers.debug.DebugLogger.debugEnabled;
import static org.opends.server.loggers.debug.DebugLogger.debugInfo;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
import java.io.IOException;
@@ -55,7 +55,7 @@
import org.opends.server.replication.protocol.ProtocolSession;
import org.opends.server.replication.protocol.RoutableMessage;
import org.opends.server.replication.protocol.ServerStartMessage;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.replication.protocol.UpdateMessage;
import org.opends.server.replication.protocol.WindowMessage;
import org.opends.server.types.Attribute;
@@ -114,7 +114,7 @@
private short changelogId;
/**
- * The time in milliseconds between heartbeats from the synchronization
+ * The time in milliseconds between heartbeats from the replication
* server. Zero means heartbeats are off.
*/
private long heartbeatInterval = 0;
@@ -177,7 +177,7 @@
session.publish(msg);
}
- SynchronizationMessage msg = session.receive();
+ ReplicationMessage msg = session.receive();
if (msg instanceof ServerStartMessage)
{
ServerStartMessage receivedMsg = (ServerStartMessage) msg;
@@ -284,7 +284,7 @@
// Create a thread to send heartbeat messages.
if (heartbeatInterval > 0)
{
- heartbeatThread = new HeartbeatThread("Synchronization Heartbeat",
+ heartbeatThread = new HeartbeatThread("replication Heartbeat",
session, heartbeatInterval);
heartbeatThread.start();
}
diff --git a/opends/src/server/org/opends/server/replication/changelog/ServerReader.java b/opends/src/server/org/opends/server/replication/server/ServerReader.java
similarity index 95%
rename from opends/src/server/org/opends/server/replication/changelog/ServerReader.java
rename to opends/src/server/org/opends/server/replication/server/ServerReader.java
index 87cd407..c129557 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ServerReader.java
+++ b/opends/src/server/org/opends/server/replication/server/ServerReader.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import java.io.IOException;
@@ -40,7 +40,7 @@
import org.opends.server.replication.protocol.InitializeRequestMessage;
import org.opends.server.replication.protocol.InitializeTargetMessage;
import org.opends.server.replication.protocol.ProtocolSession;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.replication.protocol.UpdateMessage;
import org.opends.server.replication.protocol.WindowMessage;
import org.opends.server.types.ErrorLogCategory;
@@ -96,7 +96,7 @@
{
while (true)
{
- SynchronizationMessage msg = session.receive();
+ ReplicationMessage msg = session.receive();
if (msg == null)
{
diff --git a/opends/src/server/org/opends/server/replication/changelog/ServerWriter.java b/opends/src/server/org/opends/server/replication/server/ServerWriter.java
similarity index 97%
rename from opends/src/server/org/opends/server/replication/changelog/ServerWriter.java
rename to opends/src/server/org/opends/server/replication/server/ServerWriter.java
index 2d96876..b5af7cc 100644
--- a/opends/src/server/org/opends/server/replication/changelog/ServerWriter.java
+++ b/opends/src/server/org/opends/server/replication/server/ServerWriter.java
@@ -24,11 +24,11 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.opends.server.loggers.Error.logError;
import static org.opends.server.messages.MessageHandler.getMessage;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import java.io.IOException;
import java.net.SocketException;
diff --git a/opends/src/server/org/opends/server/replication/changelog/UpdateComparator.java b/opends/src/server/org/opends/server/replication/server/UpdateComparator.java
similarity index 97%
rename from opends/src/server/org/opends/server/replication/changelog/UpdateComparator.java
rename to opends/src/server/org/opends/server/replication/server/UpdateComparator.java
index ea880d7..e6f158f 100644
--- a/opends/src/server/org/opends/server/replication/changelog/UpdateComparator.java
+++ b/opends/src/server/org/opends/server/replication/server/UpdateComparator.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.util.Comparator;
diff --git a/opends/src/server/org/opends/server/replication/changelog/package-info.java b/opends/src/server/org/opends/server/replication/server/package-info.java
similarity index 92%
rename from opends/src/server/org/opends/server/replication/changelog/package-info.java
rename to opends/src/server/org/opends/server/replication/server/package-info.java
index 79d16fc..ba38d2c 100644
--- a/opends/src/server/org/opends/server/replication/changelog/package-info.java
+++ b/opends/src/server/org/opends/server/replication/server/package-info.java
@@ -27,7 +27,7 @@
/**
* This package contains the code for the changelog service part
- * of the Multimaster synchronization feature.
+ * of the Multimaster replication feature.
* <br>
*
* A changelog server is responsible for :
@@ -48,8 +48,8 @@
* implements the ProtocolSession interface that is
* used by the changelog server and the directory server to communicate.
* This is done by using the innate encoding/decoding capabilities of the
- * SynchronizationMessages objects. This class is used by both the
- * changelog and the synchronization package.
+ * ReplicationMessages objects. This class is used by both the
+ * changelog and the replication package.
* </li>
* <li><A HREF="ChangelogCache.html"><B>ChangelogCache</B></A>
* implements the multiplexing part of the changelog
@@ -76,4 +76,4 @@
* </ul>
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
diff --git a/opends/src/server/org/opends/server/tasks/InitializeTargetTask.java b/opends/src/server/org/opends/server/tasks/InitializeTargetTask.java
index dd60297..82bfad7 100644
--- a/opends/src/server/org/opends/server/tasks/InitializeTargetTask.java
+++ b/opends/src/server/org/opends/server/tasks/InitializeTargetTask.java
@@ -41,7 +41,7 @@
import org.opends.server.backends.task.TaskState;
import org.opends.server.messages.TaskMessages;
import org.opends.server.protocols.asn1.ASN1OctetString;
-import org.opends.server.replication.plugin.SynchronizationDomain;
+import org.opends.server.replication.plugin.ReplicationDomain;
import org.opends.server.types.Attribute;
import org.opends.server.types.AttributeType;
import org.opends.server.types.AttributeValue;
@@ -66,7 +66,7 @@
boolean isEncrypted = false;
boolean skipSchemaValidation = false;
String domainString = null;
- SynchronizationDomain domain = null;
+ ReplicationDomain domain = null;
short target;
long total;
long left;
@@ -103,7 +103,7 @@
throw new DirectoryException(ResultCode.INVALID_DN_SYNTAX,
message, msgID);
}
- domain=SynchronizationDomain.retrievesSynchronizationDomain(domainDN);
+ domain=ReplicationDomain.retrievesReplicationDomain(domainDN);
attrList = taskEntry.getAttribute(typeScope);
String targetString = TaskUtils.getSingleValueString(attrList);
diff --git a/opends/src/server/org/opends/server/tasks/InitializeTask.java b/opends/src/server/org/opends/server/tasks/InitializeTask.java
index 07e8fc0..0fcfd92 100644
--- a/opends/src/server/org/opends/server/tasks/InitializeTask.java
+++ b/opends/src/server/org/opends/server/tasks/InitializeTask.java
@@ -41,7 +41,7 @@
import org.opends.server.backends.task.TaskState;
import org.opends.server.messages.TaskMessages;
import org.opends.server.protocols.asn1.ASN1OctetString;
-import org.opends.server.replication.plugin.SynchronizationDomain;
+import org.opends.server.replication.plugin.ReplicationDomain;
import org.opends.server.types.Attribute;
import org.opends.server.types.AttributeType;
import org.opends.server.types.AttributeValue;
@@ -56,8 +56,8 @@
/**
* This class provides an implementation of a Directory Server task that can
- * be used to import data over the synchronization protocol from another
- * server hosting the same synchronization domain.
+ * be used to import data over the replication protocol from another
+ * server hosting the same replication domain.
*/
public class InitializeTask extends Task
{
@@ -66,7 +66,7 @@
boolean skipSchemaValidation = false;
String domainString = null;
short source;
- SynchronizationDomain domain = null;
+ ReplicationDomain domain = null;
TaskState initState;
// The total number of entries expected to be processed when this import
@@ -110,7 +110,7 @@
message, msgID);
}
- domain=SynchronizationDomain.retrievesSynchronizationDomain(domainDN);
+ domain=ReplicationDomain.retrievesReplicationDomain(domainDN);
attrList = taskEntry.getAttribute(typeSourceScope);
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/controls/ControlsTestCase.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/controls/ControlsTestCase.java
index ac1f96f..64a04c4 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/controls/ControlsTestCase.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/controls/ControlsTestCase.java
@@ -33,7 +33,7 @@
import org.testng.annotations.BeforeClass;
/**
- * An abstract class that all synchronization unit test should extend.
+ * An abstract class that all control unit test should extend.
*/
@Test(groups = { "precommit", "controls" })
public abstract class ControlsTestCase extends DirectoryServerTestCase
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/InitOnLineTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/InitOnLineTest.java
index d4185c5..2628b5e 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/InitOnLineTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/InitOnLineTest.java
@@ -46,10 +46,8 @@
import org.opends.server.messages.TaskMessages;
import org.opends.server.protocols.internal.InternalClientConnection;
import org.opends.server.protocols.internal.InternalSearchOperation;
-import org.opends.server.replication.changelog.Changelog;
-import org.opends.server.replication.changelog.ChangelogFakeConfiguration;
import org.opends.server.replication.plugin.ChangelogBroker;
-import org.opends.server.replication.plugin.SynchronizationDomain;
+import org.opends.server.replication.plugin.ReplicationDomain;
import org.opends.server.replication.protocol.DoneMessage;
import org.opends.server.replication.protocol.EntryMessage;
import org.opends.server.replication.protocol.ErrorMessage;
@@ -57,7 +55,9 @@
import org.opends.server.replication.protocol.InitializeTargetMessage;
import org.opends.server.replication.protocol.RoutableMessage;
import org.opends.server.replication.protocol.SocketSession;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
+import org.opends.server.replication.server.Changelog;
+import org.opends.server.replication.server.ChangelogFakeConfiguration;
import org.opends.server.schema.DirectoryStringSyntax;
import org.opends.server.types.AttributeType;
import org.opends.server.types.DN;
@@ -69,7 +69,7 @@
import org.opends.server.types.SearchScope;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Test;
-import static org.opends.server.messages.SynchronizationMessages.*;
+import static org.opends.server.messages.ReplicationMessages.*;
import static org.opends.server.util.StaticUtils.stackTraceToSingleLineString;
/**
@@ -93,14 +93,11 @@
* InitializeTarget task
*/
-public class InitOnLineTest extends SynchronizationTestCase
+public class InitOnLineTest extends ReplicationTestCase
{
private static final int WINDOW_SIZE = 10;
private static final int CHANGELOG_QUEUE_SIZE = 100;
- private static final String SYNCHRONIZATION_STRESS_TEST =
- "Synchronization Stress Test";
-
/**
* A "person" entry
*/
@@ -125,7 +122,7 @@
Changelog changelog1 = null;
Changelog changelog2 = null;
boolean emptyOldChanges = true;
- SynchronizationDomain sd = null;
+ ReplicationDomain sd = null;
private void log(String s)
{
@@ -144,7 +141,6 @@
/**
* Set up the environment for performing the tests in this Class.
- * synchronization
*
* @throws Exception
* If the environment could not be set up.
@@ -180,10 +176,10 @@
synchroServerEntry = null;
// Add config entries to the current DS server based on :
- // Add the synchronization plugin: synchroPluginEntry & synchroPluginStringDN
+ // Add the replication plugin: synchroPluginEntry & synchroPluginStringDN
// Add synchroServerEntry
// Add changeLogEntry
- configureSynchronization();
+ configureReplication();
taskInitFromS2 = TestCaseUtils.makeEntry(
"dn: ds-task-id=" + UUID.randomUUID() +
@@ -666,7 +662,7 @@
String[] updatedEntries)
{
// Expect the broker to receive the entries
- SynchronizationMessage msg;
+ ReplicationMessage msg;
short entriesReceived = 0;
while (true)
{
@@ -785,17 +781,17 @@
"Unable to add the synchronized server");
entryList.add(synchroServerEntry.getDN());
- sd = SynchronizationDomain.retrievesSynchronizationDomain(baseDn);
+ sd = ReplicationDomain.retrievesReplicationDomain(baseDn);
// Clear the backend
- SynchronizationDomain.clearJEBackend(false,
+ ReplicationDomain.clearJEBackend(false,
sd.getBackend().getBackendID(),
baseDn.toNormalizedString());
}
if (sd != null)
{
- log("SynchronizationDomain: Import/Export is running ? " + sd.ieRunning());
+ log("ReplicationDomain: Import/Export is running ? " + sd.ieRunning());
}
}
catch(Exception e)
@@ -837,7 +833,7 @@
addTask(taskInitFromS2, ResultCode.SUCCESS, 0);
// S2 should receive init msg
- SynchronizationMessage msg;
+ ReplicationMessage msg;
msg = server2.receive();
if (!(msg instanceof InitializeRequestMessage))
{
@@ -872,7 +868,7 @@
@Test(enabled=false)
public void InitializeExport() throws Exception
{
- String testCase = "Synchronization/InitializeExport";
+ String testCase = "Replication/InitializeExport";
log("Starting "+testCase);
@@ -906,7 +902,7 @@
@Test(enabled=false)
public void InitializeTargetExport() throws Exception
{
- String testCase = "Synchronization/InitializeTargetExport";
+ String testCase = "Replication/InitializeTargetExport";
log("Starting " + testCase);
@@ -946,7 +942,7 @@
@Test(enabled=false)
public void InitializeTargetExportAll() throws Exception
{
- String testCase = "Synchronization/InitializeTargetExportAll";
+ String testCase = "Replication/InitializeTargetExportAll";
log("Starting " + testCase);
@@ -1165,7 +1161,7 @@
@Test(enabled=false)
public void InitializeTargetExportMultiSS() throws Exception
{
- String testCase = "Synchronization/InitializeTargetExportMultiSS";
+ String testCase = "Replication/InitializeTargetExportMultiSS";
log("Starting " + testCase);
@@ -1211,7 +1207,7 @@
@Test(enabled=false)
public void InitializeExportMultiSS() throws Exception
{
- String testCase = "Synchronization/InitializeExportMultiSS";
+ String testCase = "Replication/InitializeExportMultiSS";
log("Starting "+testCase);
// Create 2 changelogs
@@ -1282,7 +1278,7 @@
if (sd != null)
{
- log("SynchronizationDomain: Import/Export is running ? " + sd.ieRunning());
+ log("ReplicationDomain: Import/Export is running ? " + sd.ieRunning());
}
log("Successfully ending "+testCase);
@@ -1321,7 +1317,7 @@
if (sd != null)
{
- log("SynchronizationDomain: Import/Export is running ? " + sd.ieRunning());
+ log("ReplicationDomain: Import/Export is running ? " + sd.ieRunning());
}
log("Successfully ending "+testCase);
@@ -1430,7 +1426,7 @@
if (sd != null)
{
- log("SynchronizationDomain: Import/Export is running ? " + sd.ieRunning());
+ log("ReplicationDomain: Import/Export is running ? " + sd.ieRunning());
}
// Clean brokers
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ProtocolWindowTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ProtocolWindowTest.java
index 32eca00..c4fbffc 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ProtocolWindowTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ProtocolWindowTest.java
@@ -45,7 +45,7 @@
import org.opends.server.protocols.ldap.LDAPFilter;
import org.opends.server.replication.plugin.ChangelogBroker;
import org.opends.server.replication.protocol.AddMsg;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.types.Attribute;
import org.opends.server.types.AttributeType;
import org.opends.server.types.AttributeValue;
@@ -64,16 +64,16 @@
import org.testng.annotations.Test;
/**
- * Test the contructors, encoders and decoders of the synchronization AckMsg,
+ * Test the contructors, encoders and decoders of the Replication AckMsg,
* ModifyMsg, ModifyDnMsg, AddMsg and Delete Msg
*/
-public class ProtocolWindowTest extends SynchronizationTestCase
+public class ProtocolWindowTest extends ReplicationTestCase
{
private static final int WINDOW_SIZE = 10;
private static final int CHANGELOG_QUEUE_SIZE = 100;
- private static final String SYNCHRONIZATION_STRESS_TEST =
- "Synchronization Stress Test";
+ private static final String REPLICATION_STRESS_TEST =
+ "Replication Stress Test";
/**
* A "person" entry
@@ -94,7 +94,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization ProtocolWindowTest : saturateAndRestart" , 1);
+ "Starting Replication ProtocolWindowTest : saturateAndRestart" , 1);
final DN baseDn = DN.decode("ou=People,dc=example,dc=com");
@@ -125,17 +125,17 @@
"The Add Entry operation failed");
// Check if the client has received the msg
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
assertTrue(msg instanceof AddMsg,
- "The received synchronization message is not an ADD msg");
+ "The received Replication message is not an ADD msg");
AddMsg addMsg = (AddMsg) msg;
Operation receivedOp = addMsg.createOperation(connection);
assertTrue(OperationType.ADD.compareTo(receivedOp.getOperationType()) == 0,
- "The received synchronization message is not an ADD msg");
+ "The received Replication message is not an ADD msg");
assertEquals(DN.decode(addMsg.getDn()),personEntry.getDN(),
- "The received ADD synchronization message is not for the excepted DN");
+ "The received ADD Replication message is not for the excepted DN");
// send (2 * window + changelog queue) modify operations
// so that window + changelog queue get stuck in the changelog queue
@@ -166,7 +166,7 @@
}
finally {
broker.stop();
- DirectoryServer.deregisterMonitorProvider(SYNCHRONIZATION_STRESS_TEST);
+ DirectoryServer.deregisterMonitorProvider(REPLICATION_STRESS_TEST);
}
}
@@ -229,7 +229,7 @@
/**
* Set up the environment for performing the tests in this Class.
- * synchronization
+ * Replication
*
* @throws Exception
* If the environment could not be set up.
@@ -315,7 +315,7 @@
+ "userPassword: password\n" + "initials: AA\n";
personEntry = TestCaseUtils.entryFromLdifString(personLdif);
- configureSynchronization();
+ configureReplication();
}
/**
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReSyncTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReSyncTest.java
index 8b54ce1..05b1019 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReSyncTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReSyncTest.java
@@ -54,7 +54,7 @@
/**
* Test re-synchronization after after backup/restore and LDIF import.
*/
-public class ReSyncTest extends SynchronizationTestCase
+public class ReSyncTest extends ReplicationTestCase
{
/**
* Set up the environment for performing the tests in this Class.
@@ -66,7 +66,7 @@
public void setup() throws Exception
{
/*
- * - Start a server and a changelog server, configure synchronization
+ * - Start a server and a changelog server, configure replication
* - Do some changes.
*/
TestCaseUtils.startServer();
@@ -111,9 +111,9 @@
+ "ds-cfg-directory-server-id: 123\n";
synchroServerEntry = TestCaseUtils.entryFromLdifString(synchroServerLdif);
- configureSynchronization();
+ configureReplication();
- // Give some time to the synchronization to setup
+ // Give some time to the replication to setup
Thread.sleep(1000);
// Create a dummy entry
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SynchronizationTestCase.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReplicationTestCase.java
similarity index 93%
rename from opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SynchronizationTestCase.java
rename to opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReplicationTestCase.java
index 88fe4a3..c59b206 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SynchronizationTestCase.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/ReplicationTestCase.java
@@ -65,10 +65,10 @@
import org.testng.annotations.BeforeClass;
/**
- * An abstract class that all synchronization unit test should extend.
+ * An abstract class that all Replication unit test should extend.
*/
-@Test(groups = { "precommit", "synchronization" })
-public abstract class SynchronizationTestCase extends DirectoryServerTestCase
+@Test(groups = { "precommit", "replication" })
+public abstract class ReplicationTestCase extends DirectoryServerTestCase
{
/**
@@ -92,7 +92,7 @@
protected boolean schemaCheck;
/**
- * The synchronization plugin entry
+ * The replication plugin entry
*/
protected String synchroPluginStringDN =
"cn=Multimaster Synchronization, cn=Synchronization Providers,cn=config";
@@ -155,7 +155,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "SynchronizationTestCase/openChangelogSession" + e.getMessage(), 1);
+ "ReplicationTestCase/openChangelogSession" + e.getMessage(), 1);
}
}
return broker;
@@ -231,7 +231,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "SynchronizationTestCase/Cleaning config entries" , 1);
+ "ReplicationTestCase/Cleaning config entries" , 1);
DeleteOperation op;
// Delete entries
@@ -263,7 +263,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "SynchronizationTestCase/Cleaning entries" , 1);
+ "ReplicationTestCase/Cleaning entries" , 1);
DeleteOperation op;
// Delete entries
@@ -304,24 +304,24 @@
}
/**
- * Configure the Synchronization for this test.
+ * Configure the replication for this test.
*/
- protected void configureSynchronization() throws Exception
+ protected void configureReplication() throws Exception
{
- // Add the Multimaster synchronization plugin
+ // Add the Multimaster replication plugin
String synchroPluginLdif = "dn: " + synchroPluginStringDN + "\n"
+ "objectClass: top\n"
+ "objectClass: ds-cfg-synchronization-provider\n"
+ "objectClass: ds-cfg-multimaster-synchronization-provider\n"
+ "ds-cfg-synchronization-provider-enabled: true\n"
+ "ds-cfg-synchronization-provider-class: " +
- "org.opends.server.replication.plugin.MultimasterSynchronization\n";
+ "org.opends.server.replication.plugin.MultimasterReplication\n";
Entry synchroPluginEntry = TestCaseUtils.entryFromLdifString(synchroPluginLdif);
DirectoryServer.getConfigHandler().addEntry(synchroPluginEntry, null);
configEntryList.add(synchroPluginEntry.getDN());
assertNotNull(DirectoryServer.getConfigEntry(DN
.decode(synchroPluginStringDN)),
- "Unable to add the Multimaster synchronization plugin");
+ "Unable to add the Multimaster replication plugin");
// domains container entry.
String domainsLdif = "dn: "
@@ -333,7 +333,7 @@
configEntryList.add(domainsEntry.getDN());
assertNotNull(DirectoryServer.getConfigEntry(
DN.decode(synchroPluginStringDN)),
- "Unable to add the Multimaster synchronization plugin");
+ "Unable to add the Multimaster replication plugin");
// Add the changelog server
@@ -342,7 +342,7 @@
"Unable to add the changeLog server");
configEntryList.add(changeLogEntry.getDN());
- // We also have a replicated suffix (synchronization domain)
+ // We also have a replicated suffix (replication domain)
DirectoryServer.getConfigHandler().addEntry(synchroServerEntry, null);
assertNotNull(DirectoryServer.getConfigEntry(synchroServerEntry.getDN()),
"Unable to add the synchronized server");
@@ -350,7 +350,7 @@
}
/**
- * Retrieve the number of replayed updates for a given synchronization
+ * Retrieve the number of replayed updates for a given replication
* domain from the monitor entry.
* @return The number of replayed updates.
* @throws Exception If an error occurs.
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SchemaSynchronizationTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SchemaReplicationTest.java
similarity index 92%
rename from opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SchemaSynchronizationTest.java
rename to opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SchemaReplicationTest.java
index bef63a0..d7476d7 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SchemaSynchronizationTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/SchemaReplicationTest.java
@@ -43,11 +43,10 @@
import org.opends.server.core.DirectoryServer;
import org.opends.server.core.ModifyOperation;
import org.opends.server.protocols.internal.InternalClientConnection;
-import org.opends.server.protocols.ldap.LDAPModification;
import org.opends.server.replication.common.ChangeNumberGenerator;
import org.opends.server.replication.plugin.ChangelogBroker;
import org.opends.server.replication.protocol.ModifyMsg;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.types.Attribute;
import org.opends.server.types.AttributeType;
import org.opends.server.types.AttributeValue;
@@ -63,9 +62,9 @@
import org.testng.annotations.Test;
/**
- * Test for the schema synchronization.
+ * Test for the schema replication.
*/
-public class SchemaSynchronizationTest extends SynchronizationTestCase
+public class SchemaReplicationTest extends ReplicationTestCase
{
private ArrayList<Modification> rcvdMods = null;
@@ -74,7 +73,6 @@
/**
* Set up the environment for performing the tests in this Class.
- * synchronization
*
* @throws Exception
* If the environment could not be set up.
@@ -122,7 +120,7 @@
+ "ds-cfg-directory-server-id: 1\n";
synchroServerEntry = TestCaseUtils.entryFromLdifString(synchroServerLdif);
- configureSynchronization();
+ configureReplication();
}
/**
@@ -134,7 +132,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : pushSchemaChange ", 1);
+ "Starting replication test : pushSchemaChange ", 1);
final DN baseDn = DN.decode("cn=schema");
@@ -163,10 +161,10 @@
"The original operation failed");
// See if the client has received the msg
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
assertTrue(msg instanceof ModifyMsg,
- "The received synchronization message is not a MODIFY msg");
+ "The received replication message is not a MODIFY msg");
ModifyMsg modMsg = (ModifyMsg) msg;
Operation receivedOp = modMsg.createOperation(connection);
@@ -174,7 +172,7 @@
"The received message is not for cn=schema");
assertTrue(receivedOp instanceof ModifyOperation,
- "The received synchronization message is not a MODIFY msg");
+ "The received replication message is not a MODIFY msg");
ModifyOperation receivedModifyOperation = (ModifyOperation) receivedOp;
List<RawModification> rcvdRawMods =
@@ -213,14 +211,14 @@
/**
* Checks that changes to the schema pushed to the changelog
- * are received and correctly replayed by synchronization plugin.
+ * are received and correctly replayed by replication plugin.
*/
@Test(dependsOnMethods = { "pushSchemaChange" })
public void replaySchemaChange() throws Exception
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : pushSchemaChange ", 1);
+ "Starting replication test : pushSchemaChange ", 1);
final DN baseDn = DN.decode("cn=schema");
@@ -254,7 +252,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : pushSchemaFilesChange ", 1);
+ "Starting replication test : pushSchemaFilesChange ", 1);
final DN baseDn = DN.decode("cn=schema");
@@ -278,10 +276,10 @@
}
// receive the message on the broker side.
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
assertTrue(msg instanceof ModifyMsg,
- "The received synchronization message is not a MODIFY msg");
+ "The received replication message is not a MODIFY msg");
ModifyMsg modMsg = (ModifyMsg) msg;
Operation receivedOp = modMsg.createOperation(connection);
@@ -289,7 +287,7 @@
"The received message is not for cn=schema");
assertTrue(receivedOp instanceof ModifyOperation,
- "The received synchronization message is not a MODIFY msg");
+ "The received replication message is not a MODIFY msg");
ModifyOperation receivedModifyOperation = (ModifyOperation) receivedOp;
List<RawModification> rcvdRawMods =
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/StressTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/StressTest.java
index e5b83f5..1d565db 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/StressTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/StressTest.java
@@ -47,7 +47,7 @@
import org.opends.server.protocols.internal.InternalClientConnection;
import org.opends.server.replication.plugin.ChangelogBroker;
import org.opends.server.replication.protocol.AddMsg;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.types.Attribute;
import org.opends.server.types.AttributeType;
import org.opends.server.types.AttributeValue;
@@ -67,13 +67,13 @@
/**
* Stress test for the synchronization code using the ChangelogBroker API.
*/
-public class StressTest extends SynchronizationTestCase
+public class StressTest extends ReplicationTestCase
{
- private static final String SYNCHRONIZATION_STRESS_TEST =
- "Synchronization Stress Test";
+ private static final String REPLICATION_STRESS_TEST =
+ "Replication Stress Test";
/**
- * The Synchronization config manager entry
+ * The replication config manager entry
*/
private String synchroStringDN;
@@ -104,7 +104,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting Synchronization StressTest : fromServertoBroker" , 1);
+ "Starting replication StressTest : fromServertoBroker" , 1);
final DN baseDn = DN.decode("ou=People,dc=example,dc=com");
final int TOTAL_MESSAGES = 1000;
@@ -134,18 +134,18 @@
if (ResultCode.SUCCESS == addOp.getResultCode())
{
// Check if the client has received the msg
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
assertTrue(msg instanceof AddMsg,
- "The received synchronization message is not an ADD msg");
+ "The received replication message is not an ADD msg");
AddMsg addMsg = (AddMsg) msg;
Operation receivedOp = addMsg.createOperation(connection);
assertTrue(OperationType.ADD.compareTo(receivedOp.getOperationType()) == 0,
- "The received synchronization message is not an ADD msg");
+ "The received replication message is not an ADD msg");
assertEquals(DN.decode(addMsg.getDn()),personEntry.getDN(),
- "The received ADD synchronization message is not for the excepted DN");
+ "The received ADD replication message is not for the excepted DN");
}
reader = new BrokerReader(broker);
@@ -180,14 +180,13 @@
}
finally {
- DirectoryServer.deregisterMonitorProvider(SYNCHRONIZATION_STRESS_TEST);
+ DirectoryServer.deregisterMonitorProvider(REPLICATION_STRESS_TEST);
broker.stop();
}
}
/**
* Set up the environment for performing the tests in this Class.
- * synchronization
*
* @throws Exception
* If the environment could not be set up.
@@ -268,7 +267,7 @@
+ "userPassword: password\n" + "initials: AA\n";
personEntry = TestCaseUtils.entryFromLdifString(personLdif);
- configureSynchronization();
+ configureReplication();
}
/**
@@ -351,7 +350,7 @@
{
while (true)
{
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
if (msg == null)
break;
count ++;
@@ -423,7 +422,7 @@
@Override
public String getMonitorInstanceName()
{
- return SYNCHRONIZATION_STRESS_TEST;
+ return REPLICATION_STRESS_TEST;
}
@Override
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/UpdateOperationTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/UpdateOperationTest.java
index a29811e..3193dba 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/UpdateOperationTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/UpdateOperationTest.java
@@ -44,7 +44,7 @@
import org.opends.server.replication.protocol.HeartbeatThread;
import org.opends.server.replication.protocol.ModifyDNMsg;
import org.opends.server.replication.protocol.ModifyMsg;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.schema.DirectoryStringSyntax;
import org.opends.server.core.AddOperation;
import org.opends.server.core.DeleteOperation;
@@ -61,10 +61,10 @@
import org.testng.annotations.Test;
/**
- * Test synchronization update operations on the directory server and through
- * the synchronization server broker interface.
+ * Test synchronization of update operations on the directory server and through
+ * the replication server broker interface.
*/
-public class UpdateOperationTest extends SynchronizationTestCase
+public class UpdateOperationTest extends ReplicationTestCase
{
/**
* An entry with a entryUUID
@@ -213,7 +213,7 @@
personWithSecondUniqueID =
TestCaseUtils.entryFromLdifString(entryWithSecondUUID);
- configureSynchronization();
+ configureReplication();
}
/**
@@ -265,7 +265,7 @@
// Check that the entry has not been created in the directory server.
resultEntry = getEntry(personWithUUIDEntry.getDN(), 1000, true);
assertNull(resultEntry,
- "The synchronization message was replayed while the server " +
+ "The replication message was replayed while the server " +
"receive status was disabled");
// Enable the directory server receive status.
@@ -283,7 +283,7 @@
// Check that the entry has been created in the directory server.
resultEntry = getEntry(personWithUUIDEntry.getDN(), 10000, true);
assertNotNull(resultEntry,
- "The synchronization message was not replayed after the server " +
+ "The replication message was not replayed after the server " +
"receive status was enabled");
// Delete the entries to clean the database.
@@ -295,20 +295,20 @@
// Check that the delete operation has been applied.
assertNull(resultEntry,
- "The DELETE synchronization message was not replayed");
+ "The DELETE replication message was not replayed");
broker.stop();
}
/**
* Tests whether the synchronization provider fails over when it loses
- * the heartbeat from the synchronization server.
+ * the heartbeat from the replication server.
*/
@Test(groups = "slow")
public void lostHeartbeatFailover() throws Exception
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : lostHeartbeatFailover" , 1);
+ "Starting replication test : lostHeartbeatFailover" , 1);
cleanRealEntries();
@@ -344,7 +344,7 @@
// Check that the entry has been created in the directory server.
resultEntry = getEntry(personWithUUIDEntry.getDN(), 10000, true);
assertNotNull(resultEntry,
- "The ADD synchronization message was not replayed");
+ "The ADD replication message was not replayed");
// Send a first modify operation message.
List<Modification> mods = generatemods("telephonenumber", "01 02 45");
@@ -391,7 +391,7 @@
// Check that the delete operation has been applied.
assertNull(resultEntry,
- "The DELETE synchronization message was not replayed");
+ "The DELETE replication message was not replayed");
broker.stop();
}
@@ -410,7 +410,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : namingConflicts" , 1);
+ "Starting replication test : namingConflicts" , 1);
final DN baseDn = DN.decode("ou=People,dc=example,dc=com");
@@ -447,7 +447,7 @@
// Check that the entry has been created in the local DS.
Entry resultEntry = getEntry(personWithUUIDEntry.getDN(), 10000, true);
assertNotNull(resultEntry,
- "The send ADD synchronization message was not applied");
+ "The send ADD replication message was not applied");
entryList.add(resultEntry.getDN());
// send a modify operation with the correct unique ID but another DN
@@ -484,7 +484,7 @@
// Check that the entry has been created in the local DS.
resultEntry = getEntry(personWithUUIDEntry.getDN(), 10000, true);
assertNotNull(resultEntry,
- "The ADD synchronization message was not applied");
+ "The ADD replication message was not applied");
entryList.add(resultEntry.getDN());
// send a modify operation with a wrong unique ID but the same DN
@@ -518,7 +518,7 @@
resultEntry = getEntry(personWithUUIDEntry.getDN(), 10000, false);
assertNull(resultEntry,
- "The DELETE synchronization message was not replayed");
+ "The DELETE replication message was not replayed");
/*
* Test that two adds with the same DN but a different unique ID result
@@ -536,7 +536,7 @@
// Check that the entry has been created in the local DS.
resultEntry = getEntry(personWithUUIDEntry.getDN(), 10000, true);
assertNotNull(resultEntry,
- "The ADD synchronization message was not applied");
+ "The ADD replication message was not applied");
entryList.add(resultEntry.getDN());
// create an entry with the same DN and another unique ID
@@ -552,7 +552,7 @@
DN.decode("entryuuid=" + user1entrysecondUUID +" + " + user1dn),
10000, true);
assertNotNull(resultEntry,
- "The ADD synchronization message was not applied");
+ "The ADD replication message was not applied");
// delete the entries to clean the database.
delMsg =
@@ -567,7 +567,7 @@
// check that the delete operation has been applied
assertNull(resultEntry,
- "The DELETE synchronization message was not replayed");
+ "The DELETE replication message was not replayed");
/*
* Check that and added entry is correctly added below it's
* parent entry when this parent entry has been renamed.
@@ -587,7 +587,7 @@
resultEntry = getEntry(
DN.decode("uid=new person,ou=People,dc=example,dc=com"), 10000, true);
assertNotNull(resultEntry,
- "The ADD synchronization message was not applied");
+ "The ADD replication message was not applied");
/*
* Check that when replaying delete the naming conflict code
@@ -607,7 +607,7 @@
// check that the delete operation has not been applied
assertNotNull(resultEntry,
- "The DELETE synchronization message was replayed when it should not");
+ "The DELETE replication message was replayed when it should not");
/*
@@ -693,7 +693,7 @@
// check that the delete operation has been applied
assertNull(resultEntry,
- "The DELETE synchronization message was not replayed");
+ "The DELETE replication message was not replayed");
delMsg =
new DeleteMsg("entryUUID = " + user1entrysecondUUID + "+" +
@@ -708,12 +708,12 @@
// check that the delete operation has been applied
assertNull(resultEntry,
- "The DELETE synchronization message was not replayed");
+ "The DELETE replication message was not replayed");
/*
* When replaying add operations it is possible that the parent entry has
* been renamed before and that another entry have taken the former dn of
- * the parent entry. In such case the synchronization replay code should
+ * the parent entry. In such case the replication replay code should
* detect that the parent has been renamed and should add the entry below
* the new dn of the parent (thus changing the original dn with which the
* entry had been created)
@@ -793,12 +793,12 @@
resultEntry = getEntry(
DN.decode("uid=new person,ou=baseDn1,"+baseDn), 10000, false);
assertNull(resultEntry,
- "The ADD synchronization message was applied under ou=baseDn1,"+baseDn);
+ "The ADD replication message was applied under ou=baseDn1,"+baseDn);
resultEntry = getEntry(
DN.decode("uid=new person,ou=baseDn2,"+baseDn), 10000, true);
assertNotNull(resultEntry,
- "The ADD synchronization message was NOT applied under ou=baseDn2,"+baseDn);
+ "The ADD replication message was NOT applied under ou=baseDn2,"+baseDn);
entryList.add(resultEntry.getDN());
@@ -819,7 +819,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : updateOperations " + assured , 1);
+ "Starting replication test : updateOperations " + assured , 1);
final DN baseDn = DN.decode("ou=People,dc=example,dc=com");
@@ -850,17 +850,17 @@
if (ResultCode.SUCCESS.equals(addOp.getResultCode()))
{
// Check if the client has received the msg
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
assertTrue(msg instanceof AddMsg,
- "The received synchronization message is not an ADD msg");
+ "The received replication message is not an ADD msg");
AddMsg addMsg = (AddMsg) msg;
Operation receivedOp = addMsg.createOperation(connection);
assertTrue(OperationType.ADD.compareTo(receivedOp.getOperationType()) == 0,
- "The received synchronization message is not an ADD msg");
+ "The received replication message is not an ADD msg");
assertEquals(DN.decode(addMsg.getDn()),personEntry.getDN(),
- "The received ADD synchronization message is not for the excepted DN");
+ "The received ADD replication message is not for the excepted DN");
}
// Modify the entry
@@ -873,14 +873,14 @@
modOp.run();
// See if the client has received the msg
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
assertTrue(msg instanceof ModifyMsg,
- "The received synchronization message is not a MODIFY msg");
+ "The received replication message is not a MODIFY msg");
ModifyMsg modMsg = (ModifyMsg) msg;
modMsg.createOperation(connection);
assertTrue(DN.decode(modMsg.getDn()).compareTo(personEntry.getDN()) == 0,
- "The received MODIFY synchronization message is not for the excepted DN");
+ "The received MODIFY replication message is not for the excepted DN");
// Modify the entry DN
DN newDN = DN.decode("uid= new person,ou=People,dc=example,dc=com") ;
@@ -898,7 +898,7 @@
// See if the client has received the msg
msg = broker.receive();
assertTrue(msg instanceof ModifyDNMsg,
- "The received synchronization message is not a MODIFY DN msg");
+ "The received replication message is not a MODIFY DN msg");
ModifyDNMsg moddnMsg = (ModifyDNMsg) msg;
moddnMsg.createOperation(connection);
@@ -917,7 +917,7 @@
// See if the client has received the msg
msg = broker.receive();
assertTrue(msg instanceof DeleteMsg,
- "The received synchronization message is not a MODIFY DN msg");
+ "The received replication message is not a MODIFY DN msg");
DeleteMsg delMsg = (DeleteMsg) msg;
delMsg.createOperation(connection);
assertTrue(DN.decode(delMsg.getDn()).compareTo(DN
@@ -944,7 +944,7 @@
*/
Entry resultEntry = getEntry(personWithUUIDEntry.getDN(), 10000, true);
assertNotNull(resultEntry,
- "The send ADD synchronization message was not applied for "+personWithUUIDEntry.getDN().toString());
+ "The send ADD replication message was not applied for "+personWithUUIDEntry.getDN().toString());
entryList.add(resultEntry.getDN());
/*
@@ -977,7 +977,7 @@
DN.decode("uid= new person,ou=People,dc=example,dc=com"), 10000, true);
assertNotNull(resultEntry,
- "The modify DN synchronization message was not applied");
+ "The modify DN replication message was not applied");
/*
* Test the Reception of Delete Msg
@@ -991,7 +991,7 @@
DN.decode("uid= new person,ou=People,dc=example,dc=com"), 10000, false);
assertNull(resultEntry,
- "The DELETE synchronization message was not replayed");
+ "The DELETE replication message was not replayed");
}
finally
{
@@ -1082,7 +1082,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : deleteNoSuchObject" , 1);
+ "Starting replication test : deleteNoSuchObject" , 1);
DN dn = DN.decode("cn=No Such Object,ou=People,dc=example,dc=com");
Operation op =
@@ -1104,7 +1104,7 @@
{
logError(ErrorLogCategory.SYNCHRONIZATION,
ErrorLogSeverity.NOTICE,
- "Starting synchronization test : infiniteReplayLoop" , 1);
+ "Starting replication test : infiniteReplayLoop" , 1);
final DN baseDn = DN.decode("ou=People,dc=example,dc=com");
@@ -1153,7 +1153,7 @@
DirectoryStringSyntax.DECODER);
// Register a short circuit that will fake a no-such-object result code
- // on a delete. This will cause a synchronization replay loop.
+ // on a delete. This will cause a replication replay loop.
ShortCircuitPlugin.registerShortCircuit(OperationType.DELETE,
"PreParse", 32);
try
@@ -1178,11 +1178,11 @@
"PreParse");
}
- // If the synchronization replay loop was detected and broken then the
+ // If the replication replay loop was detected and broken then the
// counter will still be updated even though the replay was unsuccessful.
if (getReplayedUpdatesCount(baseDn) == initialCount)
{
- fail("Synchronization operation was not replayed");
+ fail("Operation was not replayed");
}
}
finally
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberGeneratorTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberGeneratorTest.java
index ed0394e..851d3dc 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberGeneratorTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberGeneratorTest.java
@@ -28,13 +28,13 @@
import static org.testng.Assert.*;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ChangeNumberGenerator;
import org.opends.server.util.TimeThread;
import org.testng.annotations.Test;
-public class ChangeNumberGeneratorTest extends SynchronizationTestCase
+public class ChangeNumberGeneratorTest extends ReplicationTestCase
{
/**
* Test the adjust method of ChangeNumberGenerator
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberTest.java
index 25ca2e0..ceba812 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ChangeNumberTest.java
@@ -31,7 +31,7 @@
import static org.testng.Assert.*;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ChangeNumberGenerator;
import org.opends.server.util.TimeThread;
@@ -40,7 +40,7 @@
/**
* Test ChangeNumber and ChangeNumberGenerator
*/
-public class ChangeNumberTest extends SynchronizationTestCase
+public class ChangeNumberTest extends ReplicationTestCase
{
/**
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ServerStateTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ServerStateTest.java
index 78da8ff..787bfed 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ServerStateTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/common/ServerStateTest.java
@@ -30,7 +30,7 @@
import java.util.Set;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ServerState;
import org.opends.server.util.TimeThread;
@@ -40,7 +40,7 @@
/**
* Test the ServerState
*/
-public class ServerStateTest extends SynchronizationTestCase
+public class ServerStateTest extends ReplicationTestCase
{
/**
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/AttrInfoTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/AttrInfoTest.java
index 4ae2496..92a7307 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/AttrInfoTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/AttrInfoTest.java
@@ -30,7 +30,7 @@
import java.util.LinkedHashSet;
import org.opends.server.core.DirectoryServer;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.plugin.AttrInfo;
import org.opends.server.replication.plugin.ValueInfo;
@@ -45,7 +45,7 @@
* Test AttrInfo and AttrInfoWithOptions
*/
public class AttrInfoTest
- extends SynchronizationTestCase
+ extends ReplicationTestCase
{
/**
* Build some data for the AttrInfo test below.
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java
index acb7622..58e7000 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/HistoricalTest.java
@@ -27,7 +27,7 @@
package org.opends.server.replication.plugin;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.plugin.ChangelogBroker;
import org.opends.server.replication.plugin.Historical;
@@ -53,10 +53,10 @@
* Tests the Historical class.
*/
public class HistoricalTest
- extends SynchronizationTestCase
+ extends ReplicationTestCase
{
/**
- * Set up synchronization on the test backend.
+ * Set up replication on the test backend.
* @throws Exception If an error occurs.
*/
@BeforeClass
@@ -69,7 +69,7 @@
// Create an internal connection.
connection = InternalClientConnection.getRootConnection();
- // The synchronization server.
+ // The replication server.
String changeLogStringDN = "cn=Changelog Server, " + synchroPluginStringDN;
String changeLogLdif = "dn: " + changeLogStringDN + "\n"
+ "objectClass: top\n"
@@ -90,7 +90,7 @@
+ "ds-cfg-receive-status: true\n";
synchroServerEntry = TestCaseUtils.entryFromLdifString(synchroServerLdif);
- configureSynchronization();
+ configureReplication();
}
/**
@@ -177,7 +177,7 @@
/**
* The scenario for this test case is that two modify operations occur at
* two different servers at nearly the same time, each operation adding a
- * different value for a single-valued attribute. Synchronization then
+ * different value for a single-valued attribute. Replication then
* replays the operations and we expect the conflict to be resolved on both
* servers by keeping whichever value was actually added first.
* For the unit test, we employ a single directory server. We use the
@@ -260,7 +260,7 @@
// It would be nice to avoid these sleeps.
// We need to preserve the replay order but the order could be changed
- // due to the multi-threaded nature of the synchronization replay.
+ // due to the multi-threaded nature of the replication replay.
// Putting a sentinel value in the modification is not foolproof since
// the operation might not get replayed at all.
Thread.sleep(2000);
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ModifyConflictTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ModifyConflictTest.java
index 821b1ab..89cc688 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ModifyConflictTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ModifyConflictTest.java
@@ -43,13 +43,13 @@
import org.opends.server.core.ModifyOperation;
import org.opends.server.protocols.asn1.ASN1OctetString;
import org.opends.server.protocols.internal.InternalClientConnection;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.plugin.FakeOperation;
import org.opends.server.replication.plugin.FakeOperationComparator;
import org.opends.server.replication.plugin.Historical;
import org.opends.server.replication.protocol.ModifyContext;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.replication.protocol.UpdateMessage;
import org.opends.server.types.Attribute;
import org.opends.server.types.AttributeType;
@@ -72,7 +72,7 @@
*/
public class ModifyConflictTest
- extends SynchronizationTestCase
+ extends ReplicationTestCase
{
/**
@@ -245,7 +245,7 @@
FakeOperation fk = fks.iterator().next();
assertTrue(new FakeOperationComparator().compare(fk, fk) == 0);
assertTrue(new FakeOperationComparator().compare(null , fk) < 0);
- SynchronizationMessage generatedMsg = fk.generateMessage() ;
+ ReplicationMessage generatedMsg = fk.generateMessage() ;
if (generatedMsg instanceof UpdateMessage)
{
UpdateMessage new_name = (UpdateMessage) generatedMsg;
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentServerStateTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentServerStateTest.java
index 23e0bcb..9322b2a 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentServerStateTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentServerStateTest.java
@@ -31,7 +31,7 @@
import org.opends.server.TestCaseUtils;
import org.opends.server.core.AddOperation;
import org.opends.server.protocols.internal.InternalClientConnection;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ChangeNumberGenerator;
import org.opends.server.replication.plugin.PersistentServerState;
@@ -44,7 +44,7 @@
/**
* Test the PersistentServerState class.
*/
-public class PersistentServerStateTest extends SynchronizationTestCase
+public class PersistentServerStateTest extends ReplicationTestCase
{
/**
* Set up the environment for performing the tests in this suite.
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentStateTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentStateTest.java
index e8cdfd6..89fab16 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentStateTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/PersistentStateTest.java
@@ -31,7 +31,7 @@
import org.opends.server.TestCaseUtils;
import org.opends.server.core.AddOperation;
import org.opends.server.protocols.internal.InternalClientConnection;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ChangeNumberGenerator;
import org.opends.server.replication.plugin.PersistentServerState;
@@ -44,7 +44,7 @@
/**
* Test the PersistentServerState class.
*/
-public class PersistentStateTest extends SynchronizationTestCase
+public class PersistentStateTest extends ReplicationTestCase
{
/**
* Set up the environment for performing the tests in this suite.
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ValueInfoTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ValueInfoTest.java
index f96c452..91d92fd 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ValueInfoTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/ValueInfoTest.java
@@ -27,7 +27,7 @@
package org.opends.server.replication.plugin;
import org.opends.server.core.DirectoryServer;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.plugin.ValueInfo;
import org.opends.server.types.AttributeType;
@@ -41,7 +41,7 @@
/**
* Test of ValueInfo
*/
-public class ValueInfoTest extends SynchronizationTestCase
+public class ValueInfoTest extends ReplicationTestCase
{
/**
* Build some data for the ValueInfo test below.
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/protocol/SynchronizationMsgTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/protocol/SynchronizationMsgTest.java
index e72dc10..cf36ccc 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/protocol/SynchronizationMsgTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/protocol/SynchronizationMsgTest.java
@@ -44,7 +44,7 @@
import org.opends.server.core.ModifyDNOperation;
import org.opends.server.core.ModifyOperation;
import org.opends.server.protocols.internal.InternalClientConnection;
-import org.opends.server.replication.SynchronizationTestCase;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ServerState;
import org.opends.server.replication.plugin.PendingChange;
@@ -64,7 +64,7 @@
import org.opends.server.replication.protocol.ModifyMsg;
import org.opends.server.replication.protocol.OperationContext;
import org.opends.server.replication.protocol.ServerStartMessage;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
import org.opends.server.replication.protocol.UpdateMessage;
import org.opends.server.replication.protocol.WindowMessage;
import org.opends.server.types.Attribute;
@@ -84,7 +84,7 @@
* Test the contructors, encoders and decoders of the synchronization
* AckMsg, ModifyMsg, ModifyDnMsg, AddMsg and Delete Msg
*/
-public class SynchronizationMsgTest extends SynchronizationTestCase
+public class SynchronizationMsgTest extends ReplicationTestCase
{
/**
* Build some data for the ModifyMsg test below.
@@ -165,7 +165,7 @@
InternalClientConnection connection =
InternalClientConnection.getRootConnection();
ModifyMsg msg = new ModifyMsg(changeNumber, dn, mods, "fakeuniqueid");
- ModifyMsg generatedMsg = (ModifyMsg) SynchronizationMessage
+ ModifyMsg generatedMsg = (ModifyMsg) ReplicationMessage
.generateMsg(msg.getBytes());
@@ -214,7 +214,7 @@
assertTrue(msg.isAssured());
// Check equals
- ModifyMsg generatedMsg = (ModifyMsg) SynchronizationMessage
+ ModifyMsg generatedMsg = (ModifyMsg) ReplicationMessage
.generateMsg(msg.getBytes());
assertFalse(msg.equals(null));
assertFalse(msg.equals(new Object()));
@@ -264,7 +264,7 @@
(short) 123, (short) 45);
op.setAttachment(SYNCHROCONTEXT, new DeleteContext(cn, "uniqueid"));
DeleteMsg msg = new DeleteMsg(op);
- DeleteMsg generatedMsg = (DeleteMsg) SynchronizationMessage
+ DeleteMsg generatedMsg = (DeleteMsg) ReplicationMessage
.generateMsg(msg.getBytes());
assertEquals(msg.toString(), generatedMsg.toString());
@@ -314,7 +314,7 @@
op.setAttachment(SYNCHROCONTEXT,
new ModifyDnContext(cn, "uniqueid", "newparentId"));
ModifyDNMsg msg = new ModifyDNMsg(op);
- ModifyDNMsg generatedMsg = (ModifyDNMsg) SynchronizationMessage
+ ModifyDNMsg generatedMsg = (ModifyDNMsg) ReplicationMessage
.generateMsg(msg.getBytes());
Operation generatedOperation = generatedMsg.createOperation(connection);
ModifyDNOperation mod2 = (ModifyDNOperation) generatedOperation;
@@ -381,7 +381,7 @@
AddMsg msg = new AddMsg(cn, rawDN, "thisIsaUniqueID", "parentUniqueId",
objectClass, userAttributes,
operationalAttributes);
- AddMsg generatedMsg = (AddMsg) SynchronizationMessage.generateMsg(msg
+ AddMsg generatedMsg = (AddMsg) ReplicationMessage.generateMsg(msg
.getBytes());
assertEquals(msg.getBytes(), generatedMsg.getBytes());
assertEquals(msg.toString(), generatedMsg.toString());
@@ -453,7 +453,7 @@
// Check invalid bytes for constructor
byte[] b = msg1.getBytes();
- b[0] = SynchronizationMessage.MSG_TYPE_ADD_REQUEST ;
+ b[0] = ReplicationMessage.MSG_TYPE_ADD_REQUEST ;
try
{
// This should generated an exception
@@ -466,7 +466,7 @@
}
// Check that retrieved CN is OK
- msg2 = (AckMessage) SynchronizationMessage.generateMsg(msg1.getBytes());
+ msg2 = (AckMessage) ReplicationMessage.generateMsg(msg1.getBytes());
}
@DataProvider(name="serverStart")
@@ -641,7 +641,7 @@
/**
* Test PendingChange
*/
- private void testPendingChange(ChangeNumber cn, Operation op, SynchronizationMessage msg)
+ private void testPendingChange(ChangeNumber cn, Operation op, ReplicationMessage msg)
{
if (! (msg instanceof UpdateMessage))
{
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/ChangelogFakeConfiguration.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogFakeConfiguration.java
similarity index 98%
rename from opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/ChangelogFakeConfiguration.java
rename to opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogFakeConfiguration.java
index b6a86ef..ee96544 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/ChangelogFakeConfiguration.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogFakeConfiguration.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.util.SortedSet;
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/ChangelogTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogTest.java
similarity index 97%
rename from opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/ChangelogTest.java
rename to opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogTest.java
index ee22cde..6915803 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/ChangelogTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/ChangelogTest.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import static org.testng.Assert.assertTrue;
import static org.testng.Assert.fail;
@@ -39,8 +39,7 @@
import org.opends.server.TestCaseUtils;
import org.opends.server.core.ModifyDNOperation;
-import org.opends.server.replication.SynchronizationTestCase;
-import org.opends.server.replication.changelog.Changelog;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ChangeNumberGenerator;
import org.opends.server.replication.common.ServerState;
@@ -50,7 +49,8 @@
import org.opends.server.replication.protocol.ModifyDNMsg;
import org.opends.server.replication.protocol.ModifyDnContext;
import org.opends.server.replication.protocol.ModifyMsg;
-import org.opends.server.replication.protocol.SynchronizationMessage;
+import org.opends.server.replication.protocol.ReplicationMessage;
+import org.opends.server.replication.server.Changelog;
import org.opends.server.types.Attribute;
import org.opends.server.types.DN;
import org.opends.server.types.Entry;
@@ -66,7 +66,7 @@
* Tests for the changelog service code.
*/
-public class ChangelogTest extends SynchronizationTestCase
+public class ChangelogTest extends ReplicationTestCase
{
/**
* The changelog server that will be used in this test.
@@ -162,7 +162,7 @@
new DeleteMsg("o=test,dc=example,dc=com", firstChangeNumberServer1,
"uid");
server1.publish(msg);
- SynchronizationMessage msg2 = server2.receive();
+ ReplicationMessage msg2 = server2.receive();
if (msg2 instanceof DeleteMsg)
{
DeleteMsg del = (DeleteMsg) msg2;
@@ -242,7 +242,7 @@
openChangelogSession(DN.decode("dc=example,dc=com"), (short) 3,
100, changelogPort, 1000, false);
- SynchronizationMessage msg2 = broker.receive();
+ ReplicationMessage msg2 = broker.receive();
if (!(msg2 instanceof DeleteMsg))
fail("Changelog basic transmission failed");
else
@@ -279,7 +279,7 @@
openChangelogSession(DN.decode("dc=example,dc=com"), (short) 3,
100, changelogPort, 1000, state);
- SynchronizationMessage msg2 = broker.receive();
+ ReplicationMessage msg2 = broker.receive();
if (!(msg2 instanceof DeleteMsg))
fail("Changelog basic transmission failed");
else
@@ -685,7 +685,7 @@
// - Check msg receives by broker, through changeLog2
while (ts > 1)
{
- SynchronizationMessage msg2;
+ ReplicationMessage msg2;
try
{
msg2 = broker2.receive();
@@ -787,7 +787,7 @@
{
while (true)
{
- SynchronizationMessage msg = broker.receive();
+ ReplicationMessage msg = broker.receive();
if (msg == null)
break;
}
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/UpdateComparatorTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/UpdateComparatorTest.java
similarity index 92%
rename from opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/UpdateComparatorTest.java
rename to opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/UpdateComparatorTest.java
index a35a79f..cc57d13 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/UpdateComparatorTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/UpdateComparatorTest.java
@@ -24,7 +24,7 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;
@@ -35,12 +35,12 @@
import org.opends.server.core.DeleteOperation;
import org.opends.server.protocols.internal.InternalClientConnection;
-import org.opends.server.replication.SynchronizationTestCase;
-import org.opends.server.replication.changelog.UpdateComparator;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.protocol.DeleteContext;
import org.opends.server.replication.protocol.DeleteMsg;
import org.opends.server.replication.protocol.UpdateMessage;
+import org.opends.server.replication.server.UpdateComparator;
import org.opends.server.types.DirectoryException;
import org.opends.server.types.DN;
import org.opends.server.util.TimeThread;
@@ -50,7 +50,7 @@
/**
* Test ChangeNumber and ChangeNumberGenerator
*/
-public class UpdateComparatorTest extends SynchronizationTestCase
+public class UpdateComparatorTest extends ReplicationTestCase
{
/**
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/dbHandlerTest.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/dbHandlerTest.java
similarity index 91%
rename from opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/dbHandlerTest.java
rename to opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/dbHandlerTest.java
index 87851c8..c5a19de 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/changelog/dbHandlerTest.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/server/dbHandlerTest.java
@@ -24,19 +24,19 @@
*
* Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
-package org.opends.server.replication.changelog;
+package org.opends.server.replication.server;
import java.io.File;
import java.net.ServerSocket;
import org.opends.server.TestCaseUtils;
-import org.opends.server.replication.SynchronizationTestCase;
-import org.opends.server.replication.changelog.Changelog;
-import org.opends.server.replication.changelog.ChangelogDbEnv;
-import org.opends.server.replication.changelog.DbHandler;
+import org.opends.server.replication.ReplicationTestCase;
import org.opends.server.replication.common.ChangeNumber;
import org.opends.server.replication.common.ChangeNumberGenerator;
import org.opends.server.replication.protocol.DeleteMsg;
+import org.opends.server.replication.server.Changelog;
+import org.opends.server.replication.server.ChangelogDbEnv;
+import org.opends.server.replication.server.DbHandler;
import org.opends.server.types.DN;
import org.testng.annotations.Test;
import static org.testng.Assert.*;
@@ -44,7 +44,7 @@
/**
* Test the dbHandler class
*/
-public class dbHandlerTest extends SynchronizationTestCase
+public class dbHandlerTest extends ReplicationTestCase
{
@Test()
void testDbHandlerTrim() throws Exception
--
Gitblit v1.10.0