|No such thing as a small change|
framework to handle timeouts/internal caching?by infidel2112 (Acolyte)
|on Oct 04, 2004 at 20:19 UTC||Need Help??|
Hi...I have a related question...
I deal with many cgi scripts that must perform time consuming processes, I'm looking for a framework or module that handle cleanly what I'm cobbling together manually.
To prevent timeouts, currently I write a CGI::Session id, fork a child, send the browser a session cookie and page with a meta refresh on it. The browser refreshes, sending the id, until the child query is done.
Second I also use Memoize to store responses to certain time consuming sql queries, and a few subroutine calls.
I can only cache for about an hour to keep things fresh however. So I have to do a fair amount of work to accomplish that (normalize functions, and deleting stale data), I also had to modify the source to use the locking version of storable calls so multiple processes can use the cache file.
Third I make extensive use of expires and cache-control headers etc, but often requests are different enough that the script still has to be hit.
Basically I just want to have a framework that handles the above, without having to roll so much of my own.
any suggestions? thanks