NAME
Egg::Plugin::SessionKit::DBI - Egg::Model::DBI for session.
SYNOPSIS
use Egg qw/ SessionKit DBIC::Transaction /;
__PACKAGE__->mk_eggstartup(
.......
...
MODEL => [ [ DBIC => {} ] ],
plugin_session => {
base => {
name => 'DBIC',
schema_name => 'MySchema',
source_name => 'Sessions',
data_field => 'a_session',
time_field => 'lastmod',
},
.......
...
},
);
DESCRIPTION
The session by Egg::Model::DBIC is supported.
It is necessary to load Egg::Plugin::DBIC::Transaction.
Please make the table for the following sessions for the data base used.
CREATE TABLE sessions (
id char(32) primary key,
lastmod timestamp,
a_session text
);
* It is not forgotten to set an appropriate authority.
And, the helper of Egg::Model::DBIC is executed and Schema is made.
* Please set Egg::Plugin::SessionKit::Store::Base64 to the Store module.
* The function to clear the data not used is not included. Separately, it is necessary to delete it with cron etc. regularly.
CONFIGRATION
schema_name
Name of Schema used.
There is no default. Please set it.
source_name
Name of table module for session.
There is no default. Please set it.
data_field
Name of column that stores session data.
Default is 'a_session'.
time_field
Name of column that stores updated day and hour.
Default is 'lastmod'.
METHODS
startup
The setting is checked.
restore ( [SESSION_ID] )
The session data is acquired.
insert
New session data is added.
update
Existing session data is updated.
commit_ok
Accessor to $e->[SCHEMA_NAME]_commit_ok.
close
Rollback is set if there are signs where some errors occurred before shutting the session.
SEE ALSO
Egg::Model::DBIC, Egg::Plugin::SessionKit, Egg::Release,
AUTHOR
Masatoshi Mizuno <lushe@cpan.org>
COPYRIGHT
Copyright (C) 2007 by Bee Flag, Corp. <http://egg.bomcity.com/>, All Rights Reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.6 or, at your option, any later version of Perl 5 you may have available.