in reply to Net::Server and DBI
I have no idea how to establish DBI connection just after fork, it seems there's no appropriate hook in Net::Server, but you can establish DBI connection in post_accept hook. This is after the client connected, but you should do it only for first client, just check if the connection already established. In order to maintain DBI connection between requests you should store DBI handler in some global variable, if you storing it in the some variable local for process_request, it's destroyed after you return from the function.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Net::Server and DBI
by alager (Acolyte) on May 20, 2009 at 18:15 UTC | |
by zwon (Abbot) on May 21, 2009 at 18:01 UTC |