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