@Component public class TaskCommands extends Object implements org.springframework.shell.core.CommandMarker
| Constructor and Description |
|---|
TaskCommands() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
availableWithCreateRole() |
boolean |
availableWithViewRole() |
String |
cleanup(long id) |
String |
create(String name,
String dsl) |
String |
destroy(String name) |
org.springframework.shell.table.Table |
display(long id) |
org.springframework.shell.table.Table |
executionListByName(String name) |
String |
launch(String name,
String properties,
File propertiesFile,
String arguments) |
org.springframework.shell.table.Table |
list() |
@CliAvailabilityIndicator(value={"task list","task execution status","task execution list"})
public boolean availableWithViewRole()
@CliAvailabilityIndicator(value={"task create","task launch","task execution cleanup","task destroy"})
public boolean availableWithCreateRole()
@CliCommand(value="task list",
help="List created tasks")
public org.springframework.shell.table.Table list()
@CliCommand(value="task create",
help="Create a new task definition")
public String create(@CliOption(mandatory=true,key={"","name"},help="the name to give to the task")
String name,
@CliOption(mandatory=true,key="definition",help="a task definition, using the DSL (e.g. \"timestamp --format=YYYY\")",optionContext="disable-string-converter completion-task")
String dsl)
@CliCommand(value="task launch",
help="Launch a previously created task")
public String launch(@CliOption(key={"","name"},help="the name of the task to launch",mandatory=true,optionContext="existing-task disable-string-converter")
String name,
@CliOption(key="properties",help="the properties for this launch",mandatory=false)
String properties,
@CliOption(key="propertiesFile",help="the properties for this launch (as a File)",mandatory=false)
File propertiesFile,
@CliOption(key="arguments",help="the commandline arguments for this launch",mandatory=false)
String arguments)
throws IOException
IOException@CliCommand(value="task destroy",
help="Destroy an existing task")
public String destroy(@CliOption(key={"","name"},help="the name of the task to destroy",mandatory=true,optionContext="existing-task disable-string-converter")
String name)
@CliCommand(value="task execution list",
help="List created task executions filtered by taskName")
public org.springframework.shell.table.Table executionListByName(@CliOption(key="name",help="the task name to be used as a filter",optionContext="existing-task disable-string-converter")
String name)
@CliCommand(value="task execution status",
help="Display the details of a specific task execution")
public org.springframework.shell.table.Table display(@CliOption(key={"","id"},help="the task execution id",mandatory=true)
long id)
@CliCommand(value="task execution cleanup",
help="Clean up any platform specific resources linked to a task execution")
public String cleanup(@CliOption(key={"","id"},help="the task execution id",mandatory=true)
long id)
Copyright © 2018 Pivotal Software, Inc.. All rights reserved.