1 package FS::ClientAPI_SessionCache;
5 use FS::UID qw(datasrc);
7 #ask FS::UID to run this stuff for us later
8 install_callback FS::UID sub {
9 my $conf = new FS::Conf;
10 $module = $conf->config('selfservice_server-cache_module')
11 || 'Cache::FileCache';
16 FS::ClientAPI_SessionCache;
22 Minimal Cache::Cache-alike interface for storing session cache information.
23 Backends to Cache::SharedMemoryCache, Cache::FileCache, or an internal
24 implementation which stores information in the clientapi_session and
25 clientapi_session_field database tables.
37 my $class = ref($proto) || $proto;
38 unless ( $module =~ /^_Database$/ ) {
41 my $self = $module->new(@_);
42 $self->set_cache_root('%%%FREESIDE_CACHE%%%/clientapi_session.'.datasrc)
43 if $module =~ /^Cache::FileCache$/;
47 bless ($self, $class);
52 my($self, $session_id) = @_;
53 die '_Database self-service session cache not yet implemented';
57 my($self, $session_id, $session, $expiration) = @_;
58 die '_Database self-service session cache not yet implemented';
62 my($self, $session_id) = @_;
63 die '_Database self-service session cache not yet implemented';
70 Minimal documentation.
74 L<Cache::Cache>, L<FS::clientapi_session>, L<FS::clientapi_session_field>