mirror of
https://github.com/django-q2/django-q2.git
synced 2026-10-04 17:58:11 +08:00
docs: minor updates
This commit is contained in:
@@ -40,6 +40,8 @@ Here you can check on the status of your scheduled tasks, create, edit or delete
|
|||||||
|
|
||||||
.. image:: _static/scheduled.png
|
.. image:: _static/scheduled.png
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Repeats
|
Repeats
|
||||||
~~~~~~~
|
~~~~~~~
|
||||||
If you want a schedule to only run a finite amount of times, e.g. every hour for the next 24 hours, you can do that using the :attr:`Schedule.repeats` attribute.
|
If you want a schedule to only run a finite amount of times, e.g. every hour for the next 24 hours, you can do that using the :attr:`Schedule.repeats` attribute.
|
||||||
@@ -50,6 +52,8 @@ When you set repeats to ``-1`` the schedule will continue indefinitely and the r
|
|||||||
An exception to this are schedules of type :attr:`Schedule.ONCE`. Negative repeats for this schedule type will cause it to be deleted from the database.
|
An exception to this are schedules of type :attr:`Schedule.ONCE`. Negative repeats for this schedule type will cause it to be deleted from the database.
|
||||||
This behavior is useful if you have many delayed actions which you do not necessarily need a result for. A positive number will keep the ONCE schedule, but it will not run again.
|
This behavior is useful if you have many delayed actions which you do not necessarily need a result for. A positive number will keep the ONCE schedule, but it will not run again.
|
||||||
|
|
||||||
|
You can pause a schedule by setting its repeats value to zero.
|
||||||
|
|
||||||
.. note::
|
.. note::
|
||||||
|
|
||||||
To run a ``ONCE`` schedule again, change the repeats to something other than `0`. Set a new run time before you do this or let it execute immediately.
|
To run a ``ONCE`` schedule again, change the repeats to something other than `0`. Set a new run time before you do this or let it execute immediately.
|
||||||
|
|||||||
+1
-1
@@ -49,7 +49,7 @@ Missed schedules
|
|||||||
If your cluster has not run for a while, the default behavior for the scheduler is to play catch up with the schedules and keep executing them until they are up to date.
|
If your cluster has not run for a while, the default behavior for the scheduler is to play catch up with the schedules and keep executing them until they are up to date.
|
||||||
For example, if your cluster was down for a day and you start it again. Any hourly schedules you had will run 24 times, once every schedule loop, until they are back in sync.
|
For example, if your cluster was down for a day and you start it again. Any hourly schedules you had will run 24 times, once every schedule loop, until they are back in sync.
|
||||||
This behavior is intended to facilitate schedules that poll or gather statistics, but might not be suitable to your particular situation.
|
This behavior is intended to facilitate schedules that poll or gather statistics, but might not be suitable to your particular situation.
|
||||||
You can change this by settings the :ref:`catch_up` configuration setting to ``False``.
|
You can change this by setting the :ref:`catch_up` configuration setting to ``False``.
|
||||||
The scheduler will then skip execution of scheduled events in the past. Instead those tasks will run only once and normal scheduling resumes.
|
The scheduler will then skip execution of scheduled events in the past. Instead those tasks will run only once and normal scheduling resumes.
|
||||||
|
|
||||||
Management Commands
|
Management Commands
|
||||||
|
|||||||
Reference in New Issue
Block a user