You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Joseph Niemiec (JIRA)" <ji...@apache.org> on 2017/07/11 17:26:00 UTC

[jira] [Commented] (NIFI-3680) Zookeeper ZNodes for NiFi LeaderElection shouldn't use spaces for ease of use

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

Joseph Niemiec commented on NIFI-3680:
--------------------------------------

Just some more detail, it appears zkCli parses commands using a space as a split key.

https://github.com/apache/zookeeper/blob/b9beabf5cfbb8e447f67a8050486ca2821132f61/src/java/main/org/apache/zookeeper/ZooKeeperMain.java#L156

> Zookeeper ZNodes for NiFi LeaderElection shouldn't use spaces for ease of use
> -----------------------------------------------------------------------------
>
>                 Key: NIFI-3680
>                 URL: https://issues.apache.org/jira/browse/NIFI-3680
>             Project: Apache NiFi
>          Issue Type: Improvement
>    Affects Versions: 1.1.1
>         Environment: Ubuntu 14, Oracle JDK 1.8.0_77, 3 Node cluster, Zookeeper 3.4.6 [2.5.3.0-37]
>            Reporter: Joseph Niemiec
>            Priority: Trivial
>
> When navigating the ZKCli for problems the current naming of ZNodes for leader-election isn't easy to navigate. Noticed that the default cli behaviour of a space is that is is stored as data inside the path of the znode specified. I assume the ZK Java API is being alittle more 'powerful' but it would be nice to enable operators a easier native way to check the little things. 
> ```
> [zk: localhost:2181(CONNECTED) 7] ls /nifi/leaders/
> Primary Node          Cluster Coordinator
> [zk: localhost:2181(CONNECTED) 7] ls /nifi/leaders/Primary Node
> Node does not exist: /nifi/leaders/Primary
> [zk: localhost:2181(CONNECTED) 8] ls /nifi/leaders/Cluster Coordinator
> Node does not exist: /nifi/leaders/Cluster
> [zk: localhost:2181(CONNECTED) 1] create /test blah 
> Created /test
> [zk: localhost:2181(CONNECTED) 2] get /test
> blah
> cZxid = 0xb0000038e
> ctime = Thu Apr 06 21:24:10 EDT 2017
> mZxid = 0xb0000038e
> mtime = Thu Apr 06 21:24:10 EDT 2017
> pZxid = 0xb0000038e
> cversion = 0
> dataVersion = 0
> aclVersion = 0
> ephemeralOwner = 0x0
> dataLength = 4
> numChildren = 0
> ```



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)