Google Cloud Dataplex V1 Client - Class Task (1.11.0)

Reference documentation and code samples for the Google Cloud Dataplex V1 Client class Task.

A task represents a user-visible job.

Generated from protobuf messagegoogle.cloud.dataplex.v1.Task

Namespace

Google \ Cloud \ Dataplex \ V1

Methods

__construct

Constructor.

Parameters
NameDescription
dataarray

Optional. Data for populating the Message object.

↳ namestring

Output only. The relative resource name of the task, of the form: projects/{project_number}/locations/{location_id}/lakes/{lake_id}/ tasks/{task_id}.

↳ uidstring

Output only. System generated globally unique ID for the task. This ID will be different if the task is deleted and re-created with the same name.

↳ create_timeGoogle\Protobuf\Timestamp

Output only. The time when the task was created.

↳ update_timeGoogle\Protobuf\Timestamp

Output only. The time when the task was last updated.

↳ descriptionstring

Optional. Description of the task.

↳ display_namestring

Optional. User friendly display name.

↳ stateint

Output only. Current state of the task.

↳ labelsarray|Google\Protobuf\Internal\MapField

Optional. User-defined labels for the task.

↳ trigger_specTask\TriggerSpec

Required. Spec related to how often and when a task should be triggered.

↳ execution_specTask\ExecutionSpec

Required. Spec related to how a task is executed.

↳ execution_statusTask\ExecutionStatus

Output only. Status of the latest task executions.

↳ sparkTask\SparkTaskConfig

Config related to running custom Spark tasks.

↳ notebookTask\NotebookTaskConfig

Config related to running scheduled Notebooks.

getName

Output only. The relative resource name of the task, of the form:projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{task_id}.

Returns
TypeDescription
string

setName

Output only. The relative resource name of the task, of the form:projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{task_id}.

Parameter
NameDescription
varstring
Returns
TypeDescription
$this

getUid

Output only. System generated globally unique ID for the task. This ID willbe different if the task is deleted and re-created with the same name.

Returns
TypeDescription
string

setUid

Output only. System generated globally unique ID for the task. This ID willbe different if the task is deleted and re-created with the same name.

Parameter
NameDescription
varstring
Returns
TypeDescription
$this

getCreateTime

Output only. The time when the task was created.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasCreateTime

clearCreateTime

setCreateTime

Output only. The time when the task was created.

Parameter
NameDescription
varGoogle\Protobuf\Timestamp
Returns
TypeDescription
$this

getUpdateTime

Output only. The time when the task was last updated.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasUpdateTime

clearUpdateTime

setUpdateTime

Output only. The time when the task was last updated.

Parameter
NameDescription
varGoogle\Protobuf\Timestamp
Returns
TypeDescription
$this

getDescription

Optional. Description of the task.

Returns
TypeDescription
string

setDescription

Optional. Description of the task.

Parameter
NameDescription
varstring
Returns
TypeDescription
$this

getDisplayName

Optional. User friendly display name.

Returns
TypeDescription
string

setDisplayName

Optional. User friendly display name.

Parameter
NameDescription
varstring
Returns
TypeDescription
$this

getState

Output only. Current state of the task.

Returns
TypeDescription
intEnum of typeState.

setState

Output only. Current state of the task.

Parameter
NameDescription
varint

Enum of typeState.

Returns
TypeDescription
$this

getLabels

Optional. User-defined labels for the task.

Returns
TypeDescription
Google\Protobuf\Internal\MapField

setLabels

Optional. User-defined labels for the task.

Parameter
NameDescription
vararray|Google\Protobuf\Internal\MapField
Returns
TypeDescription
$this

getTriggerSpec

Required. Spec related to how often and when a task should be triggered.

Returns
TypeDescription
Task\TriggerSpec|null

hasTriggerSpec

clearTriggerSpec

setTriggerSpec

Required. Spec related to how often and when a task should be triggered.

Parameter
NameDescription
varTask\TriggerSpec
Returns
TypeDescription
$this

getExecutionSpec

Required. Spec related to how a task is executed.

Returns
TypeDescription
Task\ExecutionSpec|null

hasExecutionSpec

clearExecutionSpec

setExecutionSpec

Required. Spec related to how a task is executed.

Parameter
NameDescription
varTask\ExecutionSpec
Returns
TypeDescription
$this

getExecutionStatus

Output only. Status of the latest task executions.

Returns
TypeDescription
Task\ExecutionStatus|null

hasExecutionStatus

clearExecutionStatus

setExecutionStatus

Output only. Status of the latest task executions.

Parameter
NameDescription
varTask\ExecutionStatus
Returns
TypeDescription
$this

getSpark

Config related to running custom Spark tasks.

Returns
TypeDescription
Task\SparkTaskConfig|null

hasSpark

setSpark

Config related to running custom Spark tasks.

Parameter
NameDescription
varTask\SparkTaskConfig
Returns
TypeDescription
$this

getNotebook

Config related to running scheduled Notebooks.

Returns
TypeDescription
Task\NotebookTaskConfig|null

hasNotebook

setNotebook

Config related to running scheduled Notebooks.

Parameter
NameDescription
varTask\NotebookTaskConfig
Returns
TypeDescription
$this

getConfig

Returns
TypeDescription
string

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-11-08 UTC.