OpenInteract::Session::DBI - Create sessions within a DBI data source
# In your configuration file [session_info] class = Apache::Session::MySQL ... [system_alias] session = OpenInteract::Session::DBI # Use a different datasource [db_info session_storage] db_owner = username = webuser password = s3kr1t dsn = dbname=sessions db_name = driver_name = Pg sql_install = long_read_len = 65536 long_trunc_ok = 0 [session_info] class = Apache::Session::Postgres datasource = session_storage ... [system_alias] session = OpenInteract::Session::DBI
Provide a '_create_session' method for OpenInteract::Session so we can use a DBI data source as a backend for Apache::Session.
Note that failure to create the session throws a '310' error, which clears out the session cookie so it does not keep happening. (See OpenInteract::Error::System for the code.)
Note that former users of OpenInteract::Session::MySQL (now defunct) should have no problems using this class -- just specify the 'session_class' as Apache::Session::MySQL and everything should work smoothly.
OpenInteract::Session::MySQL
If you want to use SQLite as a backend, see OpenInteract::Session::SQLite.
_create_session( $session_id )
Overrides the method from parent OpenInteract::Session to take a session ID and retrieve a session from the datastore. We use the following configuration information:
session_info.class ($)
Specify the session serialization implementation class -- e.g., Apache::Session::MySQL, Apache::Session::Postgres, etc.
session_info.datasource ($) (optional)
Use a datasource different from that specified in 'datasource.default_connection_db'.
session_info.params (\%) (optional)
Parameters that get passed directly to the session serialization implementation class. These depend on the implementation.
None known.
Nothing.
Apache::Session
OpenInteract::Session
Copyright (c) 2001-2002 intes.net, inc.. All rights reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Chris Winters <chris@cwinters.com>
To install OpenInteract, copy and paste the appropriate command in to your terminal.
cpanm
cpanm OpenInteract
CPAN shell
perl -MCPAN -e shell install OpenInteract
For more information on module installation, please visit the detailed CPAN module installation guide.