@Component public class StreamCommands extends Object implements CommandMarker
Constructor and Description |
---|
StreamCommands() |
Modifier and Type | Method and Description |
---|---|
boolean |
available() |
String |
createStream(String name,
String dsl,
boolean deploy) |
String |
deployStream(String name,
String properties,
File propertiesFile) |
String |
destroyAllStreams(boolean force) |
String |
destroyStream(String name) |
org.springframework.shell.table.Table |
listStreams() |
String |
undeployAllStreams(boolean force) |
String |
undeployStream(String name) |
@CliAvailabilityIndicator(value={"stream list","stream create","stream deploy","stream undeploy","stream all undeploy","stream destroy","stream all destroy"}) public boolean available()
@CliCommand(value="stream list", help="List created streams") public org.springframework.shell.table.Table listStreams()
@CliCommand(value="stream create", help="Create a new stream definition") public String createStream(@CliOption(mandatory=true,key={"","name"},help="the name to give to the stream") String name, @CliOption(mandatory=true,key="definition",help="a stream definition, using the DSL (e.g. \"http --port=9000 | hdfs\")",optionContext="disable-string-converter completion-stream") String dsl, @CliOption(key="deploy",help="whether to deploy the stream immediately",unspecifiedDefaultValue="false",specifiedDefaultValue="true") boolean deploy)
@CliCommand(value="stream deploy", help="Deploy a previously created stream") public String deployStream(@CliOption(key={"","name"},help="the name of the stream to deploy",mandatory=true) String name, @CliOption(key="properties",help="the properties for this deployment",mandatory=false) String properties, @CliOption(key="propertiesFile",help="the properties for this deployment (as a File)",mandatory=false) File propertiesFile) throws IOException
IOException
@CliCommand(value="stream undeploy", help="Un-deploy a previously deployed stream") public String undeployStream(@CliOption(key={"","name"},help="the name of the stream to un-deploy",mandatory=true) String name)
@CliCommand(value="stream all undeploy", help="Un-deploy all previously deployed stream") public String undeployAllStreams(@CliOption(key="force",help="bypass confirmation prompt",unspecifiedDefaultValue="false",specifiedDefaultValue="true") boolean force)
@CliCommand(value="stream destroy", help="Destroy an existing stream") public String destroyStream(@CliOption(key={"","name"},help="the name of the stream to destroy",mandatory=true) String name)
@CliCommand(value="stream all destroy", help="Destroy all existing streams") public String destroyAllStreams(@CliOption(key="force",help="bypass confirmation prompt",unspecifiedDefaultValue="false",specifiedDefaultValue="true") boolean force)
Copyright © 2016 Pivotal Software, Inc.. All rights reserved.