#Introduction
Products.BeakerZopeSessionManager is a replacement for the default Zope 4
session implementation. It uses Beaker as a backend (via collective.beaker)
and adapts the Beaker session to provide the same interface as a normal Zope
session.
Beaker is a better alternative to the default session implementation for several reasons:
- The Zope session implementation does not perform well in high-write scenarios.
- Beaker provides better flexibility in where session data is actually stored.
- Beaker is used and maintained outside of the Zope ecosystem.
.. Note:: If you are developing a product that needs sessions but are not already using Zope sessions, you should probably just use collective.beaker directly. This product is meant for use with existing add-ons that already use Zope sessions (i.e. request.SESSION).
#Installation
Include the line <include package="collective.beaker" /> in yout site.zcml
Edit the file lib/python3.7/site-packages/Zope2/Startup/serve.py inside your virtual env.
Replace (line 200):
try:
serve(app)`
except (SystemExit, KeyboardInterrupt) as e:
with:
try:
from beaker.middleware import SessionMiddleware
config = {
'session.type': 'file',
'session.auto': True,
'session.save_accessed_time': True,
'session.data_dir': '/tmp/sessions/data',
'session.lock_dir': '/tmp/sessions/lock',
'session.timeout': 28800
}
server(SessionMiddleware(app, config))
except (SystemExit, KeyboardInterrupt) as e:
For more info on how to configure your Beaker, please refer to Beaker documentation.
#Notes
- Beaker does not automatically clean up old sessions, so you may want to set up a cron job to take care of this.
#Contributors
- Gabriel Gisoldo [gabrielgisoldo]
.. include:: CHANGES.rst
Metadata
Release files for Products.BeakerZopeSessionManager 1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| Products.BeakerZopeSessionManager-1.0.tar.gz | 6.0 kB | Without provenance | Details for Products.BeakerZopeSessionManager-1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| Products.BeakerZopeSessionManager-1.0-py3-none-any.whl | Python 3 | none | any | Details for Products.BeakerZopeSessionManager-1.0-py3-none-any.whl |
Total release size: 15.2 kB
Release files / Products.BeakerZopeSessionManager-1.0.tar.gz
| Download URL | Products.BeakerZopeSessionManager-1.0.tar.gz |
|---|---|
| Size | 6.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4064294721f44c3f8d759cfabd3cc82d5e0c1bd8ad6ea77c3c8af1182377658a
|
|
BLAKE2b-256 checksum How to use checksums |
9595887e353d79de055becb85d38f64d45df3aba0eb31276be15cc586b40b894
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.7.2
|
Release files / Products.BeakerZopeSessionManager-1.0-py3-none-any.whl
| Download URL | Products.BeakerZopeSessionManager-1.0-py3-none-any.whl |
|---|---|
| Size | 9.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
90d60e883545096874add13bc1f839d7c2ee5d7c8eee8f2dfc5b295e58cc7e75
|
|
BLAKE2b-256 checksum How to use checksums |
d0bdaefe8b3ec5d1656369dbf08b151ab8389981d8e0d8d856d5fbcd989d2db8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.7.2
|
Security for Products.BeakerZopeSessionManager 1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.