From 5379f4a2c7666c33bc2f8d49ec4de02e2a849bd1 Mon Sep 17 00:00:00 2001
From: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Date: Thu, 02 Apr 2026 09:26:01 +0000
Subject: [PATCH] Merge remote-tracking branch 'origin/master' into copilot/fix-referential-integrity-plugin-bug Co-authored-by: vharseko <6818498+vharseko@users.noreply.github.com>
---
opendj-server-legacy/src/test/java/org/opends/server/replication/GenerationIdTest.java | 22 ++++++++++++++++++++--
1 files changed, 20 insertions(+), 2 deletions(-)
diff --git a/opendj-server-legacy/src/test/java/org/opends/server/replication/GenerationIdTest.java b/opendj-server-legacy/src/test/java/org/opends/server/replication/GenerationIdTest.java
index b452ce0..84c9b1b 100644
--- a/opendj-server-legacy/src/test/java/org/opends/server/replication/GenerationIdTest.java
+++ b/opendj-server-legacy/src/test/java/org/opends/server/replication/GenerationIdTest.java
@@ -921,7 +921,7 @@
replServer3 = createReplicationServer(replServerId3, true, testCase);
connectServer1ToReplServer(replServer1);
- Thread.sleep(2000); //wait for all RS handshakes to complete
+ waitForDomainsOnAllReplicationServers();
debugInfo("Expect genId are set in all replServers.");
waitForStableGenerationId(EMPTY_DN_GENID);
@@ -990,7 +990,7 @@
}
}
- private void waitForStableGenerationId(final long expectedGenId) throws Exception
+ private void waitForDomainsOnAllReplicationServers() throws Exception
{
TestTimer timer = new TestTimer.Builder()
.maxSleep(30, SECONDS)
@@ -1001,6 +1001,24 @@
@Override
public void call() throws Exception
{
+ assertNotNull(replServer1.getReplicationServerDomain(baseDN), "domain missing on replServer1");
+ assertNotNull(replServer2.getReplicationServerDomain(baseDN), "domain missing on replServer2");
+ assertNotNull(replServer3.getReplicationServerDomain(baseDN), "domain missing on replServer3");
+ }
+ });
+ }
+
+ private void waitForStableGenerationId(final long expectedGenId) throws Exception
+ {
+ TestTimer timer = new TestTimer.Builder()
+ .maxSleep(60, SECONDS)
+ .sleepTimes(100, MILLISECONDS)
+ .toTimer();
+ timer.repeatUntilSuccess(new CallableVoid()
+ {
+ @Override
+ public void call() throws Exception
+ {
assertGenIdEquals(expectedGenId);
}
});
--
Gitblit v1.10.0