Skip to content

featurebyte.CronFeatureJobSetting

class CronFeatureJobSetting(
*,
crontab: Crontab,
timezone: TimeZoneName="Etc/UTC"
)

Description

CronFeatureJobSetting class is used to declare a cron-based Feature Job Setting. The setting comprises two parameters:

  • The crontab parameter specifies the cron schedule for the feature job.
  • The timezone parameter defines the timezone for the cron schedule. It is used to determine the time at which the feature job should run.

Parameters

  • crontab: Crontab

  • timezone: TimeZoneName
    default: "Etc/UTC"

Examples

Consider a case study where a data warehouse refreshes each hour. The data refresh starts 10 seconds after the hour based on the UTC timezone.

  • crontab: "10 * * * "
  • timezone: "Etc/UTC"
>>> feature_job_setting = fb.CronFeatureJobSetting(
...     crontab=Crontab(
...         minute=10, hour="", day_of_week="", day_of_month="", month_of_year="*"
...     ),
...     timezone="Etc/UTC",
... )