(cron: string, fromMs: number)
| 300 | * Returns null if invalid or no match in the next 366 days. |
| 301 | */ |
| 302 | export function nextCronRunMs(cron: string, fromMs: number): number | null { |
| 303 | const fields = parseCronExpression(cron) |
| 304 | if (!fields) return null |
| 305 | const next = computeNextCronRun(fields, new Date(fromMs)) |
| 306 | return next ? next.getTime() : null |
| 307 | } |
| 308 | |
| 309 | /** |
| 310 | * Cron scheduler tuning knobs. Sourced at runtime from the |
no test coverage detected