Github user markap14 commented on the issue:
https://github.com/apache/nifi/pull/900
Thanks for reviewing guys. I did just push a new commit, because I noticed
some weirdness. When starting up, sometimes nodes would log that there is a
cluster coordinator when there actually was not. It appears that if
non-Coordinator nodes that are running an embedded zookeeper are shutdown (or
an external zookeeper is shutdown), and then coordinator is shutdown, the
coordinator's address is persisted in ZooKeeper. So if ZK and the cluster are
restarted, the nodes would think there is a coordinator when there is not. They
would then all fail to connect to the cluster because the ZNode that held the
coordinator address would be deleted when ZK/Curator realized that the node is
no longer connected. As a result, there would be no Cluster Coordinator and no
node would register for the role because they all thought one was elected
previously.
This new commit addresses this by detected the condition in
StandardFlowService and then registering for the role.
You will note that a lot of files changed for this. This is because I
needed to move the NoClusterCoordinatorException from
nifi-framework-cluster-protocol to nifi-framework-api and the package name
changed to reflect a more accurate package, so imports were changed in several
files.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---