I'm trying to use the Redis backend for idempotency in Powertools but I'm hitting a few questions the docs don't cleanly cover:
- Cluster mode — does the persistence layer support Redis Cluster, or only standalone? What's the right way to pass cluster-aware connection settings?
- Connection options — should I be passing a URL string (
redis://...) or constructor arguments (host/port/username/password/db_index/ssl)? Do both work, and is one preferred?
- Working example — a minimal end-to-end example with the
@idempotent decorator pointing at a Redis layer would help — even just the imports + the decorator + the persistence layer instantiation.
Looking at the source it seems like there are multiple persistence-layer classes; I want to make sure I pick the right one for new code, not the deprecated path.
I'm trying to use the Redis backend for idempotency in Powertools but I'm hitting a few questions the docs don't cleanly cover:
redis://...) or constructor arguments (host/port/username/password/db_index/ssl)? Do both work, and is one preferred?@idempotentdecorator pointing at a Redis layer would help — even just the imports + the decorator + the persistence layer instantiation.Looking at the source it seems like there are multiple persistence-layer classes; I want to make sure I pick the right one for new code, not the deprecated path.