javaJava @Scheduled
@Scheduled(cron = "0 0 9 * * MON-FRI")fieldsField breakdown
- SEC0at second 00-59
- MIN0at minute 00-59
- HR9at 09:000-23
- DOM*on every day of the month1-31 · L · W
- MON*in every month1-12 · JAN-DEC
- DOWMON-FRIMonday to Friday0-7 · MON-SUN · L · #
Spring replaces names before parsing: MON-FRI = 1-5 .
next runsNext executions (UTC)
| time | date | in |
|---|---|---|
| 09:00:00 | Mon, 5 Oct 2026 | in 1 day |
| 09:00:00 | Tue, 6 Oct 2026 | in 2 days |
| 09:00:00 | Wed, 7 Oct 2026 | in 3 days |
| 09:00:00 | Thu, 8 Oct 2026 | in 4 days |
| 09:00:00 | Fri, 9 Oct 2026 | in 5 days |
mistakesCommon mistakes
- Using the 24-hour field 9 with a 12-hour assumption: in cron the hour field is always 0-23.
- Leaving the timezone implicit — 9 AM means 9 AM in the job timezone.