-
-
Notifications
You must be signed in to change notification settings - Fork 50
/
Copy pathCargo.toml
146 lines (127 loc) · 3.68 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
[workspace.package]
edition = "2021"
repository = "https://github.com/geofmureithi/apalis"
[package]
name = "apalis"
version = "0.6.4"
authors = ["Geoffrey Mureithi <[email protected]>"]
description = "Simple, extensible multithreaded background job processing for Rust"
edition.workspace = true
repository.workspace = true
documentation = "https://docs.rs/apalis"
readme = "README.md"
license = "MIT OR Apache-2.0"
keywords = ["job", "task", "scheduler", "worker", "cron"]
categories = ["database"]
[lib]
bench = false
[features]
default = ["tracing"]
## Support Tracing 👀
tracing = ["dep:tracing", "dep:tracing-futures"]
## Support for Sentry exception and performance monitoring
sentry = ["sentry-core", "ulid?/uuid", "uuid"]
## Support Prometheus metrics
prometheus = ["metrics", "metrics-exporter-prometheus"]
## Support direct retrying jobs
retry = ["tower/retry"]
## Support timeouts on jobs
timeout = ["tower/timeout"]
## 💪 Limit the amount of jobs
limit = ["tower/limit"]
## Support filtering jobs based on a predicate
filter = ["tower/filter"]
## Captures panics in executions and convert them to errors
catch-panic = []
layers = [
"sentry",
"prometheus",
"tracing",
"retry",
"timeout",
"limit",
"filter",
"catch-panic",
]
docsrs = ["document-features"]
[dependencies.apalis-core]
version = "0.6.4"
default-features = false
path = "./packages/apalis-core"
[dependencies.document-features]
version = "0.2"
optional = true
[package.metadata.docs.rs]
# defines the configuration attribute `docsrs`
rustdoc-args = ["--cfg", "docsrs"]
all-features = true
[dev-dependencies]
criterion = { version = "0.5.1", features = ["async_tokio", "html_reports"] }
pprof = { version = "0.14", features = ["flamegraph"] }
paste = "1.0.14"
serde = "1"
tokio = { version = "1", features = ["macros", "rt-multi-thread"] }
apalis = { path = ".", features = ["limit"] }
apalis-redis = { path = "./packages/apalis-redis" }
apalis-sql = { path = "./packages/apalis-sql", features = [
"postgres",
"mysql",
"sqlite",
] }
redis = { version = "0.27", default-features = false, features = [
"tokio-comp",
"script",
"aio",
"connection-manager",
] }
[dev-dependencies.sqlx]
version = "0.8.1"
default-features = false
features = ["chrono", "mysql", "sqlite", "postgres", "runtime-tokio"]
[workspace]
members = [
"packages/apalis-core",
"packages/apalis-redis",
"packages/apalis-sql",
"packages/apalis-cron",
# Examples
"examples/email-service",
"examples/redis",
"examples/actix-web",
"examples/sqlite",
"examples/sentry",
"examples/mysql",
"examples/postgres",
"examples/axum",
"examples/prometheus",
"examples/tracing",
"examples/async-std-runtime",
"examples/basics",
"examples/redis-with-msg-pack",
"examples/redis-deadpool",
"examples/redis-mq-example",
"examples/cron",
"examples/catch-panic",
"examples/graceful-shutdown",
"examples/unmonitored-worker",
"examples/fn-args",
"examples/persisted-cron",
"examples/rest-api",
]
[dependencies]
tower = { version = "0.5", features = ["util"], default-features = false }
tracing-futures = { version = "0.2.5", optional = true, default-features = false }
sentry-core = { version = "0.36.0", optional = true, default-features = false }
metrics = { version = "0.24.0", optional = true, default-features = false }
metrics-exporter-prometheus = { version = "0.16", optional = true, default-features = false }
thiserror = "2.0.0"
futures = "0.3.30"
pin-project-lite = "0.2.14"
# Needed only for sentry reporting
uuid = { version = "1.8", optional = true }
ulid = { version = "1", optional = true }
serde = { version = "1.0", features = ["derive"] }
[dependencies.tracing]
default-features = false
version = "0.1.40"
optional = true