@ShellComponent public class StreamCommands extends Object
Constructor and Description |
---|
StreamCommands(DataFlowShell dataFlowShell,
ConsoleUserInput userInput) |
Modifier and Type | Method and Description |
---|---|
org.springframework.shell.Availability |
availableWithCreateRole() |
org.springframework.shell.Availability |
availableWithDeployRole() |
org.springframework.shell.Availability |
availableWithDestroyRole() |
org.springframework.shell.Availability |
availableWithModifyRole() |
org.springframework.shell.Availability |
availableWithViewRole() |
String |
createStream(String name,
String dsl,
String description,
boolean deploy) |
String |
deployStream(String name,
String deploymentProperties,
File propertiesFile,
String packageVersion,
String platformName,
String repoName) |
String |
destroyAllStreams(boolean force) |
String |
destroyStream(String name) |
String |
getManifest(String name,
int releaseVersion) |
org.springframework.shell.table.Table |
history(String name) |
org.springframework.shell.table.Table |
listPlatforms() |
org.springframework.shell.table.Table |
listStreams() |
String |
rollbackStreamUsingSkipper(String name,
int releaseVersion) |
String |
scaleStream(String name,
String applicationName,
Integer count,
String scaleProperties) |
TablesInfo |
streamInfo(String name) |
protected StreamOperations |
streamOperations() |
String |
undeployAllStreams(boolean force) |
String |
undeployStream(String name) |
String |
updateStream(String name,
String properties,
File propertiesFile,
String packageVersion,
String repoName,
boolean force,
String appNames) |
TablesInfo |
validateStream(String name) |
public StreamCommands(DataFlowShell dataFlowShell, ConsoleUserInput userInput)
public org.springframework.shell.Availability availableWithCreateRole()
public org.springframework.shell.Availability availableWithDeployRole()
public org.springframework.shell.Availability availableWithDestroyRole()
public org.springframework.shell.Availability availableWithModifyRole()
public org.springframework.shell.Availability availableWithViewRole()
@ShellMethod(key="stream deploy", value="Deploy a previously created stream using Skipper") @ShellMethodAvailability(value="availableWithDeployRole") public String deployStream(@ShellOption(value={"","--name"},help="the name of the stream to deploy",valueProvider=StreamNameValueProvider.class) String name, @ShellOption(value="--properties",help="the properties for this deployment",defaultValue="__NULL__") String deploymentProperties, @ShellOption(value="--propertiesFile",help="the properties for this deployment (as a File)",defaultValue="__NULL__") File propertiesFile, @ShellOption(value="--packageVersion",help="the package version of the package to deploy. Default is 1.0.0",defaultValue="1.0.0") String packageVersion, @ShellOption(value="--platformName",help="the name of the target platform to deploy to",defaultValue="__NULL__") String platformName, @ShellOption(value="--repoName",help="the name of the local repository to upload the package to",defaultValue="__NULL__") String repoName) throws IOException
IOException
@ShellMethod(key="stream manifest", value="Get manifest for the stream deployed using Skipper") @ShellMethodAvailability(value="availableWithViewRole") public String getManifest(@ShellOption(value={"","--name"},help="the name of the stream",valueProvider=StreamNameValueProvider.class) String name, @ShellOption(value="--releaseVersion",help="the Skipper release version to get the manifest for",defaultValue="0") int releaseVersion)
@ShellMethod(key="stream history", value="Get history for the stream deployed using Skipper") @ShellMethodAvailability(value="availableWithViewRole") public org.springframework.shell.table.Table history(@ShellOption(value={"","--name"},help="the name of the stream",valueProvider=StreamNameValueProvider.class) String name)
@ShellMethod(key="stream platform-list", value="List Skipper platforms") @ShellMethodAvailability(value="availableWithViewRole") public org.springframework.shell.table.Table listPlatforms()
@ShellMethod(key="stream update", value="Update a previously created stream using Skipper") @ShellMethodAvailability(value="availableWithModifyRole") public String updateStream(@ShellOption(value={"","--name"},help="the name of the stream",valueProvider=StreamNameValueProvider.class) String name, @ShellOption(help="Flattened YAML style properties to update the stream") String properties, @ShellOption(value="--propertiesFile",help="the properties for the stream update (as a File)",defaultValue="__NULL__") File propertiesFile, @ShellOption(value="--packageVersion",help="the package version of the package to update when using Skipper",defaultValue="__NULL__") String packageVersion, @ShellOption(value="--repoName",help="the name of the local repository to upload the package when using Skipper",defaultValue="__NULL__") String repoName, @ShellOption(help="force the update",defaultValue="false") boolean force, @ShellOption(value="--appNames",help="the application names to force update",defaultValue="__NULL__") String appNames) throws IOException
IOException
@ShellMethod(key="stream scale app instances", value="Scale app instances in a stream") @ShellMethodAvailability(value="availableWithModifyRole") public String scaleStream(@ShellOption(value={"","--name"},help="the name of the stream to scale",valueProvider=StreamNameValueProvider.class) String name, @ShellOption(value="--applicationName",help="the name/label of the application to scale") String applicationName, @ShellOption(help="desired number of application instances") Integer count, @ShellOption(value="--properties",help="the properties for this scale",defaultValue="__NULL__") String scaleProperties) throws IOException
IOException
@ShellMethod(key="stream rollback", value="Rollback a stream using Skipper") @ShellMethodAvailability(value="availableWithModifyRole") public String rollbackStreamUsingSkipper(@ShellOption(value={"","--name"},help="the name of the stream to rollback",valueProvider=StreamNameValueProvider.class) String name, @ShellOption(value="--releaseVersion",help="the Skipper release version to rollback to",defaultValue="0") int releaseVersion)
@ShellMethod(key="stream create", value="Create a new stream definition") @ShellMethodAvailability(value="availableWithCreateRole") public String createStream(@ShellOption(value={"","--name"},help="the name to give to the stream") String name, @ShellOption(value="--definition",help="a stream definition, using the DSL (e.g. \"http --port=9000 | hdfs\")") String dsl, @ShellOption(help="a short description about the stream",defaultValue="") String description, @ShellOption(help="whether to deploy the stream immediately",defaultValue="false") boolean deploy)
@ShellMethod(key="stream list", value="List created streams") @ShellMethodAvailability(value="availableWithViewRole") public org.springframework.shell.table.Table listStreams()
@ShellMethod(key="stream info", value="Show information about a specific stream") @ShellMethodAvailability(value="availableWithViewRole") public TablesInfo streamInfo(@ShellOption(value={"","--name"},help="the name of the stream to show",valueProvider=StreamNameValueProvider.class) String name)
@ShellMethod(key="stream undeploy", value="Un-deploy a previously deployed stream") @ShellMethodAvailability(value="availableWithDeployRole") public String undeployStream(@ShellOption(value={"","--name"},help="the name of the stream to un-deploy",valueProvider=StreamNameValueProvider.class) String name)
@ShellMethod(key="stream all undeploy", value="Un-deploy all previously deployed stream") @ShellMethodAvailability(value="availableWithDeployRole") public String undeployAllStreams(@ShellOption(help="bypass confirmation prompt",defaultValue="false") boolean force)
@ShellMethod(key="stream destroy", value="Destroy an existing stream") @ShellMethodAvailability(value="availableWithDestroyRole") public String destroyStream(@ShellOption(value={"","--name"},help="the name of the stream to destroy",valueProvider=StreamNameValueProvider.class) String name)
@ShellMethod(key="stream all destroy", value="Destroy all existing streams") @ShellMethodAvailability(value="availableWithDestroyRole") public String destroyAllStreams(@ShellOption(help="bypass confirmation prompt",defaultValue="false") boolean force)
@ShellMethod(key="stream validate", value="Verify that apps contained in the stream are valid.") @ShellMethodAvailability(value="availableWithViewRole") public TablesInfo validateStream(@ShellOption(value={"","--name"},help="the name of the stream to validate",valueProvider=StreamNameValueProvider.class) String name) throws OperationNotSupportedException
OperationNotSupportedException
protected StreamOperations streamOperations()
Copyright © 2024 Pivotal Software, Inc.. All rights reserved.