[ 
https://issues.apache.org/jira/browse/NIFI-16229?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Sevag Keosseian updated NIFI-16229:
-----------------------------------
    Fix Version/s: 2.12.0
           Status: Patch Available  (was: Open)

> Clustered Parameter Context update rejects inherited asset-backed Parameter
> ---------------------------------------------------------------------------
>
>                 Key: NIFI-16229
>                 URL: https://issues.apache.org/jira/browse/NIFI-16229
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Core Framework
>    Affects Versions: 2.11.0
>         Environment: Observed in clustered Apache NiFi 2.11.0 behavior. 
> Reproduced using the NiFi system-test framework in a two-node cluster. The 
> equivalent standalone system test succeeds.
>            Reporter: Sevag Keosseian
>            Assignee: Sevag Keosseian
>            Priority: Major
>             Fix For: 2.12.0
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> A Parameter Context update fails in clustered NiFi when an existing child 
> Parameter Context is updated to inherit a parent containing an asset-backed 
> Parameter.
> Steps to reproduce:
> 1. Create a parent Parameter Context with a Parameter such as `Key File`.
> 2. Upload an Asset to the parent context and configure `Key File` to 
> reference it.
> 3. Create a separate child Parameter Context.
> 4. Update the child to inherit the parent.
> Expected behavior:
> The child inherits the Parameter and can use the Asset owned by the source 
> parent context.
> Actual behavior:
> The clustered update fails with an error similar to:
> `Parameter [Key File] is not allowed to reference asset [key.p8] which does 
> not belong to parameter context [child-context-id]`
> The initial update calculates the inherited effective Parameter correctly. In 
> clustered mode, the enriched DTO is replicated to the nodes and effective 
> Parameter updates are calculated a second time. The existing logic infers 
> that a Parameter is inherited when it is absent from the incoming DTO. 
> Because the first pass inserts the inherited Parameter into the DTO, the 
> second pass incorrectly reclassifies it as local. Asset ownership validation 
> then rejects the parent-owned Asset as though it were referenced by a locally 
> defined child Parameter.
> Standalone NiFi succeeds because the update does not use the replicated 
> cluster path.
> The proposed correction is to classify a non-null effective Parameter using 
> its source Parameter Context ID rather than DTO membership. A Parameter is 
> inherited when its source context differs from the context being updated. 
> Existing handling for effective Parameter removals remains unchanged.
> Regression coverage should include both standalone and clustered updates, 
> repeated submission of the effective DTO, removal of an inherited asset 
> context, and rejection of a genuinely local Parameter referencing an Asset 
> owned by another context.



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

Reply via email to