67071Re: [mp2] $| doesn't work with mod_perl
- Sep 16, 2005Can you please elaborate on why apache filters can be an issue with the autoflush problem that I noticed ?
Also, I noticed that the autoflush work properly when I flush it to a regular file. Its only when I choose STDOUT that the flushing gets delayed. Is there some buffering that happens with STDOUT alone ? I am confused if this is a modperl problem or an Apache problem.On 9/12/05, pradeep kumar <pradeep.smani@... > wrote:Hi Tom,I am using mp2.Thanks and Regards,Pradeep
On 9/12/05, Tom Schindl <tomAtLinux@...> wrote:
-----BEGIN PGP SIGNED MESSAGE-----
What version of mp are you using if you are running mp2 i think the
apache-filter-system is the problem.
pradeep kumar wrote:
> I have a perl script which uses $| to set autoflush on. Basically, it
> flushes after every print. This script is working fine from the command
> line when run using standalone perl interpreter. But when the same
> script is accessed via mod_perl/apache setup, mod_perl is not flushing
> after every print, instead buffering and printing all output at one shot.
> Any idea why $| is not working with mod_perl.
> Here is my sample script:
> #!/usr/bin/perl -w
> use CGI qw/:standard/;
> use strict;
> $| = 1;
> print STDOUT "Content-type: text/html\n\n"; print STDOUT <<END; <html>
> <head> </head> <body> END print STDOUT 'hello'; print STDOUT '<br>';
> sleep(2); print STDOUT 'World'; print STDOUT '<br>'; sleep(2); print
> STDOUT 'Testing'; print STDOUT "</body></html>";
> Thanks in advance,
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
Comment: Using GnuPG with Mandriva - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
- << Previous post in topic Next post in topic >>