Process Information
The following task information is described in this section:
task_name
Syntax
task_name()
Description
Returns the global name of the current task. See Cloud Workflow Processes for information on tasks.
Arguments
None
Result
A string that represents the global name of the current task.
Examples
concurrent do
sub task_name: "launch_app" do
@servers = find("servers", "db")
@arrays = find("server_arrays", "appserver")
concurrent do
sub task_name: "launch_servers" do
@servers.launch()
$name = task_name() # $name == "launch_app/launch_servers"
end
sub task_name: "launch_arrays" do
@arrays.launch()
$name = task_name() # $name == "launch_app/launch_arrays"
end
end
end
sub task_name: "notify" do
# ... do things
end
end
tasks
Syntax
tasks()
Arguments
None
Result
Returns a hash of task status keyed by global task name. Valid values for a task status are: completed, aborted, canceled, paused, or running.
task_label
Syntax
task_label($label)
Description
Sets the label of the current task. This label is displayed in the Self-Service user interface to end users when an operation is running.
Arguments
| Position | Possible Values | Required | Default Value |
|---|---|---|---|
| 1 | String | Yes | None |
Result
The new label string.
task_status
Syntax
task_status($task_name)
Description
Returns the status of the given task. The task name can be relative or absolute (relative match is tried first then absolute if there is no task with a relative name matching the argument).
Arguments
| Position | Possible Values | Required | Default Value | Comment |
|---|---|---|---|---|
| 1 | String | Yes | None | Name of task whose status should be returned |
Result
completed, aborted, canceled, paused, or running. Returns null for non-existent tasks.