Home | Wiki | OI 1.x Docs | OI 2.x Docs |
OpenInteract2::Cache::File -- Implement caching in the filesystem
Subclass of OpenInteract2::Cache that uses the filesystem to cache objects.
initialize( \%config )
Creates a new Cache::FileCache object for later
use, initializing it with the values from \%config
-- this
corresponds to the data under cache_info.data
in your server
configuration. Here's what you can set:
directory (required)
Root directory of cache. Must be writable by the user who owns the server process.
max_size (optional)
Max size of the cache, in bytes. (Default: 2000000 about 10MB)
default_expire (optional)
Number of seconds the cached item should be valid. (Default: 86400, or one day)
directory_depth (optional)
If you cache a lot of content set this to '2' or '3' so the cache doesn't create too many files in a single directory, which can foul up some filesystems.
Copyright (c) 2001-2003 Chris Winters. 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>
Generated from the OpenInteract 1.99_03 source.