Interface ResonateSchedules

interface ResonateSchedules {
    create(id, cron, promiseId, promiseTimeout, opts?): Promise<Schedule>;
    get(id): Promise<Schedule>;
    search(id, tags, limit?): AsyncGenerator<Schedule[], void, unknown>;
}

Methods

Methods

  • Create a new schedule.

    Parameters

    • id: string

      Unique identifier for the schedule.

    • cron: string

      CRON expression defining the schedule's execution time.

    • promiseId: string

      Unique identifier for the associated promise.

    • promiseTimeout: number

      Timeout for the associated promise in milliseconds.

    • Optional opts: Partial<schedules.Options>

      Additional options.

    Returns Promise<Schedule>

    A schedule.

  • Search for schedules.

    Parameters

    • id: string

      Ids to match, can include wildcards.

    • tags: undefined | Record<string, string>

      Tags to match.

    • Optional limit: number

      Maximum number of schedules to return.

    Returns AsyncGenerator<Schedule[], void, unknown>

    A generator that yields schedules.