[ 
https://issues.apache.org/jira/browse/NIFI-14283?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17929847#comment-17929847
 ] 

ASF subversion and git services commented on NIFI-14283:
--------------------------------------------------------

Commit 96eea40601948dbe30d4df7b5f7a667cb997d591 in nifi's branch 
refs/heads/main from Dariusz Seweryn
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=96eea40601 ]

NIFI-14283 Switched to non-static workerLock for ConsumeKinesisStream (#9737)

Signed-off-by: David Handermann <[email protected]>

> ConsumeKinesisStream non-static lock
> ------------------------------------
>
>                 Key: NIFI-14283
>                 URL: https://issues.apache.org/jira/browse/NIFI-14283
>             Project: Apache NiFi
>          Issue Type: Improvement
>          Components: Extensions
>    Affects Versions: 2.2.0
>            Reporter: Dariusz Seweryn
>            Priority: Trivial
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> ConsumeKinesisStream processor contains:
> ```
> private static final Object WORKER_LOCK = new Object();
> ```
>  
> This object is used for synchronizing blocks of code in:
>  * `onTrigger` where it guards generation of SchedulerId, creating a 
> Scheduler and starting a Thread that runs the Scheduler
>  * `@OnStopped stopConsuming` where the scheduler is shut down and instance's 
> `workerState` removed
>  
> There is no apparent static state touched in the synchronized block of code 
> therefore the lock can be turned into an instance field.



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

Reply via email to