Commit Graph

10 Commits (5217da79395a94cb35364e8a1cd85f1dddb9b450)

Author SHA1 Message Date
Christoph Fiehe 8fc534b5d6 Fixes the issue "PGSessionStore.vacuum() got an unexpected keyword argument 'max_lifetime'" when autovacuum gets executed.
Signed-off-by: Christoph Fiehe <c.fiehe@eurodata.de>
2023-08-16 11:37:23 +02:00
Stéphane Bidoul 2344802039 session_db: refactor retry handling 2023-03-27 19:04:12 +02:00
Stéphane Bidoul 13c570d639 session_db: reconnect if needed
If the connection to the database fails when
retrying a session operation, we end up
with no cursore, which makes subsequent
session operations fail.

We fix this by ensuring we have cursor
before any operations.
2023-03-27 09:58:13 +02:00
Stéphane Bidoul 2277d97458 session_db: improve cursor release 2023-02-10 19:59:59 +01:00
Stéphane Bidoul b13029ab08 session_db: cosmetics 2023-02-10 19:36:00 +01:00
Stéphane Bidoul 8023bff1b6 session_db: gevent and thread support
There were concurrency issues in evented mode.
So while I was at it, I added support for threaded mode too.
2023-02-10 19:36:00 +01:00
Stéphane Bidoul 018b664940 session_db: improve resiliency to database errors
Retry on OperationalError exception, which we receive on database restart.
Return cursor to pool when reconnecting.
2023-01-23 09:27:31 +01:00
Stéphane Bidoul 42f7db536a session_db: do not update write_date on get
The upstream FilesystemSessionStore does not do that.
2023-01-19 10:20:11 +01:00
Stéphane Bidoul b68adf53a2 session_db: use SESSION_LIFETIME constant 2023-01-19 10:20:11 +01:00
Stéphane Bidoul 6ff5bb8e03 [MIG] session_db to 16.0 2023-01-19 10:20:11 +01:00