You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -296,6 +296,7 @@ The following wrappers are available:
296
296
297
297
| Wrapper | Description | Example |
298
298
|---------|---------------|-----|
299
+
| CollectionRoutingWrapper | Route operations to different stores based on a collection name. |`CollectionRoutingWrapper(collection_map={"sessions": redis_store, "users": dynamo_store}, default_store=memory_store)`|
299
300
| CompressionWrapper | Compress values before storing and decompress on retrieval. |`CompressionWrapper(key_value=memory_store, min_size_to_compress=0)`|
300
301
| FernetEncryptionWrapper | Encrypt values before storing and decrypt on retrieval. |`FernetEncryptionWrapper(key_value=memory_store, source_material="your-source-material", salt="your-salt")`|
301
302
| FallbackWrapper | Fallback to a secondary store when the primary store fails. |`FallbackWrapper(primary_key_value=memory_store, fallback_key_value=memory_store)`|
@@ -306,6 +307,7 @@ The following wrappers are available:
306
307
| PrefixKeysWrapper | Prefix all keys with a given prefix. |`PrefixKeysWrapper(key_value=memory_store, prefix="users")`|
307
308
| ReadOnlyWrapper | Prevent all write operations on the underlying store. |`ReadOnlyWrapper(key_value=memory_store, raise_on_write=True)`|
| RoutingWrapper | Route operations to different stores based on a routing function. |`RoutingWrapper(routing_function=lambda collection: redis_store if collection == "sessions" else dynamo_store, default_store=memory_store)`|
309
311
| SingleCollectionWrapper | Wrap a store to only use a single collection. |`SingleCollectionWrapper(key_value=memory_store, single_collection="users")`|
310
312
| TTLClampWrapper | Clamp the TTL to a given range. |`TTLClampWrapper(key_value=memory_store, min_ttl=60, max_ttl=3600)`|
311
313
| StatisticsWrapper | Track operation statistics for the store. |`StatisticsWrapper(key_value=memory_store)`|
0 commit comments