You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Simon Bence (Jira)" <ji...@apache.org> on 2023/10/10 07:58:00 UTC

[jira] [Created] (NIFI-12203) JSON Sync does not delete controller level items

Simon Bence created NIFI-12203:
----------------------------------

             Summary: JSON Sync does not delete controller level items
                 Key: NIFI-12203
                 URL: https://issues.apache.org/jira/browse/NIFI-12203
             Project: Apache NiFi
          Issue Type: Bug
          Components: Core Framework
    Affects Versions: 2.0.0
            Reporter: Simon Bence


JSON based flow synchronization looks to behave differently than XML in regards of controllel level components: while XML cleans up "removed" components from the current flow, the JSON keeps them. This happens in case of [JoinClusterWithDifferentFlow|https://github.com/apache/nifi/blob/main/nifi-system-tests/nifi-system-test-suite/src/test/java/org/apache/nifi/tests/system/clustering/JoinClusterWithDifferentFlow.java#L240] where components within the root group are "replaced" as the tests expects but the controller level Controller Service is not.

Running the test using JSON synchronizer results two Controller Services in the memory representation of the flow definition on node 2: both the services from flow1 and flow2 are part of the synced flow.

After some testing, it looks like  [this|https://github.com/apache/nifi/blob/main/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/serialization/VersionedFlowSynchronizer.java#L900] method and other methods in the "inherit*" method family will not clean up components are not present in the proposed flow.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)