From 3af1c93c0de41be1cdfc0e6aff1d1c98f1d5530b Mon Sep 17 00:00:00 2001
From: mrossign <mrossign@localhost>
Date: Tue, 07 Jul 2009 09:15:52 +0000
Subject: [PATCH] Fractional replication Info about the feature: https://www.opends.org/wiki/page/FractionalReplication
---
opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/DomainFakeCfg.java | 38 ++++++++++++++++++++++++++++++++++++++
1 files changed, 38 insertions(+), 0 deletions(-)
diff --git a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/DomainFakeCfg.java b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/DomainFakeCfg.java
index 92161f0..6f2ffbf 100644
--- a/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/DomainFakeCfg.java
+++ b/opends/tests/unit-tests-testng/src/server/org/opends/server/replication/plugin/DomainFakeCfg.java
@@ -26,6 +26,7 @@
*/
package org.opends.server.replication.plugin;
+import java.util.List;
import java.util.SortedSet;
import java.util.TreeSet;
@@ -63,6 +64,9 @@
// Referrals urls to be published to other servers of the topology
SortedSet<String> refUrls = new TreeSet<String>();
+ private SortedSet<String> fractionalExcludes = new TreeSet<String>();
+ private SortedSet<String> fractionalIncludes = new TreeSet<String>();
+
/**
* Creates a new Domain with the provided information
* (assured mode disabled, default group id)
@@ -76,6 +80,30 @@
/**
* Creates a new Domain with the provided information
+ * (with some fractional configuration provided)
+ */
+ public DomainFakeCfg(DN baseDn, int serverId, SortedSet<String> replServers,
+ List<String> fractionalExcludes, List<String> fractionalIncludes)
+ {
+ this(baseDn, serverId, replServers);
+ if (fractionalExcludes != null)
+ {
+ for (String str : fractionalExcludes)
+ {
+ this.fractionalExcludes.add(str);
+ }
+ }
+ if (fractionalIncludes != null)
+ {
+ for (String str : fractionalIncludes)
+ {
+ this.fractionalIncludes.add(str);
+ }
+ }
+ }
+
+ /**
+ * Creates a new Domain with the provided information
* (assured mode disabled, group id provided)
*/
public DomainFakeCfg(DN baseDn, int serverId, SortedSet<String> replServers,
@@ -305,4 +333,14 @@
{
return refUrls;
}
+
+ public SortedSet<String> getFractionalExclude()
+ {
+ return fractionalExcludes;
+ }
+
+ public SortedSet<String> getFractionalInclude()
+ {
+ return fractionalIncludes;
+ }
}
--
Gitblit v1.10.0