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
This backend uses [pickle](https://docs.python.org/3/library/pickle.html) module to serialize
138
-
values, but the cashes can store values with sha1-keyed hash.
139
+
values, but the cashes can store values with md5-keyed hash.
139
140
140
141
Use `secret` and `digestmod` parameters to protect your application from security vulnerabilities.
141
-
142
142
The `digestmod` is a hashing algorithm that can be used: `sum`, `md5` (default), `sha1` and `sha256`
143
-
144
143
The `secret` is a salt for a hash.
145
144
146
145
Pickle can't serialize any type of object. In case you need to store more complex types
146
+
you can use [dill](https://github.com/uqfoundation/dill) - set `pickle_type="dill"`. Dill is great, but less performance.
147
147
148
-
you can use [dill](https://github.com/uqfoundation/dill) - set `pickle_type="dill"`.
149
-
Dill is great, but less performance.
150
148
If you need complex serializer for [sqlalchemy](https://docs.sqlalchemy.org/en/14/core/serializer.html) objects you can set `pickle_type="sqlalchemy"`
151
149
Use `json` also an option to serialize/deserialize an object, but it very limited (`pickle_type="json"`)
152
150
153
151
Any connection errors are suppressed, to disable it use `suppress=False` - a `CacheBackendInteractionError` will be raised
154
152
155
-
If you would like to use [client-side cache](https://redis.io/topics/client-side-caching) set `client_side=True`
153
+
For some data, it may be useful to use compression. Gzip and zlib compression are available;
154
+
you can use the `compress_type` parameter to configure it.
156
155
157
-
Client side cache will add `cashews:` prefix for each key, to customize it use `client_side_prefix` option.
156
+
If you would like to use [client-side cache](https://redis.io/topics/client-side-caching) set `client_side=True`. Client side cache will add `cashews:` prefix for each key, to customize it use `client_side_prefix` option.
For using secure connections to redis (over ssl) uri should have `rediss` as schema
@@ -177,10 +176,12 @@ This will use local sqlite databases (with shards) as storage.
177
176
It is a good choice if you don't want to use redis, but you need a shared storage, or your cache takes a lot of local memory.
178
177
Also, it is a good choice for client side local storage.
179
178
180
-
You can setup disk cache with [FanoutCache parameters](http://www.grantjenks.com/docs/diskcache/api.html#fanoutcache)
179
+
You can setup disk cache with [Cache parameters](https://grantjenks.com/docs/diskcache/api.html#diskcache.diskcache.DEFAULT_SETTINGS)
181
180
182
181
** Warning **`cache.scan` and `cache.get_match` does not work with this storage (works only if shards are disabled)
183
182
183
+
** Warning ** Be careful with the [default settings](https://grantjenks.com/docs/diskcache/api.html#diskcache.diskcache.DEFAULT_SETTINGS) as they contain parameters such as `size_limit`
0 commit comments