You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nifi.apache.org by Joe Percivall <jo...@yahoo.com.INVALID> on 2015/09/16 17:03:10 UTC

Checking Primary Node Scheduling in Processor

Hey Dev,

Is there a way for a processor to check if the scheduling is primary node only and if it's being run on the primary node? The developer guide doesn't mention anything about "primary node".

Thanks,
Joe- - - - - - 
Joseph Percivall
linkedin.com/in/Percivall
e: joepercivall@yahoo.com

Re: Checking Primary Node Scheduling in Processor

Posted by Joe Percivall <jo...@yahoo.com.INVALID>.
Mark,

Awesome. I created a ticket[1] to add the scheduling strategy to the ProcessContext.

Also I just created another ticket to add documentation for cluster environments and Primary Node Scheduling to the User and Dev Guide[2].

Thanks,
Joe

[1] https://issues.apache.org/jira/browse/NIFI-966
[2] https://issues.apache.org/jira/browse/NIFI-968
 - - - - - - 
Joseph Percivall
linkedin.com/in/Percivall
e: joepercivall@yahoo.com




On Wednesday, September 16, 2015 12:33 PM, Mark Payne <ma...@hotmail.com> wrote:
Joe,

There is an annotation that can be used : @OnPrimaryNodeStateChange that will allow the processor to be notified when the node it's running on is elected primary node or when this role is revoked.

However, there's nothing right now that exposes the Scheduling Strategy (Timer Driven, Chron Driven, Primary Node Only, Event Driven). This should probably be exposed in the ProcessContext.

Thanks
-Mark



> On Sep 16, 2015, at 11:03 AM, Joe Percivall <jo...@yahoo.com.INVALID> wrote:
> 
> Hey Dev,
> 
> Is there a way for a processor to check if the scheduling is primary node only and if it's being run on the primary node? The developer guide doesn't mention anything about "primary node".
> 
> Thanks,
> Joe- - - - - - 
> Joseph Percivall
> linkedin.com/in/Percivall
> e: joepercivall@yahoo.com

Re: Checking Primary Node Scheduling in Processor

Posted by Mark Payne <ma...@hotmail.com>.
Joe,

There is an annotation that can be used : @OnPrimaryNodeStateChange that will allow the processor to be notified when the node it's running on is elected primary node or when this role is revoked.

However, there's nothing right now that exposes the Scheduling Strategy (Timer Driven, Chron Driven, Primary Node Only, Event Driven). This should probably be exposed in the ProcessContext.

Thanks
-Mark


> On Sep 16, 2015, at 11:03 AM, Joe Percivall <jo...@yahoo.com.INVALID> wrote:
> 
> Hey Dev,
> 
> Is there a way for a processor to check if the scheduling is primary node only and if it's being run on the primary node? The developer guide doesn't mention anything about "primary node".
> 
> Thanks,
> Joe- - - - - - 
> Joseph Percivall
> linkedin.com/in/Percivall
> e: joepercivall@yahoo.com