[ https://issues.apache.org/jira/browse/NIFI-2267?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15379322#comment-15379322 ]
ASF GitHub Bot commented on NIFI-2267: -------------------------------------- GitHub user ijokarumawak opened a pull request: https://github.com/apache/nifi/pull/657 NIFI-2267: A way for Processor to know node type - Added NodeTypeProvider to expose flowController's isClustered and isPrimaryNode so that processor can know if it's running on a cluster and if it's a primary node. - Added mechanism to simulate clustered or not, and primary or not, for testing You can merge this pull request into a Git repository by running: $ git pull https://github.com/ijokarumawak/nifi nifi-2267 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/nifi/pull/657.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #657 ---- commit 2895159caabc1a28688208268173e6fcadc7d4bf Author: Koji Kawamura <ijokaruma...@gmail.com> Date: 2016-07-15T12:16:54Z NIFI-2267: A way for Processor to know node type - Added NodeTypeProvider to expose flowController's isClustered and isPrimaryNode so that processor can know if it's running on a cluster and if it's a primary node. - Added mechanism to simulate clustered or not, and primary or not, for testing ---- > Provide a way for Processor to determine running NiFi node type - > standalone/clustered, primary/node > ---------------------------------------------------------------------------------------------------- > > Key: NIFI-2267 > URL: https://issues.apache.org/jira/browse/NIFI-2267 > Project: Apache NiFi > Issue Type: Improvement > Components: Core Framework > Affects Versions: 1.0.0 > Reporter: Koji Kawamura > Assignee: Koji Kawamura > Fix For: 1.0.0 > > > Currently, there's no way for processor to understand if it's running on: > - Standalone or Cluster? > - If in a cluster, is it a Primary node or not? > There're processors that need this information to provide more cluster > friendly behavior, such as MonitorActivity. > @OnPrimaryNodeStateChange annotation is already available. However, it's > notified only when a primary node has been changed. So, If a processor is > added to an existing NiFi cluster, which has already one node elected as a > primary node, the processor is not notified, thus it won't be able to know > it's a primary node. > This ticket is meant for tracking the effort of adding such capability to > provide node type information. -- This message was sent by Atlassian JIRA (v6.3.4#6332)