> On Sept. 27, 2016, 6:37 p.m., Rakesh R wrote: > > src/java/main/org/apache/zookeeper/KeeperException.java, line 317 > > <https://reviews.apache.org/r/51546/diff/3/?file=1510450#file1510450line317> > > > > Do we need @Deprecated constant value? Since we are in 3.5 branch, I > > feel its not required. > > > > Secondly, we can't we use -122?
Thanks for all the reviews, Rakesh! We need deprecated here but I see what you mean - instead of adding a deprecated value I can just skip adding it. -122 is used in zookeeper.h as ZRWSERVERFOUND... this maybe a bug as there is no corresponding code in Java client. I'd like to deal with this later so skip -122 and choose next value -123. > On Sept. 27, 2016, 6:37 p.m., Rakesh R wrote: > > src/java/main/org/apache/zookeeper/admin/ZooKeeperAdmin.java, line 42 > > <https://reviews.apache.org/r/51546/diff/3/?file=1510453#file1510453line42> > > > > Please add class level javadoc. Thanks! Good catch, will update. > On Sept. 27, 2016, 6:37 p.m., Rakesh R wrote: > > src/java/main/org/apache/zookeeper/admin/ZooKeeperAdmin.java, line 46 > > <https://reviews.apache.org/r/51546/diff/3/?file=1510453#file1510453line46> > > > > I could see ZooKeeper.java has the static block printing "Client > > environment" details. I think it will simply duplicate the information, can > > we remove this static block. Also, move the LOG instantiation directly to > > the LOG variable. Will fix. > On Sept. 27, 2016, 6:37 p.m., Rakesh R wrote: > > src/java/main/org/apache/zookeeper/server/PrepRequestProcessor.java, line > > 472 > > <https://reviews.apache.org/r/51546/diff/3/?file=1510457#file1510457line472> > > > > Its throwing exception and failing the operation. Should we need an > > error log priority instead of warn? Good one, I agree LOG.error is better and is consistent with existing behavior. > On Sept. 27, 2016, 6:37 p.m., Rakesh R wrote: > > src/java/main/org/apache/zookeeper/server/quorum/QuorumPeerConfig.java, > > line 291 > > <https://reviews.apache.org/r/51546/diff/3/?file=1510458#file1510458line291> > > > > I agree its not followed previously in zookeeper code base. But I feel > > to print the configured value in case of invalid to improve debuggability, > > like below as we are adding new items and we have the chance now:-) > > > > throw new ConfigException("Invalid option:"+ value +" for > > reconfigEnabled flag. Choose 'true' or 'false.'"); Sounds good. > On Sept. 27, 2016, 6:37 p.m., Rakesh R wrote: > > src/java/test/org/apache/zookeeper/test/ReconfigExceptionTest.java, line 82 > > <https://reviews.apache.org/r/51546/diff/3/?file=1510466#file1510466line82> > > > > Its good practise to add timeout in tests. may be smaller value can be > > given. > > > > @Test(timeout = 10000) Will fix. - Michael ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/51546/#review150538 ----------------------------------------------------------- On Sept. 26, 2016, 10:48 p.m., Michael Han wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/51546/ > ----------------------------------------------------------- > > (Updated Sept. 26, 2016, 10:48 p.m.) > > > Review request for zookeeper, fpj, Patrick Hunt, Raul Gutierrez Segales, and > Alexander Shraer. > > > Bugs: ZOOKEEPER-2014 > https://issues.apache.org/jira/browse/ZOOKEEPER-2014 > > > Repository: zookeeper-git > > > Description > ------- > > Address various security concerns around reconfig feature (ZOOKEEPER-2014) to > unblock 3.5.3 release. > > > Diffs > ----- > > build.xml 96c9ef8 > src/c/include/zookeeper.h 18a203d > src/c/tests/TestReconfigServer.cc 6a429ac > src/c/tests/ZooKeeperQuorumServer.h aa8b7cc > src/c/tests/ZooKeeperQuorumServer.cc 23392cd > src/docs/src/documentation/content/xdocs/zookeeperAdmin.xml f729095 > src/docs/src/documentation/content/xdocs/zookeeperReconfig.xml 7168a01 > src/java/main/org/apache/zookeeper/ClientCnxn.java 12dd51c > src/java/main/org/apache/zookeeper/KeeperException.java a05f1ab > src/java/main/org/apache/zookeeper/ZooKeeper.java f2ec3d7 > src/java/main/org/apache/zookeeper/ZooKeeperMain.java 25d61a4 > src/java/main/org/apache/zookeeper/admin/ZooKeeperAdmin.java PRE-CREATION > src/java/main/org/apache/zookeeper/cli/CliCommand.java 3d0a90b > src/java/main/org/apache/zookeeper/cli/ReconfigCommand.java deb7914 > src/java/main/org/apache/zookeeper/server/DataTree.java 06c80d3 > src/java/main/org/apache/zookeeper/server/PrepRequestProcessor.java 33f638d > src/java/main/org/apache/zookeeper/server/quorum/QuorumPeerConfig.java > e772fa8 > src/java/test/org/apache/zookeeper/server/DataTreeTest.java d726643 > src/java/test/org/apache/zookeeper/server/quorum/ReconfigBackupTest.java > 241af52 > > src/java/test/org/apache/zookeeper/server/quorum/ReconfigDuringLeaderSyncTest.java > 301837d > > src/java/test/org/apache/zookeeper/server/quorum/ReconfigFailureCasesTest.java > e7147b3 > src/java/test/org/apache/zookeeper/server/quorum/ReconfigLegacyTest.java > ee9f2e2 > > src/java/test/org/apache/zookeeper/server/quorum/StandaloneDisabledTest.java > 1f6ce1f > src/java/test/org/apache/zookeeper/test/ACLTest.java 9920fc4 > src/java/test/org/apache/zookeeper/test/ReconfigExceptionTest.java > PRE-CREATION > src/java/test/org/apache/zookeeper/test/ReconfigTest.java 248a754 > src/java/test/org/apache/zookeeper/test/StandaloneTest.java 5c95280 > > Diff: https://reviews.apache.org/r/51546/diff/ > > > Testing > ------- > > Added new Java unit tests that cover various exception cases of using > reconfig API without proper set up. > All existing tests (Java and C) passed under stress tests (minors those known > flaky tests.). > Manuelly tested reconfig commands using ZooKeeper command line tool. > > > Thanks, > > Michael Han > >