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

Oleg Zhurakousky commented on NIFI-1464:
----------------------------------------

Note to self:
Not sure if it's worth opening another JIRA as a sub-task, but there is another 
bug with current lifecycle of Processor. Basically unlike ControllerServices 
that have 4 states, Processors only have two (STOPPED/RUNNING) which 
essentially by-passes the two transition states (STARTING/STOPPING). That 
allows Start to be called while the Processor may be stopping and Stop called 
while the Processor is starting and other combinations. Fortunately since our 
current interaction with these methods is only through UI, this doesn't create 
an immediate problem (hence no need for new JIRA), however, from the pure 
framework perspective it's very loose.
In any event, it is being addressed similar to the way ControllerServices 
lifecycle was addressed in NIFI-1164. I am also introducing two additional 
transitionary states (STARTING/STOPPING) which will help to manage the atomic 
nature of these operations without introducing unnecessary locks.

> Refactor lifecycle code for Processors and other components
> -----------------------------------------------------------
>
>                 Key: NIFI-1464
>                 URL: https://issues.apache.org/jira/browse/NIFI-1464
>             Project: Apache NiFi
>          Issue Type: Improvement
>            Reporter: Oleg Zhurakousky
>            Assignee: Oleg Zhurakousky
>             Fix For: 0.6.0
>
>
> Similar lifecycle handling improvements that went in as part of the NIFI-1164 
> for ControllerServices, could/should be applied to other  components (e..g, 
> Processors).
> The improvements may also help to address NIFI-78 (may be without killing the 
> thread).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to