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.
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.
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.
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.
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.
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.
[[["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-08-07 UTC."],[],[],null,["# Interface Task.TriggerSpecOrBuilder (0.16.0)\n\nVersion latestkeyboard_arrow_down\n\n- [0.16.0 (latest)](/java/docs/reference/google-cloudevent-types/latest/com.google.events.cloud.dataplex.v1.Task.TriggerSpecOrBuilder)\n- [0.15.0](/java/docs/reference/google-cloudevent-types/0.15.0/com.google.events.cloud.dataplex.v1.Task.TriggerSpecOrBuilder)\n- [0.14.1](/java/docs/reference/google-cloudevent-types/0.14.1/com.google.events.cloud.dataplex.v1.Task.TriggerSpecOrBuilder) \n\n public static interface Task.TriggerSpecOrBuilder extends MessageOrBuilder\n\nImplements\n----------\n\n[MessageOrBuilder](https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.MessageOrBuilder.html)\n\nMethods\n-------\n\n### getDisabled()\n\n public abstract boolean getDisabled()\n\nOptional. Prevent the task from executing.\nThis does not cancel already running tasks. It is intended to temporarily\ndisable RECURRING tasks.\n\n`bool disabled = 4;`\n\n### getMaxRetries()\n\n public abstract int getMaxRetries()\n\nOptional. Number of retry attempts before aborting.\nSet to zero to never attempt to retry a failed task.\n\n`int32 max_retries = 7;`\n\n### getSchedule()\n\n public abstract String 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`string schedule = 100;`\n\n### getScheduleBytes()\n\n public abstract ByteString getScheduleBytes()\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`string schedule = 100;`\n\n### getStartTime()\n\n public abstract Timestamp getStartTime()\n\nOptional. The first run of the task will be after this time.\nIf not specified, the task will run shortly after being submitted if\nON_DEMAND and based on the schedule if RECURRING.\n\n`.google.protobuf.Timestamp start_time = 6;`\n\n### getStartTimeOrBuilder()\n\n public abstract TimestampOrBuilder getStartTimeOrBuilder()\n\nOptional. The first run of the task will be after this time.\nIf not specified, the task will run shortly after being submitted if\nON_DEMAND and based on the schedule if RECURRING.\n\n`.google.protobuf.Timestamp start_time = 6;`\n\n### getTriggerCase()\n\n public abstract Task.TriggerSpec.TriggerCase getTriggerCase()\n\n### getType()\n\n public abstract Task.TriggerSpec.Type getType()\n\nRequired. Immutable. Trigger type of the user-specified Task.\n\n`.google.events.cloud.dataplex.v1.Task.TriggerSpec.Type type = 5;`\n\n### getTypeValue()\n\n public abstract int getTypeValue()\n\nRequired. Immutable. Trigger type of the user-specified Task.\n\n`.google.events.cloud.dataplex.v1.Task.TriggerSpec.Type type = 5;`\n\n### hasSchedule()\n\n public abstract boolean hasSchedule()\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`string schedule = 100;`\n\n### hasStartTime()\n\n public abstract boolean hasStartTime()\n\nOptional. The first run of the task will be after this time.\nIf not specified, the task will run shortly after being submitted if\nON_DEMAND and based on the schedule if RECURRING.\n\n`.google.protobuf.Timestamp start_time = 6;`"]]