Re: [mp2] Runtime PerlResponseHandler

2005-07-22 Thread Tim Esselens
Philippe M. Chiasson wrote: >> Is PerlInitHandler a hook too early for adding PerlResponseHandlers? > Not too early, but the mapping / => index.phtml is done by mod_autoindex > at a later phase, so when your InitHandler _could_ kick in, the request > still has $r->filename point to the directory

Re: [mp2.0.1] [bug] [porting.pm]

2005-07-22 Thread Philippe M. Chiasson
Bengt-Arne Fjellner wrote: > porting.pm does not work without Apache2::compat Thanks, applied as r224421 Philippe M. Chiasson m/gozer\@(apache|cpan|ectoplasm)\.org/ GPG KeyID : 88C3A5A5 http://gozer.ectoplasm.org/

[mp2.0.1] [bug] [Makefile.PL]

2005-07-22 Thread Bengt-Arne Fjellner
Background my apche is not installes exactly as standard. perl Makefile.Pl ends with: [warning] mod_perl dso library will be built as mod_perl.so [warning] You'll need to add the following to httpd.conf: [warning] baf LoadModule perl_module modules/mod_perl.so but: [EMAIL PROTECTED] ~/mod_perl-

[Patch WIN32 apxs]

2005-07-22 Thread William A. Rowe, Jr.
For users of Randy's apxs win32 (v 0.2) here's my gross hack to get it working again for 2.1-dev, 2.2. The binary has changed from apache.exe to httpd.exe, causing some pain. However, it's specific, I started generic but ran out of time (libapr-1.dll for example.) Sorry for the crosspost, expect

Re: [mp2] Runtime PerlResponseHandler

2005-07-22 Thread Philippe M. Chiasson
Tim Esselens wrote: > Hi, > > I'm having problems with the following construct: > > -[httpd.conf] > > PerlInitHandler Dispatcher > > > -[Dispatcher.pm]- > sub handler() { > # do some stuff to get $module >

Re: [mp2] Runtime PerlResponseHandler

2005-07-22 Thread Tim Esselens
Geoffrey Young wrote: >> $r->push_handlers(PerlResponseHandler => $module); > you also need $r->handler('modperl') here, as apache needs to know which > content handler to dispatch to. I've added this before and after push_handlers, also tried $r->handler('perl-script') but none of them

[mp2.0.1] [bug] [porting.pm]

2005-07-22 Thread Bengt-Arne Fjellner
porting.pm does not work without Apache2::compat see patch: [EMAIL PROTECTED] /usr/lib/perl5/site_perl/5.8.5/i586-linux-thread-multi/Apache2# diff -u porting.pm.org porting.pm --- porting.pm.org 2005-07-20 03:46:56.0 +0200 +++ porting.pm 2005-07-22 23:10:57.0 +0200 @@ -38,7 +

Re: [mp2] Runtime PerlResponseHandler

2005-07-22 Thread Geoffrey Young
> $r->push_handlers(PerlResponseHandler => $module); you also need $r->handler('modperl') here, as apache needs to know which content handler to dispatch to. HTH --Geoff

[mp2] Runtime PerlResponseHandler

2005-07-22 Thread Tim Esselens
Hi, I'm having problems with the following construct: -[httpd.conf] PerlInitHandler Dispatcher -[Dispatcher.pm]- sub handler() { # do some stuff to get $module $r->push_handlers(PerlResponseHandler => $

Re: [mp2] PerlAuthenHandler ->Internal_Redict question

2005-07-22 Thread Bengt-Arne Fjellner
Geoffrey Young wrote: > > > Bengt-Arne Fjellner wrote: >> Hi. Im working on a modperl login module that amongst others will check for >> https >> If not https I want to give an error page instead. > > you'll need something like Apache::SSLLookup to determine https during the > authen phase. Than

Re: Why mod_perl?

2005-07-22 Thread Perrin Harkins
On Fri, 2005-07-22 at 14:53 +0100, Shane De Jager wrote: > I am trying to speed up my CGI scripts on Apache Server 2. Can you > tell me some reasons why u chose mod_perl instead of fastCGI? There are two main reasons to choose mod_perl, in my opinion: - Access to Apache internals, giving you the s

Re: Request-local storage?

2005-07-22 Thread Simon Perreault
On Friday 22 July 2005 11:08, Joe Cullin wrote: > 1. Use $ENV{'UNIQUE_ID'} (set my mod_unique_id?) > This seems to be a different value for every request. So I can create 2 > global variables, $lastId and %savedData. If $lastId != $ENV{'UNIQUE_ID'} > then I know I'm in a new request and I can wi

Two Server Setup Strategy Question

2005-07-22 Thread Jonathan Vanasco
I'd like to use the 2+ server setup strategy: Vanilla Apache bound to port 80 proxypass to mod_perl server on different ports I got that running on Linux using 2 sourcetrees as in the modperlbook I just got a new server with FreeBSD 5.4-RELEASE on it, and am new to all the port

Re: Request-local storage?

2005-07-22 Thread Stas Bekman
Simon Perreault wrote: On Friday 22 July 2005 11:00, Stas Bekman wrote: But you need this functionality only under mod_perl, right? Well, not really. I would still need to cache stuff during the request when running under mod_cgi but then the cache would be automatically reset at the end o

[RELEASE CANDIDATE] Apache-Test 1.26

2005-07-22 Thread Geoffrey Young
we are pleased to announce a new release candidate for the Apache-Test distribution. http://people.apache.org/~geoff/Apache-Test-1.26-dev.tar.gz recently it was discovered that Apache-Test didn't play nice with boxes that had both mp1 and mp2 installed. if you're running mod_perl and can't do

Re: Request-local storage?

2005-07-22 Thread Simon Perreault
On Friday 22 July 2005 11:00, Stas Bekman wrote: > But you need this functionality only under mod_perl, right? Well, not really. I would still need to cache stuff during the request when running under mod_cgi but then the cache would be automatically reset at the end of each script. Nothing spec

Re: Request-local storage?

2005-07-22 Thread Joe Cullin
We're in a similar situation. I've found two ways of doing this. 1. Use $ENV{'UNIQUE_ID'} (set my mod_unique_id?) This seems to be a different value for every request. So I can create 2 global variables, $lastId and %savedData. If $lastId != $ENV{'UNIQUE_ID'} then I know I'm in a new request a

Re: Request-local storage?

2005-07-22 Thread Stas Bekman
Simon Perreault wrote: On Friday 22 July 2005 10:27, Stas Bekman wrote: $r->notes for strings $r->pnotes for perl scalars Thank you very much for your quick reply. I didn't know about those methods. I should have mentioned that I am running under ModPerl::Registry and am trying to keep my

Re: Modification of read only value attempted

2005-07-22 Thread Malte Ubl
Stas Bekman wrote: Could this error occur if the close or unlock a type glob that does not have a file handle in it? May be. It's hard to tell w/o being able to reproduce the problem. Another thing to try is to change the perl source code to dump the sv: sv_dump(sv); in the place it logs

Re: Request-local storage?

2005-07-22 Thread Simon Perreault
On Friday 22 July 2005 10:27, Stas Bekman wrote: > $r->notes for strings > $r->pnotes for perl scalars Thank you very much for your quick reply. I didn't know about those methods. I should have mentioned that I am running under ModPerl::Registry and am trying to keep my scripts free from any mod

Re: Request-local storage?

2005-07-22 Thread Stas Bekman
Simon Perreault wrote: Hi, Is there a good way to have request-local storage? For example, I want to cache stuff (file reading primarily) for the length of a given request, and have that cache be local to the request (ie. other concurrent requests have separate caches). How would you do that?

Request-local storage?

2005-07-22 Thread Simon Perreault
Hi, Is there a good way to have request-local storage? For example, I want to cache stuff (file reading primarily) for the length of a given request, and have that cache be local to the request (ie. other concurrent requests have separate caches). How would you do that? It should not matter wet

Re: set the UIDs and GIDs in Mod_Perl 2

2005-07-22 Thread Stas Bekman
Shane De Jager wrote: Hi In O'Reilly Practical mod_perl Appendix C Under C.1. Users Sharing a Single Web Server it states: mod_perl 2.0 improves the situation, since it allows a pool of Perl interpreters to be dedicated to a single virtual host. It is possible to set the UIDs and GIDs of these

RE: set the UIDs and GIDs in Mod_Perl 2

2005-07-22 Thread Shane De Jager
Hi In O'Reilly Practical mod_perl Appendix C Under C.1. Users Sharing a Single Web Server it states: mod_perl 2.0 improves the situation, since it allows a pool of Perl interpreters to be dedicated to a single virtual host. It is possible to set the UIDs and GIDs of these interpreters to be th

Why mod_perl?

2005-07-22 Thread Shane De Jager
Hi I am trying to speed up my CGI scripts on Apache Server 2. Can you tell me some reasons why u chose mod_perl instead of fastCGI? -- Shane De Jager Technical Developer INTERGAGE High-performance, updateable Web sites Switchboard +44(0)845 456 1022 Direct Dial +44(0)1202 688 219 ==

Re: set the UIDs and GIDs in Mod_Perl 2

2005-07-22 Thread Stas Bekman
Shane De Jager wrote: Hi I am in the process of moving to mod perl from CGI. Under modCGI i could set UIDs and GID with suExec. Is this possible with mod_perl2? If so, how is it done? Not at the moment, Shane. http://perl.apache.org/docs/1.0/guide/install.html#Is_it_possible_to_run_mod_perl_

set the UIDs and GIDs in Mod_Perl 2

2005-07-22 Thread Shane De Jager
Hi I am in the process of moving to mod perl from CGI. Under modCGI i could set UIDs and GID with suExec. Is this possible with mod_perl2? If so, how is it done? -- Shane De Jager Technical Developer INTERGAGE High-performance, updateable Web sites Switchboard +44(0)845 456 1022 Direct Dia