Daily cleanup job at 3:15 AM

cron expression Quartz
$ 0 15 3 * * ?

Runs every day at 3:15 AM.

0
Second
15
Minute
3
Hour
*
Day of Month
*
Month
?
Day of Week

* In a Nutshell

The cron expression 0 15 3 * * ? runs Runs every day at 3:15 AM.. This schedule is ideal for routine maintenance tasks that can tolerate a slight delay after midnight, such as log rotation, temporary file cleanup, or minor database optimization. Running it during off-peak hours ensures minimal impact on user-facing services.

* When to use this

Use 0 15 3 * * ? when a recurring task needs to run Runs every day at 3:15 AM.. This schedule is commonly associated with daily schedules and quartz scheduler workloads. It uses Quartz Scheduler (6–7 Fields) syntax, supported by Unix cron daemons, cloud schedulers such as AWS EventBridge, and container orchestration platforms such as Kubernetes CronJob.

CronBase parses 0 15 3 * * ? using a dialect-aware rules engine that identifies the Quartz Scheduler (6–7 Fields) format, validates field structure against the Quartz Scheduler (6–7 Fields) specification, and produces the translation above. Next run times are calculated by forward-scanning from the current UTC clock. Learn how CronBase works.

Platform Implementations

Bash

This cron expression is for Quartz and not directly usable in bash. Use '15 3 * * ?' with standard cron syntax.

bash
0 15 3 * * ?

Last verified:

Nodejs

This cron expression is for Quartz. For node-cron, use '15 3 * * *'.

nodejs
0 15 3 * * ?

Last verified:

Python

This cron expression is for Quartz. For APScheduler, use '15 3 * * *'.

python
0 15 3 * * ?

Last verified:

Golang

This cron expression is for Quartz. For go-cron, use '15 3 * * *'.

golang
0 15 3 * * ?

Last verified:

Java

Use this expression directly in your Quartz scheduler configuration.

java
0 15 3 * * ?

Last verified:

Kubernetes

Use the 'schedule' field in your Kubernetes CronJob definition with this Quartz expression.

kubernetes
{
  "schedule": "0 15 3 * * ?"
}

Last verified:

Frequently Asked Questions

What does the cron expression '0 15 3 * * ?' do?

This Quartz cron expression specifies a job that will run every day at 3:15 AM.

Does the timezone matter for this schedule?

Yes, the schedule will run at 3:15 AM in the timezone configured for the Quartz scheduler. It's crucial to ensure the scheduler's timezone aligns with operational expectations.

How can I verify this job is running correctly?

You can verify the job's execution by checking the scheduler's logs for entries related to the job's activation at 3:15 AM, or by implementing a simple log statement within the job itself.

What is a common variant of this schedule?

A common variant would be to run the job at midnight daily, using the cron expression '0 0 0 * * ?'. This is often preferred for tasks that should execute as soon as a day ends.

Are there any common pitfalls with this expression?

A potential pitfall is the 'ec_overlapping-run' edge case if the cleanup task takes longer than 15 minutes to complete, as a new instance could start before the previous one finishes.

More schedules like this

Explore Daily Schedules →

* Try any expression

Standard, Quartz, AWS EventBridge, Jenkins, named schedules (@daily, @hourly…)

* Keep Exploring

Related expressions you might need