ZooKeeper
  1. ZooKeeper
  2. ZOOKEEPER-1025

zkCli is overly sensitive to to spaces.

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.3.3, 3.4.0
    • Fix Version/s: 3.4.0
    • Component/s: java client
    • Labels:
      None

      Description

      Here's an example:

      I do an ls to get znode names. I try to stat a znode.

      [zk: localhost:3181(CONNECTED) 1] ls /flume-nodes
      [nodes0000000002, nodes0000000001, nodes0000000000, nodes0000000005, nodes0000000004, nodes0000000003]
      [zk: localhost:3181(CONNECTED) 3] stat /flume-nodes/nodes0000000002 
      cZxid = 0xb
      ctime = Sun Mar 20 23:24:03 PDT 2011
      ... (success)
      

      Here's something that almost looks the same. Notice the extra space infront of the znode name.

      [zk: localhost:3181(CONNECTED) 2] stat  /flume-nodes/nodes0000000002
      Command failed: java.lang.IllegalArgumentException: Path length must be > 0
      

      This seems like unexpected behavior.

      1. ZOOKEEPER-1025.patch
        2 kB
        Laxman
      2. ZOOKEEPER-1025.patch
        2 kB
        Laxman

        Issue Links

          Activity

          Hide
          Laxman added a comment -

          Patch to fix the space sensitivity in cli.

          Show
          Laxman added a comment - Patch to fix the space sensitivity in cli.
          Hide
          Laxman added a comment -

          uploading patch again to get tested by qa bot.

          Show
          Laxman added a comment - uploading patch again to get tested by qa bot.
          Hide
          Hadoop QA added a comment -

          +1 overall. Here are the results of testing the latest attachment
          http://issues.apache.org/jira/secure/attachment/12490408/ZOOKEEPER-1025.patch
          against trunk revision 1157698.

          +1 @author. The patch does not contain any @author tags.

          +1 tests included. The patch appears to include 3 new or modified tests.

          +1 javadoc. The javadoc tool did not generate any warning messages.

          +1 javac. The applied patch does not increase the total number of javac compiler warnings.

          +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) warnings.

          +1 release audit. The applied patch does not increase the total number of release audit warnings.

          +1 core tests. The patch passed core unit tests.

          +1 contrib tests. The patch passed contrib unit tests.

          Test results: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/460//testReport/
          Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/460//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
          Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/460//console

          This message is automatically generated.

          Show
          Hadoop QA added a comment - +1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12490408/ZOOKEEPER-1025.patch against trunk revision 1157698. +1 @author. The patch does not contain any @author tags. +1 tests included. The patch appears to include 3 new or modified tests. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs (version 1.3.9) warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/460//testReport/ Findbugs warnings: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/460//artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Console output: https://builds.apache.org/job/PreCommit-ZOOKEEPER-Build/460//console This message is automatically generated.
          Hide
          Camille Fournier added a comment -

          Looks good, +1 from me. Mahadev, should I check this in to trunk or are we trying to freeze 3.4 for release?

          Show
          Camille Fournier added a comment - Looks good, +1 from me. Mahadev, should I check this in to trunk or are we trying to freeze 3.4 for release?
          Hide
          Mahadev konar added a comment -

          Camille go ahead and check this to trunk. Doesnt look disruptive.

          Show
          Mahadev konar added a comment - Camille go ahead and check this to trunk. Doesnt look disruptive.
          Hide
          Camille Fournier added a comment -

          commited to trunk r1159389

          Show
          Camille Fournier added a comment - commited to trunk r1159389
          Hide
          Mahadev konar added a comment -

          Camille, did you forget to mark this as fixed?

          Show
          Mahadev konar added a comment - Camille, did you forget to mark this as fixed?
          Hide
          Camille Fournier added a comment -

          I usually like to wait until it gets through the build, but I can mark it as fixed immediately upon checkin if that is better.

          Show
          Camille Fournier added a comment - I usually like to wait until it gets through the build, but I can mark it as fixed immediately upon checkin if that is better.
          Hide
          Hudson added a comment -

          Integrated in ZooKeeper-trunk #1270 (See https://builds.apache.org/job/ZooKeeper-trunk/1270/)
          ZOOKEEPER-1025: zkCli is overly sensitive to to spaces. (Laxman via camille)

          camille : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1159389
          Files :

          • /zookeeper/trunk/src/java/main/org/apache/zookeeper/ZooKeeperMain.java
          • /zookeeper/trunk/src/java/test/org/apache/zookeeper/ZooKeeperTest.java
          • /zookeeper/trunk/CHANGES.txt
          Show
          Hudson added a comment - Integrated in ZooKeeper-trunk #1270 (See https://builds.apache.org/job/ZooKeeper-trunk/1270/ ) ZOOKEEPER-1025 : zkCli is overly sensitive to to spaces. (Laxman via camille) camille : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1159389 Files : /zookeeper/trunk/src/java/main/org/apache/zookeeper/ZooKeeperMain.java /zookeeper/trunk/src/java/test/org/apache/zookeeper/ZooKeeperTest.java /zookeeper/trunk/CHANGES.txt
          Hide
          Laxman added a comment -

          Thanks Camille for your review and commit.

          Show
          Laxman added a comment - Thanks Camille for your review and commit.

            People

            • Assignee:
              Laxman
              Reporter:
              Jonathan Hsieh
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development