[Catalyst] Plugin::Session lazy start
des at des.no
Wed May 23 08:58:42 GMT 2012
I have an application that uses sessions with a FastMmap store. This
application also includes a custom script (using Catalyst::ScriptRole)
used to perform certain administrative tasks from the command line.
The problem is that Catalyst tries to unlink and recreate the session
cache every time it starts (somewhere in the bowels of MyApp->setup(), I
imagine). This is obviously a bad idea if the application is running,
but it is a problem even if the application isn't running if the session
cache is owned by a different user (e.g. www) than the one that runs the
script (e.g. des).
Is there a way to have C::Plugin::Session (or C::P::S::Store::FastMmap)
initialize the cache on first use instead of at startup?
As an alternate solution, is there a way to have it use a different file
name every time it starts?
Dag-Erling Smørgrav - des at des.no
More information about the Catalyst