Re: file descriptor for client socket?

2007-01-18 Thread Daniel Risacher
>From within a mod_perl request handler, fileno(STDOUT) returns -1, which is >the same thing I got from $r->FILENO. Any other ideas? On Wed, 17 Jan 2007 17:26:56 -0500, Robert Landrum <[EMAIL PROTECTED]> wrote: > Daniel Risacher wrote: >> Is it possible to get the file descriptor for the clien

Re: Apache2::Request fouls up content length?

2007-01-18 Thread craig
Jonathan, thank you for your replies! The client I'm testing with is, in most contexts, not "slow". It's a dual-processor 1.25 MHz PowerMac on a DSL line, with the Safari browser which does most things faster than any other PC or Mac browser I've used. Thought I had a solution: since my two pag

Re: Two failures in make test building mod_perl 2.0.3

2007-01-18 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Jan 18, 2007 at 02:58:45PM -0500, Geoffrey Young wrote: > > > -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled) > > > # testing : connection notes > > # expected: 127.0.0.1 > > # received: 127.0.0.7 > > not ok 1 > > this looks like it may be

Re: mod_perl best practices cleanup

2007-01-18 Thread Tracy12
I introduced a use vars qw( $SESSION_CLEANUP_COUNTER); also having if not defined value =0, and $SESSION_CLEANUP_COUNTER When it reaches the threshold do the cleanup, but it always go to the undefined clause and return zero, had use vars qw been deprecated? Tracy12 wrote: > > I have a

Re: mod_perl best practices cleanup

2007-01-18 Thread Tracy12
I have a general understanding about cleanup handler But what is meant by the global timestamp and cleaning up in every 15 minutes, Programatically How can we achieve it Are u refereing to a global variable Jonathan Vanasco-3 wrote: > >>> Which part of the perl auth handler should do this

Re: Ugly build scenario...

2007-01-18 Thread Geoffrey Young
William A. Rowe, Jr. wrote: > Nevermind > > - no, it's not fun - and the project really should rethink failing >with an error or offering an override to bypass this error. > > In this case it was svn's bogus use checkout/export time and crossing > timezones > that have screwed up my datesta

Re: Ugly build scenario...

2007-01-18 Thread William A. Rowe, Jr.
Nevermind - no, it's not fun - and the project really should rethink failing with an error or offering an override to bypass this error. In this case it was svn's bogus use checkout/export time and crossing timezones that have screwed up my datestamps. For a project with extreme dedication t

Ugly build scenario...

2007-01-18 Thread William A. Rowe, Jr.
On a very fast dual cpu xeon box, configuring and then running make under linux gives me; make[1]: Warning: File `Makefile.PL' has modification time 3.7e+03 s in the future Makefile out-of-date with respect to Makefile.PL Cleaning current config before rebuilding Makefile... make -f Makefile.old

Re: mod_perl best practices cleanup

2007-01-18 Thread Rhesa
Tracy12 wrote: Looks like cron job will do, but is there any docs to write such a script. See CGI::Session::ExpireSessions (http://search.cpan.org/perldoc?CGI%3A%3ASession%3A%3AExpireSessions) for a complete solution). HTH, Rhesa

Re: mod_perl best practices cleanup

2007-01-18 Thread Tracy12
Looks like cron job will do, but is there any docs to write such a script. Meantime I found a sample as follows, as I am not having any DSN but only a folder /tmp to store session data will this work or how this can be modified #!/usr/bin/perl use constant DSN=> 'driver:file'; use co

Re: Apache2::Request fouls up content length?

2007-01-18 Thread Jonathan Vanasco
On Jan 18, 2007, at 8:14 PM, [EMAIL PROTECTED] wrote: You are correct. Turning off keepalive fixes the problem. (We're on a VPS so we have control of httpd.conf.) My residual problem is that neither KeepAlive nor MaxKeepAliveRequests is allowed in a block, so I can't just do one of them for

Re: mod_perl best practices cleanup

2007-01-18 Thread Jonathan Vanasco
Which part of the perl auth handler should do this cleanup Just to add though -- if you really want to do a cleanup within MP, use the cleanup handler which works after the client connection is terminated. also try setting a global timestamp so you only do the cleanup code once every 15 m

Re: mod_perl best practices cleanup

2007-01-18 Thread Jonathan Vanasco
On Jan 18, 2007, at 7:53 PM, Tracy12 wrote: We decided to keep the session data on LAN (file). As there will be new file created for each Session, We just wanted to know how to cleanup this folder, basically to clean all the expired sessions. Which part of the perl auth handler should do

mod_perl best practices cleanup

2007-01-18 Thread Tracy12
Hi, I could get my Perl (mod_perl) Authentication handler with the CGI:Session package, It is working fine. We decided to keep the session data on LAN (file). As there will be new file created for each Session, We just wanted to know how to cleanup this folder, basically to clean all the expir

Re: Apache2::Request fouls up content length?

2007-01-18 Thread Jonathan Vanasco
it sounds to me like a keepalive problem try KeepAlive Off if you really want it on, try MaxKeepAliveRequests 10 KeepAliveTimeout 3 but you may not be able to specify either, as its an apache config option. // Jonathan Vanasco | - - - - - - - - - - - - - - - - -

Apache2::Request fouls up content length?

2007-01-18 Thread craig
I'm still hoping for a good answer on my previous build problem. But for now I'm proceeding with testing using the mod_perl that my hosting provider set up. The first script that I've tested that uses Apache2::Request gives a problem. The browser sits and waits for its timeout period, then the c

Re: Catching errors

2007-01-18 Thread Robert Landrum
Jonathan Mangin wrote: sub handler { my $r = shift; my $req = Apache2::Request->new($r); my $foo; # eval {$foo = $req->param('foo')}; $foo = $req->param('foo'); You might want to make sure $r is really $r. If you configure apache such that you use PerlHandler Foo->handler, I be

Re: Session Handling/Set Session attributes

2007-01-18 Thread Frank Wiles
On Wed, 17 Jan 2007 16:11:17 -0800 (PST) Tracy12 <[EMAIL PROTECTED]> wrote: > > Well does this all mean there is limited features to do session > handling on mod_perl. Well I am new to mod_perl but in JAVA/Servlet > you can do a simple thing like this > > request.getSession().setAttribute("my_r

Catching errors

2007-01-18 Thread Jonathan Mangin
I'm hitting a location on my server with: http://zeppo/time?fname=Jonathan&lname=Mangin&foo=George #use APR::Const -compile => qw(:common :error); use APR::Const qw(:common :error); sub handler { my $r = shift; my $req = Apache2::Request->new($r); my $foo; # eval {$foo = $req->param(

Re: Two failures in make test building mod_perl 2.0.3

2007-01-18 Thread Geoffrey Young
> -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled) > # testing : connection notes > # expected: 127.0.0.1 > # received: 127.0.0.7 > not ok 1 this looks like it may be an IPv6 issue that's perhaps outside our control... the 'expected' part of this test is deduced by Apache-Test using straight-up

make test fails / mod_perl doesn't work

2007-01-18 Thread ralf . lehmann
Hello list, this is my first post on a mailing-list, so please pardon if I accidently break some rules. Also Enlish isn't my native language but I try to give my best... My problem is, that I have a web-application based on perl-scripts. So far everything is running (IBM-webserver based on Apac