timmylicheng commented on a change in pull request #1286: HDDS-1894. Add filter 
to scmcli listPipelines.
URL: https://github.com/apache/hadoop/pull/1286#discussion_r314565982
 
 

 ##########
 File path: 
hadoop-hdds/tools/src/main/java/org/apache/hadoop/hdds/scm/cli/pipeline/ListPipelinesSubcommand.java
 ##########
 @@ -38,11 +38,34 @@
   @CommandLine.ParentCommand
   private SCMCLI parent;
 
+  @CommandLine.Option( names = {"-ffc", "--filterByFactor"},
+          description = "Filter listed pipelines by Factor(ONE/one)", 
defaultValue = "",
+          required = false)
+  private String factor;
+
+  @CommandLine.Option( names = {"-fst", "--filterByState"},
+          description = "Filter listed pipelines by State(OPEN/CLOSE)", 
defaultValue = "",
+          required = false)
+  private String state;
+
+
   @Override
   public Void call() throws Exception {
     try (ScmClient scmClient = parent.createScmClient()) {
-      scmClient.listPipelines().forEach(System.out::println);
+      if (isNullOrEmpty(factor) && isNullOrEmpty(state)) {
 
 Review comment:
   My method removes spaces :)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: common-issues-h...@hadoop.apache.org

Reply via email to