Module to store session on a redis
Project description
Odoo Session inside Redis
Use redis to store odoo cookie session.
Inspired by :
https://github.com/odoo/odoo-extra/commit/99265410bf396fc476c0a4502a44549a1dd29ef2
This gist https://gist.github.com/carlopires/1451947
This module https://github.com/Smile-SA/odoo_addons/commit/d90e23f6fbc078beb0cb14080a2b18de332200ef
And this module https://github.com/camptocamp/odoo-cloud-platform/tree/16.0/session_redis
Install
pip install mangono-odoo-redis-session
Config
Configuration is done through environment variables. Alternatively, you can use a config parameter under [redis_sessions_store]. Environment variable have higher priority than config parameter.
ENV_VARIABLE_NAME = default | config_parameter
Redis connection
REDIS_HOST = None | host – Redis host.
REDIS_PORT = None | port – Redis host port.
REDIS_PREFIX = None | prefix – Prefix for Redis keys.
REDIS_URL = None | url – Alternative connection through url.
REDIS_PASSWORD = None | password – Redis password.
Session TTL parameters
ODOO_SESSION_REDIS_EXPIRATION = 259200 | expiration – Logged session TTL in seconds.
ODOO_SESSION_REDIS_EXPIRATION_ANONYMOUS = 120 | anon_expiration – Anonymous session TTL in seconds.
ODOO_SESSION_REDIS_TIMEOUT_ON_INACTIVITY = "True" | timeout_on_inactivity – "true" | "1" | "t" will evaluate to True (case-insensitive), all other values will evaluate to False – Whether user activity should reset session TTL or not. If false, session will have a fixed expiration set on creation.
ODOO_SESSION_REDIS_TIMEOUT_IGNORED_URLS = "/longpolling,/calendar/notify" | ignored_urls – Comma separated list of string matching starts of endpoints that won't update session TTL on access. Has no effect when in fixed TTL mode. Note that the default value is not overridable and will always be added.
Known issues
On fixed expiry time , refreshing the page still refresh TTL.
See doc in https://atlas.docs.mangono.io/redis-session
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mangono_odoo_redis_session-1.4.0.tar.gz.
File metadata
- Download URL: mangono_odoo_redis_session-1.4.0.tar.gz
- Upload date:
- Size: 95.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a93559256d9d9e47fe466afda2e33f4759dd1557d9b95e8ede1b198d3af0a6de
|
|
| MD5 |
3afa91b1425e420402304e28a1c07a7b
|
|
| BLAKE2b-256 |
05d738955cf151b6cf9e5664d8d05fd4eae5617379a2a7829851a8db6b58f266
|
File details
Details for the file mangono_odoo_redis_session-1.4.0-py3-none-any.whl.
File metadata
- Download URL: mangono_odoo_redis_session-1.4.0-py3-none-any.whl
- Upload date:
- Size: 7.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
008fc6ba03a1c18c560990f0545cbc3b24e180028b9d8becc2d0f7953e896e5a
|
|
| MD5 |
9e6d5cb42eb1a4dad6f70431ab8d1f48
|
|
| BLAKE2b-256 |
936ef9a4426823c0c52ff025021d9b32de3dd83871aafd93f5121adba6826609
|