You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "markap14 (via GitHub)" <gi...@apache.org> on 2026/10/08 15:05:02 UTC

Re: [PR] NIFI-16351 - Prevent Flow Registry synchronization failures during startup validation [nifi]

markap14 commented on code in PR #11684:
URL: https://github.com/apache/nifi/pull/11684#discussion_r4220648796


##########
nifi-system-tests/nifi-system-test-suite/src/test/java/org/apache/nifi/tests/system/registry/RegistryClientIT.java:
##########
@@ -364,6 +377,24 @@ public void testStartVersionControlThenModifyAndRevert() throws NiFiClientExcept
         assertEquals("UP_TO_DATE", versionedFlowState);
     }
 
+    @Test
+    public void testVersionControlledProcessGroupSynchronizesAfterRestart() throws Exception {
+        final FlowRegistryClientEntity registryClient = registerClient();
+        final ProcessGroupEntity processGroup = getClientUtil().createProcessGroup("Versioned Process Group", "root");
+        getClientUtil().createProcessor("TerminateFlowFile", processGroup.getId());
+        getClientUtil().startVersionControl(processGroup, registryClient, TEST_FLOWS_BUCKET, "restart-flow");
+
+        assertEquals(VersionControlInformationDTO.UP_TO_DATE, getClientUtil().getVersionControlState(processGroup.getId()));
+
+        getClientUtil().updateRegistryClientProperties(registryClient, Collections.singletonMap("Validate Sleep Time", "15 sec"));
+
+        getNiFiInstance().stop();
+        getNiFiInstance().start();
+        setupClient();

Review Comment:
   [GPT-5.6 Sol] Pierre, this test is also inherited by `ClusteredRegistryClientIT`. After restarting the cluster, it calls `setupClient()` and immediately reads the version-control state without waiting for all nodes to reconnect, even though the normal test setup waits for that. I think this can race cluster startup and either return a partial view or fail while a node is still joining. Do you agree that this test should call `waitForAllNodesConnected()` here when it is running in clustered mode?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org