Re: code in <perl> sections executed twice in same process?

E R <[email protected]>
Newsgroups gmane.comp.apache.mod-perl
Message-ID <[email protected]>
The <perl> sections don't seem to be executed in the children.

Is there a way to determine which pass you are in?

For large mod_perl apps, is there a way to avoid loading your code in twice?

Note I am using mod_perl 1.3.41.

Thanks,
ER

On Mon, Nov 16, 2009 at 4:41 PM, André Warnier <[email protected]> wrote:
> E R wrote:
> ...
>>
>> Is this "normal", and what can I do so that the code in <Perl>
>> sections is only executed once in the parent process?
>>
> I believe it is "normal", in the sense that Apache actually parses its
> configuration at least twice : one time "just for checking", then it throws
> everything away and parses it a second time "for real".
>
> Then it will even (probably) run your section again, each time it starts a
> new child process.
>
> You probably really want to read the following 2 pages :
> http://perl.apache.org/docs/2.0/user/handlers/server.html
> http://perl.apache.org/docs/2.0/user/config/custom.html
>
>
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.