(CommandLine cli)
| 51 | } |
| 52 | |
| 53 | @Override |
| 54 | public void runImpl(CommandLine cli) throws Exception { |
| 55 | String zkHost = CLIUtils.getZkHost(cli); |
| 56 | String znode = cli.getArgs()[0]; |
| 57 | |
| 58 | try (SolrZkClient zkClient = CLIUtils.getSolrZkClient(cli, zkHost)) { |
| 59 | echoIfVerbose("\nConnecting to ZooKeeper at " + zkHost + " ..."); |
| 60 | |
| 61 | boolean recursive = cli.hasOption(CommonCLIOptions.RECURSIVE_OPTION); |
| 62 | echoIfVerbose( |
| 63 | "Getting listing for ZooKeeper node " |
| 64 | + znode |
| 65 | + " from ZooKeeper at " |
| 66 | + zkHost |
| 67 | + " recursive: " |
| 68 | + recursive); |
| 69 | runtime.print(zkClient.listZnode(znode, recursive)); |
| 70 | } catch (Exception e) { |
| 71 | log.error("Could not complete ls operation for reason: ", e); |
| 72 | throw (e); |
| 73 | } |
| 74 | } |
| 75 | } |
nothing calls this directly
no test coverage detected