Re: [Lxr-dev] DB only opened, never closed?
Brought to you by:
ajlittoz
From: Per K. G. <pe...@if...> - 2001-10-17 13:35:20
|
* Malcolm Box | Under mod_perl, do we want to do this? Because mod_perl keeps one | script going through several invocations, I think that we want to open | the db connection at initialisation and only close it when the apache | server thread dies. Thus the cost of the connection will be amortised | over several connections. | | It occurs to me that due to earlier changes this is not what currently | happens - there is one db connection per instance of $index, rather than | one for the module, but perhaps it is this that is wrong rather than | needing cleanup to close everything. I must admit that I am not 100% familiar with all the mod_perl details. What you are saying makes sense to me. If we previously created a connection to the database for each invocation we must clean up as I have implemented now. The correct solution seems to be what you are proposing. I don't know how, but there must be some way to do initialization at server thread startup. Another problem, which I do not know how to solve, is that of the libpath issue. I don't understand why the modules are not found, but I think it is a rather important problem to fix. Per Kristian Malcolm: can you fix so that messages from pk...@ne... goes through to the mailing list? |