Getting Started
Installation
Add Trypema with the right feature set for local-only, Redis, or hybrid usage.
Choose the dependency shape you need
Local only
[dependencies]
trypema = "1"
This compiles the local provider only.
Redis or Hybrid with Tokio
[dependencies]
trypema = { version = "1", features = ["redis-tokio"] }
redis = { version = "1", features = ["aio", "tokio-comp", "connection-manager"] }
tokio = { version = "1", features = ["full"] }
Redis or Hybrid with Smol
[dependencies]
trypema = { version = "1", features = ["redis-smol"] }
redis = { version = "1", features = ["aio", "smol-comp", "connection-manager"] }
smol = "2"
Requirements
| Requirement | Version |
|---|---|
| Rust edition | 2024 |
| Redis | 7.2+ |
| Tokio | 1.x when using redis-tokio |
| Smol | 2.x when using redis-smol |
Feature rules
redis-tokioandredis-smolare mutually exclusive.- Redis and hybrid usage require a Redis
connection_manager. - Local-only builds have no Redis dependency at all.
Quick verification
cargo check
If you enabled a Redis feature, point tests at a live Redis instance:
REDIS_URL=redis://127.0.0.1:6379/ cargo test --features redis-tokio

