(subparsers)
| 460 | |
| 461 | |
| 462 | def initialize_local_subcommand(subparsers): |
| 463 | command_help = """Runs the main method of class with the specified arguments but pointing to a local cluster |
| 464 | The storm jars and configs in ~/.storm are put on the classpath. |
| 465 | The process is configured so that StormSubmitter |
| 466 | (https://storm.apache.org/releases/current/javadocs/org/apache/storm/StormSubmitter.html) |
| 467 | and others will interact with a local cluster instead of the one configured by default. |
| 468 | |
| 469 | Most options should work just like with the storm jar command. |
| 470 | """ |
| 471 | sub_parser = subparsers.add_parser("local", help=command_help, formatter_class=SortingHelpFormatter) |
| 472 | |
| 473 | add_topology_jar_options(sub_parser) |
| 474 | add_client_jar_options(sub_parser) |
| 475 | |
| 476 | sub_parser.add_argument( |
| 477 | "--local-ttl", |
| 478 | help="sets the number of seconds the local cluster will run for before it shuts down", |
| 479 | default=LOCAL_TTL_DEFAULT |
| 480 | ) |
| 481 | |
| 482 | sub_parser.add_argument( |
| 483 | "--java-debug", |
| 484 | help="lets you turn on java debugging and set the parameters passed to -agentlib:jdwp on the JDK" + |
| 485 | "e.g transport=dt_socket,address=localhost:8000 will open up a debugging server on port 8000", |
| 486 | default=None |
| 487 | ) |
| 488 | |
| 489 | sub_parser.add_argument( |
| 490 | "--local-zookeeper", |
| 491 | help="""if using an external zookeeper sets the connection string to use for it.""", |
| 492 | default=None |
| 493 | ) |
| 494 | |
| 495 | sub_parser.set_defaults(func=local) |
| 496 | add_common_options(sub_parser) |
| 497 | |
| 498 | |
| 499 | def initialize_kill_subcommand(subparsers): |
no test coverage detected