class ProjectsLocationsWorkflowTemplates extends Resource (View source)

The "workflowTemplates" collection of methods.

Typical usage is:

 $dataprocService = new Google\Service\Dataproc(...);
 $workflowTemplates = $dataprocService->projects_locations_workflowTemplates;

Methods

create(string $parent, WorkflowTemplate $postBody, array $optParams = [])

Creates new workflow template. (workflowTemplates.create)

delete(string $name, array $optParams = [])

Deletes a workflow template. It does not cancel in-progress workflows.

get(string $name, array $optParams = [])

Retrieves the latest workflow template.Can retrieve previously instantiated template by specifying optional version parameter. (workflowTemplates.get)

getIamPolicy(string $resource, GetIamPolicyRequest $postBody, array $optParams = [])

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

instantiate(string $name, InstantiateWorkflowTemplateRequest $postBody, array $optParams = [])

Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata (https://cloud.google.com/dataproc/docs/reference/rp c/google.cloud.dataproc.v1#workflowmetadata). Also see Using WorkflowMetadata (https://cloud.google.com/dataproc/docs/concepts/workflows/debugging#using_wo rkflowmetadata).On successful completion, Operation.response will be Empty.

instantiateInline(string $parent, WorkflowTemplate $postBody, array $optParams = [])

Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata (https://cloud.google.com/dataproc/docs/reference/rpc/google .cloud.dataproc.v1#workflowmetadata). Also see Using WorkflowMetadata (https: //cloud.google.com/dataproc/docs/concepts/workflows/debugging#using_workflowm etadata).On successful completion, Operation.response will be Empty.

listProjectsLocationsWorkflowTemplates(string $parent, array $optParams = [])

Lists workflows that match the specified filter in the request.

setIamPolicy(string $resource, SetIamPolicyRequest $postBody, array $optParams = [])

Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors. (workflowTemplates.setIamPolicy)

testIamPermissions(string $resource, TestIamPermissionsRequest $postBody, array $optParams = [])

Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking.

update(string $name, WorkflowTemplate $postBody, array $optParams = [])

Updates (replaces) workflow template. The updated template must contain version that matches the current server version. (workflowTemplates.update)

Details

WorkflowTemplate create(string $parent, WorkflowTemplate $postBody, array $optParams = [])

Creates new workflow template. (workflowTemplates.create)

Parameters

string $parent

Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.create, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location}

WorkflowTemplate $postBody
array $optParams

Optional parameters.

Return Value

WorkflowTemplate

Exceptions

Exception

DataprocEmpty delete(string $name, array $optParams = [])

Deletes a workflow template. It does not cancel in-progress workflows.

(workflowTemplates.delete)

Parameters

string $name

Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

array $optParams

Optional parameters.

Return Value

DataprocEmpty

Exceptions

Exception

WorkflowTemplate get(string $name, array $optParams = [])

Retrieves the latest workflow template.Can retrieve previously instantiated template by specifying optional version parameter. (workflowTemplates.get)

Parameters

string $name

Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

array $optParams

Optional parameters.

Return Value

WorkflowTemplate

Exceptions

Exception

Policy getIamPolicy(string $resource, GetIamPolicyRequest $postBody, array $optParams = [])

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

(workflowTemplates.getIamPolicy)

Parameters

string $resource

REQUIRED: The resource for which the policy is being requested. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

GetIamPolicyRequest $postBody
array $optParams

Optional parameters.

Return Value

Policy

Exceptions

Exception

Operation instantiate(string $name, InstantiateWorkflowTemplateRequest $postBody, array $optParams = [])

Instantiates a template and begins execution.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata (https://cloud.google.com/dataproc/docs/reference/rp c/google.cloud.dataproc.v1#workflowmetadata). Also see Using WorkflowMetadata (https://cloud.google.com/dataproc/docs/concepts/workflows/debugging#using_wo rkflowmetadata).On successful completion, Operation.response will be Empty.

(workflowTemplates.instantiate)

Parameters

string $name

Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

InstantiateWorkflowTemplateRequest $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

Operation instantiateInline(string $parent, WorkflowTemplate $postBody, array $optParams = [])

Instantiates a template and begins execution.This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.The Operation.metadata will be WorkflowMetadata (https://cloud.google.com/dataproc/docs/reference/rpc/google .cloud.dataproc.v1#workflowmetadata). Also see Using WorkflowMetadata (https: //cloud.google.com/dataproc/docs/concepts/workflows/debugging#using_workflowm etadata).On successful completion, Operation.response will be Empty.

(workflowTemplates.instantiateInline)

Parameters

string $parent

Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location}

WorkflowTemplate $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

ListWorkflowTemplatesResponse listProjectsLocationsWorkflowTemplates(string $parent, array $optParams = [])

Lists workflows that match the specified filter in the request.

(workflowTemplates.listProjectsLocationsWorkflowTemplates)

Parameters

string $parent

Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region} For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location}

array $optParams

Optional parameters.

Return Value

ListWorkflowTemplatesResponse

Exceptions

Exception

Policy setIamPolicy(string $resource, SetIamPolicyRequest $postBody, array $optParams = [])

Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors. (workflowTemplates.setIamPolicy)

Parameters

string $resource

REQUIRED: The resource for which the policy is being specified. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

SetIamPolicyRequest $postBody
array $optParams

Optional parameters.

Return Value

Policy

Exceptions

Exception

TestIamPermissionsResponse testIamPermissions(string $resource, TestIamPermissionsRequest $postBody, array $optParams = [])

Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking.

This operation may "fail open" without warning. (workflowTemplates.testIamPermissions)

Parameters

string $resource

REQUIRED: The resource for which the policy detail is being requested. See Resource names (https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

TestIamPermissionsRequest $postBody
array $optParams

Optional parameters.

Return Value

TestIamPermissionsResponse

Exceptions

Exception

WorkflowTemplate update(string $name, WorkflowTemplate $postBody, array $optParams = [])

Updates (replaces) workflow template. The updated template must contain version that matches the current server version. (workflowTemplates.update)

Parameters

string $name

Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names. For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id} For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

WorkflowTemplate $postBody
array $optParams

Optional parameters.

Return Value

WorkflowTemplate

Exceptions

Exception