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

Rakesh Kumar Singh reassigned NIFI-15883:
-----------------------------------------

    Assignee: Rakesh Kumar Singh

> Wait/Notify Processing have a race condition while updating the Cache
> ---------------------------------------------------------------------
>
>                 Key: NIFI-15883
>                 URL: https://issues.apache.org/jira/browse/NIFI-15883
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Extensions
>    Affects Versions: 1.15.3, 2.1.0, 2.9.0
>            Reporter: Sheel Chand
>            Assignee: Rakesh Kumar Singh
>            Priority: Critical
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> Nifi Processor Wait calls the protocol.replace function without checking the 
> return value - true or false. The replace() method may fail if a Notify 
> processor has updated the counters since the last fetch() by the Wait 
> Processor. As a result some updates are lost specially in a high concurrency 
> case. If you have a counter to wait for a number of ACKS before releasing the 
> files, the counter keeps increasing because the decrements by the Wait 
> Processor get lost.
> The same issue with the entry removal.  The protocol.complete() method 
> removes the entry without going through the Cache Protocol Version 2. So, it 
> may remove an entry even if a Notify processor has updated counters since the 
> last fetch().
> The notify function in WaitNotifyPortocol.java does the right thing by 
> retrying multiple times if the replace() method returns false.
> Wait Processor needs to be fixed to implement Cache Protocol Version 2 for 
> replace and complete() methods.



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

Reply via email to