quioteframework/session-pdo

PDO-backed session storage for Quiote: a SessionPersistenceInterface implementation for SessionManager, plus a native SessionHandlerInterface implementation for the legacy Storage subsystem.

Maintainers

Package info

github.com/quioteframework/session-pdo

Issues

pkg:composer/quioteframework/session-pdo

Transparency log

Statistics

Installs: 1

Dependents: 1

Suggesters: 1

Stars: 0

dev-main 2026-07-04 14:58 UTC

This package is auto-updated.

Last update: 2026-07-05 17:07:47 UTC


README

PDO-backed session storage for Quiote. Ships two independent implementations against Quiote's two session mechanisms:

  • Quiote\Session\Pdo\PdoSessionPersistence implements Quiote\Session\SessionPersistenceInterface (load/save/delete), the backend for Quiote\Session\SessionManager — the modern, PSR-7-based session mechanism, safe under persistent worker runtimes (FrankenPHP, RoadRunner). Prefer this for new code.
  • Quiote\Storage\Pdo\PdoSessionStorage implements PHP's native SessionHandlerInterface for the legacy Storage/SessionStorage mechanism ($_SESSION/session_start()). Kept for apps already built on that mechanism.

Install

composer require quioteframework/session-pdo

Both expect a table shaped like:

CREATE TABLE session (
    sess_id   VARCHAR(64) PRIMARY KEY,
    sess_data BYTEA/BLOB/TEXT NOT NULL,
    sess_time TIMESTAMP NOT NULL
);

PdoSessionPersistence

$manager = new \Quiote\Session\SessionManager(
    new \Quiote\Session\Pdo\PdoSessionPersistence($pdo, table: 'session'),
);

PdoSessionStorage

Configure via storage.xml/factories with the required db_table parameter (optional: database, db_id_col, db_data_col, db_time_col, data_as_lob, date_format) — see the class docblock for the full list.

License

MIT. See LICENSE.