Suggestion on perl handler to reject request with large content length

2010-11-18 Thread Mohit Anchlia
I have been searching for an answer in httpd forum. But I think I need to ask here: I have a requirement to look at content length and if it is greatar than desired size then return error message. So psuedo code is like: if content_length > 32G then if url contains /abc/ then echo "0|ab

Re: Suggestion on perl handler to reject request with large content length

2010-11-19 Thread Mohit Anchlia
On Fri, Nov 19, 2010 at 9:59 AM, Mohit Anchlia wrote: > On Thu, Nov 18, 2010 at 6:26 PM, Mark J. Reed wrote: >> On Thu, Nov 18, 2010 at 8:47 PM, Mohit Anchlia >> wrote: >>> I have a requirement to look at content length and if it is greatar >>> than desired s

Mod-jk worker not being called after calling Perl handler

2010-11-19 Thread Mohit Anchlia
I am trying to look at how handlers work so I created a very simple perl handler that just return "OK". And I added an entry "PerlModule" and the "PerlHandler". I also was able to build mod_perl2.so. When I do a GET request with handler ON I see that Handler gets called but then the call is not goi

Re: Mod-jk worker not being called after calling Perl handler

2010-11-22 Thread Mohit Anchlia
ending request to mod-jk. On Sat, Nov 20, 2010 at 7:14 AM, Ryan Gies wrote: > Have you tried returning Apache2::Const::DECLINED instead? > http://perl.apache.org/docs/2.0/user/handlers/intro.html#Handler_Return_Values > > On 11/20/2010 12:09 AM, Mohit Anchlia wrote: >> >> I

Re: Mod-jk worker not being called after calling Perl handler

2010-11-23 Thread Mohit Anchlia
;content_type('text/plain'); #$r->print('Rules'); return OK; # We must return a status to mod_perl } 1; # This is a perl module so we must return true to perl On Tue, Nov 23, 2010 at 4:17 PM, Mohit Anchlia wrote: > On Tue, Nov 23, 2010 at 9:57 AM, Mohit Anchlia wrote: &g

Building and installing mod_perl as a complete package

2010-11-23 Thread Mohit Anchlia
I was able to build mod_perl.so . But I noticed that "make install" copies whole bunch of perl modules under non-apache directories. My question, 1. Is it possible to build it such that I don't have to run make install on every web server? Is there a way to build mod_perl that contains everythin

Apache2::RequestIO sendfile

2010-11-24 Thread Mohit Anchlia
If I use $r->sendfile($filenam) and the file is always the same then does mod_perl open and read this file on every execution or is it cached? I am wondering if it will be better to copy the contents of file (500bytes) in the perl module instead. Is there a overhead or chances of running out of fi

Re: Building and installing mod_perl as a complete package

2010-12-20 Thread Mohit Anchlia
sch : > On Tuesday, December 14, 2010 23:17:10 Mohit Anchlia wrote: >> Thanks! So for eg: DESTDIR needs to be given in make install or with >> make perl Makefile.PL? > > the former > > Torsten Förtsch > > -- > Need professional modperl support? Hire me! (http: