Skip to content

Commit 25bcc5e

Browse files
committed
docs: add more schedule sources
1 parent 6222908 commit 25bcc5e

File tree

1 file changed

+46
-3
lines changed

1 file changed

+46
-3
lines changed

docs/available-components/schedule-sources.md

Lines changed: 46 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,12 @@ order: 4
55
# Available schedule sources
66

77
These objects are used to fetch current schedule for tasks.
8-
Currently we have only one schedule source.
98

10-
## RedisScheduleSource
9+
## Official schedule sources
10+
11+
These schedule sources are not part of the core Taskiq library. But they are maintained by Taskiq developers. You can install them as a separate package.
12+
13+
### RedisScheduleSource
1114

1215
This source is capable of adding new schedules in runtime. It uses Redis as a storage for schedules.
1316
To use this source you need to install `taskiq-redis` package.
@@ -24,7 +27,7 @@ scheduler = TaskiqScheduler(broker, sources=[redis_source])
2427
For more information on how to use dynamic schedule sources read [Dynamic scheduling section](../guide/scheduling-tasks.md#dynamic-scheduling).
2528

2629

27-
## LabelScheduleSource
30+
### LabelScheduleSource
2831

2932
This source parses labels of tasks, and if it finds a `schedule` label, it considers this task as scheduled.
3033

@@ -76,3 +79,43 @@ In order to resolve all labels correctly, don't forget to import
7679
all task modules using CLI interface.
7780

7881
:::
82+
83+
### NATS schedule source
84+
85+
This source is capable of adding new schedules in runtime. It uses NATS as a storage for schedules.
86+
To use this source you need to install `taskiq-nats` package.
87+
88+
```python
89+
from taskiq_nats import NATSKeyValueScheduleSource
90+
from taskiq.scheduler import TaskiqScheduler
91+
92+
93+
broker = ...
94+
95+
scheduler = TaskiqScheduler(
96+
broker=broker,
97+
sources=[NATSKeyValueScheduleSource(broker)],
98+
)
99+
```
100+
101+
This schedule source doesn't use `schedule` label on tasks. To add new schedules, you need to call `add_schedule` method on the source.
102+
103+
## Third-party schedule sources
104+
105+
These schedule sources are not part of the core Taskiq library. They are maintained by other open‑source contributors. You can install them as a separate packages.
106+
107+
### PostgreSQL schedule source
108+
109+
Project link: [taskiq-postgres](https://github.com/danfimov/taskiq-postgres)
110+
111+
```bash
112+
pip install taskiq-postgres
113+
```
114+
115+
### YDB schedule source
116+
117+
Project link: [taskiq-ydb](https://github.com/danfimov/taskiq-ydb)
118+
119+
```bash
120+
pip install taskiq-ydb
121+
```

0 commit comments

Comments
 (0)