You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@fluo.apache.org by GitBox <gi...@apache.org> on 2017/12/22 13:46:29 UTC
[GitHub] keith-turner commented on a change in pull request #982: fixes #981 stopped printing meta info in scan
keith-turner commented on a change in pull request #982: fixes #981 stopped printing meta info in scan
URL: https://github.com/apache/fluo/pull/982#discussion_r158494513
##########
File path: modules/core/src/main/java/org/apache/fluo/core/util/ScanUtil.java
##########
@@ -128,24 +125,20 @@ public static void scanFluo(ScanOpts options, FluoConfiguration sConfig) {
sb.append(rcv.getsValue());
System.out.println(sb.toString());
}
- entriesFound++;
+
if (System.out.checkError()) {
break;
}
}
- if (entriesFound == 0) {
- System.out.println("\nNo data found\n");
- }
} catch (FluoException e) {
- System.out.println("Scan failed - " + e.getMessage());
+ System.err.println("Scan failed - " + e.getMessage());
+ System.exit(-1);
Review comment:
That sounds fine. I changed this code to make it consistent with other existing code. I think it would be best to make this change in another PR where all of the code is made consistent.
```bash
$ find . -name "*.java" | xargs grep System.exit
./src/main/java/org/apache/fluo/command/BaseOpts.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/BaseOpts.java: System.exit(1);
./src/main/java/org/apache/fluo/command/CommandUtil.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/CommandUtil.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(0);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(0);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoInit.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoExec.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoWait.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoWait.java: System.exit(-1);
./src/main/java/org/apache/fluo/command/FluoWait.java: System.exit(-1);
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services