in reply to Looking for a way to use one database connection with multiple CGI scripts
An alternative to mod_perl et al is SpeedyCGI. You still fork one process per CGI request, but the actual script gets stuffed into a background daemon for a given time or number of invocations. The connection set-up would go into the global variables space of the script == backend. The first caller would initialize it, subsequent calls re-use until the backend terminates (and takes any memory leak with it).
Re^2: Looking for a way to use one database connection with multiple CGI scripts
by vendion (Scribe) on Nov 24, 2009 at 22:03 UTC
|
Sorry to everyone for the confusing post. I have two files on my server which each makes their own connection to my MySQL server. I have never done something to this scale before and so I don't know what would be the best approach to handling database connections like this. As for what I am using I think my server is using mod_perl because I don't have FastCGI installed.
| [reply] |
|