Service Client: Google::Cloud::Run::V2::Task::TasksClient

Client stub representing the remote Tasks gRPC service. Delegates call dispatching to Google::gRPC::Client.

target

The endpoint target address. Defaults to run.googleapis.com:443.

credentials

The authentication credentials provider. Defaults to application default credentials via Google::Auth.

NAME

Google::Cloud::Run::V2::Task - Compiled Protocol Buffers messages for google/cloud/run/v2/task.proto

SYNOPSIS

use Google::Cloud::Run::V2::Task;

my $msg = Google::Cloud::Run::V2::Task::GetTaskRequest->new({
    name => $name,
});

# Read or update a field
my $val = $msg->name();

# Binary wire-format roundtrip
my $bytes   = $msg->serialize();
my $decoded = Google::Cloud::Run::V2::Task::GetTaskRequest->parse($bytes);

# Canonical ProtoJSON
my $json = $msg->to_json();

DESCRIPTION

Auto-generated Protobuf message classes compiled from google/cloud/run/v2/task.proto. All message classes inherit from Protobuf::Message and support new(), serialize(), parse(), to_json(), from_json(), to_text(), and to_perl().

MESSAGES

Google::Cloud::Run::V2::Task::GetTaskRequest

Request message for obtaining a Task by its full name.

Inherits from Protobuf::Message.

Accessors

  • $msg->name() / $msg->name($value)

    Type: String

    Required. The full name of the Task. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}/tasks/{task}

Google::Cloud::Run::V2::Task::ListTasksRequest

Request message for retrieving a list of Tasks.

Inherits from Protobuf::Message.

Accessors

  • $msg->parent() / $msg->parent($value)

    Type: String

    Required. The Execution from which the Tasks should be listed. To list all Tasks across Executions of a Job, use "-" instead of Execution name. To list all Tasks across Jobs, use "-" instead of Job name. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}

  • $msg->page_size() / $msg->page_size($value)

    Type: Int32

    Maximum number of Tasks to return in this call.

  • $msg->page_token() / $msg->page_token($value)

    Type: String

    A page token received from a previous call to ListTasks. All other parameters must match.

  • $msg->show_deleted() / $msg->show_deleted($value)

    Type: Bool

    If true, returns deleted (but unexpired) resources along with active ones.

Google::Cloud::Run::V2::Task::ListTasksResponse

Response message containing a list of Tasks.

Inherits from Protobuf::Message.

Accessors

  • $msg->tasks() / $msg->tasks($value)

    Type: Message (Google::Cloud::Run::V2::Task::Task)

    The resulting list of Tasks.

  • $msg->next_page_token() / $msg->next_page_token($value)

    Type: String

    A token indicating there are more items than page_size. Use it in the next ListTasks request to continue.

Google::Cloud::Run::V2::Task::Task

Task represents a single run of a container to completion.

Inherits from Protobuf::Message.

Accessors

  • $msg->name() / $msg->name($value)

    Type: String

    Output only. The unique name of this Task.

  • $msg->uid() / $msg->uid($value)

    Type: String

    Output only. Server assigned unique identifier for the Task. The value is a UUID4 string and guaranteed to remain unchanged until the resource is deleted.

  • $msg->generation() / $msg->generation($value)

    Type: Int64

    Output only. A number that monotonically increases every time the user modifies the desired state.

  • $msg->labels() / $msg->labels($value)

    Type: Message (Google::Cloud::Run::V2::Task::Task::LabelsEntry)

    Output only. Unstructured key value map that can be used to organize and categorize objects. User-provided labels are shared with Google's billing system, so they can be used to filter, or break down billing charges by team, component, environment, state, etc. For more information, visit https://cloud.google.com/resource-manager/docs/creating-managing-labels or https://cloud.google.com/run/docs/configuring/labels

  • $msg->annotations() / $msg->annotations($value)

    Type: Message (Google::Cloud::Run::V2::Task::Task::AnnotationsEntry)

    Output only. Unstructured key value map that may be set by external tools to store and arbitrary metadata. They are not queryable and should be preserved when modifying objects.

  • $msg->create_time() / $msg->create_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. Represents time when the task was created by the system. It is not guaranteed to be set in happens-before order across separate operations.

  • $msg->scheduled_time() / $msg->scheduled_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. Represents time when the task was scheduled to run by the system. It is not guaranteed to be set in happens-before order across separate operations.

  • $msg->start_time() / $msg->start_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. Represents time when the task started to run. It is not guaranteed to be set in happens-before order across separate operations.

  • $msg->completion_time() / $msg->completion_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. Represents time when the Task was completed. It is not guaranteed to be set in happens-before order across separate operations.

  • $msg->update_time() / $msg->update_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. The last-modified time.

  • $msg->delete_time() / $msg->delete_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. For a deleted resource, the deletion time. It is only populated as a response to a Delete request.

  • $msg->expire_time() / $msg->expire_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. For a deleted resource, the time after which it will be permamently deleted. It is only populated as a response to a Delete request.

  • $msg->job() / $msg->job($value)

    Type: String

    Output only. The name of the parent Job.

  • $msg->execution() / $msg->execution($value)

    Type: String

    Output only. The name of the parent Execution.

  • $msg->containers() / $msg->containers($value)

    Type: Message (Google::Cloud::Run::V2::K8sMin::Container)

    Holds the single container that defines the unit of execution for this task.

  • $msg->sandboxes() / $msg->sandboxes($value)

    Type: Message (Google::Cloud::Run::V2::Sandbox::SandboxConfiguration)

    Configuration for sandboxes.

  • $msg->volumes() / $msg->volumes($value)

    Type: Message (Google::Cloud::Run::V2::K8sMin::Volume)

    A list of Volumes to make available to containers.

  • $msg->max_retries() / $msg->max_retries($value)

    Type: Int32

    Number of retries allowed per Task, before marking this Task failed.

  • $msg->timeout() / $msg->timeout($value)

    Type: Message (Google::Protobuf::Duration::Duration)

    Max allowed time duration the Task may be active before the system will actively try to mark it failed and kill associated containers. This applies per attempt of a task, meaning each retry can run for the full timeout.

  • $msg->service_account() / $msg->service_account($value)

    Type: String

    Email address of the IAM service account associated with the Task of a Job. The service account represents the identity of the running task, and determines what permissions the task has. If not provided, the task will use the project's default service account.

  • $msg->execution_environment() / $msg->execution_environment($value)

    Type: Enum (Google::Cloud::Run::V2::ExecutionEnvironment)

    The execution environment being used to host this Task.

  • $msg->reconciling() / $msg->reconciling($value)

    Type: Bool

    Output only. Indicates whether the resource's reconciliation is still in progress. See comments in `Job.reconciling` for additional information on reconciliation process in Cloud Run.

  • $msg->conditions() / $msg->conditions($value)

    Type: Message (Google::Cloud::Run::V2::Condition::Condition)

    Output only. The Condition of this Task, containing its readiness status, and detailed error information in case it did not reach the desired state.

  • $msg->observed_generation() / $msg->observed_generation($value)

    Type: Int64

    Output only. The generation of this Task. See comments in `Job.reconciling` for additional information on reconciliation process in Cloud Run.

  • $msg->index() / $msg->index($value)

    Type: Int32

    Output only. Index of the Task, unique per execution, and beginning at 0.

  • $msg->retried() / $msg->retried($value)

    Type: Int32

    Output only. The number of times this Task was retried. Tasks are retried when they fail up to the maxRetries limit.

  • $msg->last_attempt_result() / $msg->last_attempt_result($value)

    Type: Message (Google::Cloud::Run::V2::Task::TaskAttemptResult)

    Output only. Result of the last attempt of this Task.

  • $msg->encryption_key() / $msg->encryption_key($value)

    Type: String

    Output only. A reference to a customer managed encryption key (CMEK) to use to encrypt this container image. For more information, go to https://cloud.google.com/run/docs/securing/using-cmek

  • $msg->vpc_access() / $msg->vpc_access($value)

    Type: Message (Google::Cloud::Run::V2::VendorSettings::VpcAccess)

    Output only. VPC Access configuration to use for this Task. For more information, visit https://cloud.google.com/run/docs/configuring/connecting-vpc.

  • $msg->log_uri() / $msg->log_uri($value)

    Type: String

    Output only. URI where logs for this execution can be found in Cloud Console.

  • $msg->satisfies_pzs() / $msg->satisfies_pzs($value)

    Type: Bool

    Output only. Reserved for future use.

  • $msg->node_selector() / $msg->node_selector($value)

    Type: Message (Google::Cloud::Run::V2::VendorSettings::NodeSelector)

    Output only. The node selector for the task.

  • $msg->gpu_zonal_redundancy_disabled() / $msg->gpu_zonal_redundancy_disabled($value)

    Type: Bool

    Optional. Output only. True if GPU zonal redundancy is disabled on this task.

  • $msg->workload_identity_config() / $msg->workload_identity_config($value)

    Type: Message (Google::Cloud::Run::V2::VendorSettings::WorkloadIdentityConfig)

    Optional. The Task's workload identity settings.

  • $msg->etag() / $msg->etag($value)

    Type: String

    Output only. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.

Google::Cloud::Run::V2::Task::TaskAttemptResult

Result of a task attempt.

Inherits from Protobuf::Message.

Accessors

  • $msg->status() / $msg->status($value)

    Type: Message (Google::Rpc::Status::Status)

    Output only. The status of this attempt. If the status code is OK, then the attempt succeeded.

  • $msg->exit_code() / $msg->exit_code($value)

    Type: Int32

    Output only. The exit code of this attempt. This may be unset if the container was unable to exit cleanly with a code due to some other failure. See status field for possible failure details.

    At most one of exit_code or term_signal will be set.

  • $msg->term_signal() / $msg->term_signal($value)

    Type: Int32

    Output only. Termination signal of the container. This is set to non-zero if the container is terminated by the system.

    At most one of exit_code or term_signal will be set.

SEE ALSO

Protobuf, Protobuf::Message, Google::Cloud::Run::V2::Task::Types, https://protobuf.dev/

LICENSE AND COPYRIGHT

Copyright (C) 2026 Google LLC

This program is released under the Apache 2.0 license.