You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Geoffrey Young <ge...@modperlcookbook.org> on 2002/11/14 21:18:50 UTC
Re: odd headers with Apache::add_version_component()
Josh Chamas wrote:
> Hey,
>
> I'm looking to get Apache::ASP to insert itself into the module
> Server tokens with the add_version_component() API, so I call
> it like this:
>
> package Apache::ASP
> ...
> &Apache::add_version_component("Apache::ASP/$VERSION");
> ...
> 1;
>
> but then it becomes the first header on the list!, and I do
> not want it to look like it is the actual web server itself...
from what I remember, this method is very strange - it depends lots on
how your server is set up. for instance, whether you're using DSO
(which breaks down the interpreter on restarts) and/or whether you
have PerlFreshRestart On. both of these behaviors seem to affect the
order of the tokens.
the reason I know this is a few private emails between doug and I
after this:
http://marc.theaimsgroup.com/?l=apache-modperl-cvs&m=99453039711626&w=2
the box I wrote the book on worked just fine, placing the token at the
end like we illustrate. that one happened to be static without
PerlFreshRestart on linux. go figure.
>
> Server: Apache::ASP/2.49 Apache/1.3.27 (Unix) PHP/4.2.3 mod_perl/1.27
> Perl/v5.8.0 mod_ssl/2.8.11 OpenSSL/0.9.6g
>
> So, how can I use this method correctly, so that Apache::ASP ends
> up near the end of the server tokens?
>
> BTW, I dug up this method from the mod_perl Cookbook
> very good examples, http://www.modperlcookbook.org/
thanks :)
HTH
--Geoff
Re: odd headers with Apache::add_version_component()
Posted by Geoffrey Young <ge...@modperlcookbook.org>.
>
> Even if I can get this to work through certain config tweaks,
> I will not add this to Apache::ASP as I would need this to be
> correct for all user configs, not just mine. I do not want to
> preempt the Apache/... header!
>
> Thanks for the follow up. Maybe I'll revist this in MP2.
sure.
it's really a shame about this one, since it's a nice feature. maybe
somebody will revisit it in mod_perl core one day.
you know, you make a conscious decision to write about how things are
documented/expected to behave, even when you know there are bugs, and
then...
:)
--Geoff
Re: odd headers with Apache::add_version_component()
Posted by Josh Chamas <jo...@chamas.com>.
Geoffrey Young wrote:
>
> from what I remember, this method is very strange - it depends lots on
> how your server is set up. for instance, whether you're using DSO (which
> breaks down the interpreter on restarts) and/or whether you have
> PerlFreshRestart On. both of these behaviors seem to affect the order
> of the tokens.
>
I am not using DSO, but it is enabled.
When I set PerlFreshRestart On, I do get the header in the right place,
but its also still in the wrong place!
Server: Apache::ASP/2.49 Apache/1.3.27 (Unix) PHP/4.2.3 mod_perl/1.27 Perl/v5.8.0 Apache::ASP/2.49 mod_ssl/2.8.11 OpenSSL/0.9.6g
At least we are a step closer.
Even if I can get this to work through certain config tweaks,
I will not add this to Apache::ASP as I would need this to be
correct for all user configs, not just mine. I do not want to
preempt the Apache/... header!
Thanks for the follow up. Maybe I'll revist this in MP2.
Regards,
Josh
________________________________________________________________
Josh Chamas, Founder phone:925-552-0128
Chamas Enterprises Inc. http://www.chamas.com
NodeWorks Link Checking http://www.nodeworks.com