NewGoCronJob
Constructs a GoCronJob.
def NewGoCronJob(
ctx: context.Context,
t: *models.Trigger,
executor: Executor
) - > *GoCronJob
Constructs a GoCronJob object. This function is used to create a new cron job instance, associating it with a specific trigger and an executor.
Parameters
| Name | Type | Description |
|---|---|---|
| ctx | context.Context | The context for the cron job, used for cancellation and carrying request-scoped values. |
| t | *models.Trigger | The trigger definition for the cron job, specifying when and how often the job should run. |
| executor | Executor | The executor responsible for running the cron job's tasks when triggered. |
Returns
| Type | Description |
|---|---|
*GoCronJob | A new instance of GoCronJob configured with the provided context, trigger, and executor. |