Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

miyagawa (1653)

miyagawa
  (email not shown publicly)
http://bulknews.vox.com/
AOL IM: bulknews (Add Buddy, Send Message)

Journal of miyagawa (1653)

Monday December 24, 2001
06:46 PM

Apache::Singleton

[ #1789 ]
Recently I've worked with Singleton module for mod_perl environment.

Something which bothers me with Class::Singleton is lifetime of singleton object. We use singleton pattern for config parser object, but in mod_perl environment, object stays the same even if we change configuration file. It's messy.

So Apache::Singleton clears out singleton instance on every request using Apache pnotes API. Original idea by Matt Sergeant on mod_perl list.

Newest 0.05 can switch to default Request or Process properly according to $ENV{MOD_PERL}, so it's totally compatible with Class::Singleton.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.