| 1 |
""" |
| 2 |
Cron configuration file #2 for testing the rqcron management command. |
| 3 |
Contains different jobs for alternative test scenarios. |
| 4 |
""" |
| 5 |
|
| 6 |
from rq import cron |
| 7 |
|
| 8 |
from .fixtures import say_hello |
| 9 |
|
| 10 |
# Register a job with different arguments for testing |
| 11 |
cron.register(say_hello, 'default', args=('from cron config2',), cron='*/2 * * * *') # Every 2 minutes |
| 12 |
|
| 13 |
# Register another job with a different interval |
| 14 |
cron.register(say_hello, 'default', args=('every 10 seconds config2',), interval=10) |