Re: DBI Connectons accumulate under Mod_perl

"David E. Wheeler" <[email protected]>
Newsgroups gmane.comp.apache.mod-perl
Message-ID <[email protected]>
On Nov 16, 2009, at 1:10 AM, Artem Kuchin wrote:

> I am the original poster. Someone else has stolen my thread.
> Anyway.
> I AM calling disconnect  and the thing is wrapped in
> sub handler {
>   my $db=...
> 
>   ...
> 
>   $db->disconnect();
> }
> 
> So, everything goes out of scope when handler finishes. I made it so to play nice with mod_per. NO globals
> at all.
> 
> The apache run two site with such code. One site does not have a problem another builds up the connection.
> It might be related to windows (it is all under windows and i never had such problem under freebsd).

Maybe you have a system call or some other forking call that can lead to stray handles? Some Perl modules will do it without you knowing. I suggest switching to DBIx::Connector, which detects such things, to see if it helps.

Best,

David
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.