Optional. The first run of the task will be after this time. If not specified, the task will run shortly after being submitted if ON_DEMAND and based on the schedule if RECURRING.
↳ disabled
bool
Optional. Prevent the task from executing. This does not cancel already running tasks. It is intended to temporarily disable RECURRING tasks.
↳ max_retries
int
Optional. Number of retry attempts before aborting. Set to zero to never attempt to retry a failed task.
↳ schedule
string
Optional. Cron schedule (https://en.wikipedia.org/wiki/Cron) for running tasks periodically. To explicitly set a timezone to the cron tab, apply a prefix in the cron tab: "CRON_TZ=${IANA_TIME_ZONE}" or "TZ=${IANA_TIME_ZONE}". The ${IANA_TIME_ZONE} may only be a valid string from IANA time zone database. For example, CRON_TZ=America/New_York 1 * * * *, or TZ=America/New_York 1 * * * *. This field is required for RECURRING tasks.
getType
Required. Immutable. Trigger type of the user-specified Task.
Returns
Type
Description
int
setType
Required. Immutable. Trigger type of the user-specified Task.
Parameter
Name
Description
var
int
Returns
Type
Description
$this
getStartTime
Optional. The first run of the task will be after this time.
If not specified, the task will run shortly after being submitted if
ON_DEMAND and based on the schedule if RECURRING.
This does not cancel already running tasks. It is intended to temporarily
disable RECURRING tasks.
Returns
Type
Description
bool
setDisabled
Optional. Prevent the task from executing.
This does not cancel already running tasks. It is intended to temporarily
disable RECURRING tasks.
Parameter
Name
Description
var
bool
Returns
Type
Description
$this
getMaxRetries
Optional. Number of retry attempts before aborting.
Set to zero to never attempt to retry a failed task.
Returns
Type
Description
int
setMaxRetries
Optional. Number of retry attempts before aborting.
Set to zero to never attempt to retry a failed task.
Parameter
Name
Description
var
int
Returns
Type
Description
$this
getSchedule
Optional. Cron schedule (https://en.wikipedia.org/wiki/Cron) for
running tasks periodically. To explicitly set a timezone to the cron
tab, apply a prefix in the cron tab: "CRON_TZ=${IANA_TIME_ZONE}" or
"TZ=${IANA_TIME_ZONE}". The ${IANA_TIME_ZONE} may only be a valid
string from IANA time zone database. For example,
CRON_TZ=America/New_York 1 * * * *, or TZ=America/New_York 1 * * *
*. This field is required for RECURRING tasks.
Returns
Type
Description
string
hasSchedule
setSchedule
Optional. Cron schedule (https://en.wikipedia.org/wiki/Cron) for
running tasks periodically. To explicitly set a timezone to the cron
tab, apply a prefix in the cron tab: "CRON_TZ=${IANA_TIME_ZONE}" or
"TZ=${IANA_TIME_ZONE}". The ${IANA_TIME_ZONE} may only be a valid
string from IANA time zone database. For example,
CRON_TZ=America/New_York 1 * * * *, or TZ=America/New_York 1 * * *
*. This field is required for RECURRING tasks.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Google Cloud Dataplex V1 Client - Class TriggerSpec (1.7.1)\n\nVersion latestkeyboard_arrow_down\n\n- [1.7.1 (latest)](/php/docs/reference/cloud-dataplex/latest/V1.Task.TriggerSpec)\n- [1.7.0](/php/docs/reference/cloud-dataplex/1.7.0/V1.Task.TriggerSpec)\n- [1.6.1](/php/docs/reference/cloud-dataplex/1.6.1/V1.Task.TriggerSpec)\n- [1.4.0](/php/docs/reference/cloud-dataplex/1.4.0/V1.Task.TriggerSpec)\n- [1.3.0](/php/docs/reference/cloud-dataplex/1.3.0/V1.Task.TriggerSpec)\n- [1.2.1](/php/docs/reference/cloud-dataplex/1.2.1/V1.Task.TriggerSpec)\n- [1.1.1](/php/docs/reference/cloud-dataplex/1.1.1/V1.Task.TriggerSpec)\n- [1.0.1](/php/docs/reference/cloud-dataplex/1.0.1/V1.Task.TriggerSpec)\n- [0.16.1](/php/docs/reference/cloud-dataplex/0.16.1/V1.Task.TriggerSpec)\n- [0.15.1](/php/docs/reference/cloud-dataplex/0.15.1/V1.Task.TriggerSpec)\n- [0.14.0](/php/docs/reference/cloud-dataplex/0.14.0/V1.Task.TriggerSpec)\n- [0.13.0](/php/docs/reference/cloud-dataplex/0.13.0/V1.Task.TriggerSpec)\n- [0.12.0](/php/docs/reference/cloud-dataplex/0.12.0/V1.Task.TriggerSpec)\n- [0.11.1](/php/docs/reference/cloud-dataplex/0.11.1/V1.Task.TriggerSpec)\n- [0.10.0](/php/docs/reference/cloud-dataplex/0.10.0/V1.Task.TriggerSpec)\n- [0.9.0](/php/docs/reference/cloud-dataplex/0.9.0/V1.Task.TriggerSpec)\n- [0.8.0](/php/docs/reference/cloud-dataplex/0.8.0/V1.Task.TriggerSpec)\n- [0.7.0](/php/docs/reference/cloud-dataplex/0.7.0/V1.Task.TriggerSpec)\n- [0.6.0](/php/docs/reference/cloud-dataplex/0.6.0/V1.Task.TriggerSpec)\n- [0.5.1](/php/docs/reference/cloud-dataplex/0.5.1/V1.Task.TriggerSpec)\n- [0.4.0](/php/docs/reference/cloud-dataplex/0.4.0/V1.Task.TriggerSpec)\n- [0.3.0](/php/docs/reference/cloud-dataplex/0.3.0/V1.Task.TriggerSpec)\n- [0.2.3](/php/docs/reference/cloud-dataplex/0.2.3/V1.Task.TriggerSpec)\n- [0.1.6](/php/docs/reference/cloud-dataplex/0.1.6/V1.Task.TriggerSpec) \nReference documentation and code samples for the Google Cloud Dataplex V1 Client class TriggerSpec.\n\nTask scheduling and trigger settings.\n\nGenerated from protobuf message `google.cloud.dataplex.v1.Task.TriggerSpec`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ Dataplex \\\\ V1 \\\\ Task\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getType\n\nRequired. Immutable. Trigger type of the user-specified Task.\n\n### setType\n\nRequired. Immutable. Trigger type of the user-specified Task.\n\n### getStartTime\n\nOptional. The first run of the task will be after this time.\n\nIf not specified, the task will run shortly after being submitted if\nON_DEMAND and based on the schedule if RECURRING.\n\n### hasStartTime\n\n### clearStartTime\n\n### setStartTime\n\nOptional. The first run of the task will be after this time.\n\nIf not specified, the task will run shortly after being submitted if\nON_DEMAND and based on the schedule if RECURRING.\n\n### getDisabled\n\nOptional. Prevent the task from executing.\n\nThis does not cancel already running tasks. It is intended to temporarily\ndisable RECURRING tasks.\n\n### setDisabled\n\nOptional. Prevent the task from executing.\n\nThis does not cancel already running tasks. It is intended to temporarily\ndisable RECURRING tasks.\n\n### getMaxRetries\n\nOptional. Number of retry attempts before aborting.\n\nSet to zero to never attempt to retry a failed task.\n\n### setMaxRetries\n\nOptional. Number of retry attempts before aborting.\n\nSet to zero to never attempt to retry a failed task.\n\n### getSchedule\n\nOptional. Cron schedule (\u003chttps://en.wikipedia.org/wiki/Cron\u003e) for\nrunning tasks periodically. To explicitly set a timezone to the cron\ntab, apply a prefix in the cron tab: \"CRON_TZ=${IANA_TIME_ZONE}\" or\n\"TZ=${IANA_TIME_ZONE}\". The ${IANA_TIME_ZONE} may only be a valid\nstring from IANA time zone database. For example,\n`CRON_TZ=America/New_York 1 * * * *`, or `TZ=America/New_York 1 * * *\n*`. This field is required for RECURRING tasks.\n\n### hasSchedule\n\n### setSchedule\n\nOptional. Cron schedule (\u003chttps://en.wikipedia.org/wiki/Cron\u003e) for\nrunning tasks periodically. To explicitly set a timezone to the cron\ntab, apply a prefix in the cron tab: \"CRON_TZ=${IANA_TIME_ZONE}\" or\n\"TZ=${IANA_TIME_ZONE}\". The ${IANA_TIME_ZONE} may only be a valid\nstring from IANA time zone database. For example,\n`CRON_TZ=America/New_York 1 * * * *`, or `TZ=America/New_York 1 * * *\n*`. This field is required for RECURRING tasks.\n\n### getTrigger"]]