Return-Path: Delivered-To: apmail-httpd-dev-archive@www.apache.org Received: (qmail 214 invoked from network); 11 Apr 2011 19:15:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 11 Apr 2011 19:15:22 -0000 Received: (qmail 13364 invoked by uid 500); 11 Apr 2011 19:15:22 -0000 Delivered-To: apmail-httpd-dev-archive@httpd.apache.org Received: (qmail 13309 invoked by uid 500); 11 Apr 2011 19:15:22 -0000 Mailing-List: contact dev-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list dev@httpd.apache.org Received: (qmail 13301 invoked by uid 99); 11 Apr 2011 19:15:22 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Apr 2011 19:15:22 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [188.40.99.202] (HELO eru.sfritsch.de) (188.40.99.202) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Apr 2011 19:15:14 +0000 Received: from [10.1.1.6] (helo=k.localnet) by eru.sfritsch.de with esmtp (Exim 4.69) (envelope-from ) id 1Q9MZa-0006AU-53 for dev@httpd.apache.org; Mon, 11 Apr 2011 21:14:54 +0200 From: Stefan Fritsch To: dev@httpd.apache.org Subject: Re: ap_read_config in 2.3.11 Date: Mon, 11 Apr 2011 21:14:53 +0200 User-Agent: KMail/1.13.5 (Linux/2.6.38-2-amd64; KDE/4.4.5; x86_64; ; ) References: <201104112045.55493.torsten.foertsch@gmx.net> In-Reply-To: <201104112045.55493.torsten.foertsch@gmx.net> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Message-Id: <201104112114.53451.sf@sfritsch.de> X-Virus-Checked: Checked by ClamAV on apache.org On Monday 11 April 2011, Torsten F=F6rtsch wrote: > I am working on porting modperl to the upcoming httpd 2.4. One > problem is the line >=20 > conf_vector_length =3D total_modules; >=20 > in ap_read_config (config.c:2300). >=20 > Modperl provides a way to write modules in Perl. These modules are > loaded by the directive PerlLoadModule which is executed later > than line 2300. Such modules are then appended to the module list, > get a module structure, can create config directives etc. They > also have a module index and allocate their place in config > vectors. >=20 > Now, the line above limits the config vector length to the number > of modules known before any one perl module could be loaded. >=20 > How can this situation be solved? When exactly is PerlLoadModule executed? The above code assumes that=20 modules are loaded with EXEC_ON_READ during reading of the config. I guess the optimization could be done later, after the config has=20 been parsed completely. That would waste some memory in pconf but=20 still preserve the optimization during request processing, which is=20 more important.