Github user priyank5485 commented on a diff in the pull request:

    https://github.com/apache/storm/pull/1665#discussion_r77034491
  
    --- Diff: 
external/storm-kafka-monitor/src/main/java/org/apache/storm/kafka/monitor/KafkaOffsetLagUtil.java
 ---
    @@ -373,16 +377,20 @@ private static Options buildOptions () {
             curatorFramework.start();
             String partitionPrefix = "partition_";
             String zkPath = oldKafkaSpoutOffsetQuery.getZkPath();
    -        if (!zkPath.endsWith("/")) {
    -            zkPath += "/";
    +         if (zkPath.endsWith("/")) {
    --- End diff --
    
    Is there a reason for removing trailing / here and then appending in the 
loop below?  The loop already has a check for 
curatorFramework.checkExists().forPath(path). May be we can just print and exit 
therE? Also, can you call the printUsageAndExit method here to be consistent? 
Or is there a reason you could not use it?


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to