logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

Apache::Session::SQLite3 - Use DBD::SQLite 1.x for Apache::Session storage

Author

       Autrijus Tang <autrijus@autrijus.org>

Description

       This module is an implementation of Apache::Session.  It uses the DBD::SQLite backing store.  It requires
       DBD::SQLite version 1.00 or above, due to its use of SQLite3 API for BLOB support.  Also, an extra
       "LastUpdated" field is populated with the current "time()".

       There is no need to create the data source file beforehand; this module creates the "session" table
       automatically.

Name

       Apache::Session::SQLite3 - Use DBD::SQLite 1.x for Apache::Session storage

See Also

       Apache::Session, Apache::Session::SQLite, DBD::SQLite

perl v5.34.0                                       2022-06-06                      Apache::Session::SQLite3(3pm)

Synopsis

           use Apache::Session::SQLite3;

           tie %hash, 'Apache::Session::SQLite3', $id, {
               DataSource => 'dbi:SQLite:dbname=/tmp/session.db'
           };

           # to purge all sessions older than 30 days, do this:
           tied(%hash)->{object_store}{dbh}->do(qq[
               DELETE FROM Sessions WHERE ? > LastUpdated
           ], {}, time - (30 * 86400));

Version

       This document describes version 0.03 of Apache::Session::SQLite3, released February 2, 2005.

See Also