perl-asp mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Heiss" <Christ...@heiss-net.de>
Subject performance problems...
Date Wed, 13 Jun 2001 22:11:26 GMT
Hi there,

I have a PIII 800Mhz Linux Box with:
SuSE7.0, Apache1.3.17, mod_perl1.24_01,  ASP2.15

The following optional modules are installed:

 >... found Apache::Filter !
 >... found Apache::SSI !
 >... found CGI !
 >... found Compress::Zlib !
 >... found DB_File !
 >... found Devel::Symdump !
 >... found HTML::Clean !
 >... found HTML::FillInForm !
 >... found MLDBM::Sync::SDBM_File !
 >... found Net::Config !
 >... found Net::SMTP !
 >... found Time::HiRes !
 >??? you may want module: XML::Sablotron
 >    WHY: XSLT that is 10 times faster than XML::XSLT
> ... found XML::XSLT 0.32 !

I parse my *.html files from a directory to build automatically a header and a footer, 
also I'm searching for not used code in the files... :-)

My global.asa is:
>.
>.
>.sub Script_OnStart {
>    $Response->Include('./inc/header.inc');
>}
>sub Script_OnEnd {
>    $Response->Include('./inc/footer.inc')
>}
>
>sub Script_OnFlush {
>    if($Response->{ContentType} eq 'text/html') {
>        my $data = $Response->{BinaryRef};
>        $$data =~ s/(.*?)(\<title.*?\/title\>)(.*?)(\<title.*?\/title\>)/$1$4$3/isg;
>        $$data =~ s/(.*?)(\<META name="description".*?\>)(.*?)(\<META name="description".*?\>)/$1$4$3/is;
>        $$data =~ s/(.*?)(\<META name="author".*?\>)(.*?)(\<META name="author".*?\>)/$1$4$3/is;
>        $$data =~ s/(.*?)(\<META name="keywords".*?\>)(.*?)(\<META name="keywords".*?\>)/$1$4$3/is;
>        $$data =~ s/(.*?)(\<META name="date".*?\>)(.*?)(\<META name="date".*?\>)/$1$4$3/is;
>        $$data =~ s/(.*?)(\<link rel="stylesheet".*?\>)(.*?)(\<link rel="stylesheet.*?\>)/$1$4$3/is;
>        $$data =~ s/\<!-- end_header.*?\<body.*?\>//is;
>        $$data =~ s/\<\/body.*?\/html\>//is;
>        $$data =~ s/\<!-- end_footer.*//is;
>        $$data =~ s/\<font.*?\>//isg;                                 
>        $$data =~ s/\<\/font.*?\>//isg;
>        $$data =~ s/\<!--mstheme*.?\>//isg;
>        $$data =~ s/\<!--msnavi*.?\>//isg;
>        $$data =~ s/Ä/\&Auml;/isg;
>        $$data =~ s/ä/\&auml;/isg;
>        $$data =~ s/Ö/\&Ouml;/isg;
>        $$data =~ s/ö/\&ouml;/isg;
>        $$data =~ s/Ü/\&Uuml;/isg;
>        $$data =~ s/ü/\&uuml;/isg;
>        $$data =~ s/ß/\&szlig;/isg;
>
>    }
>}

All works fine, but my problem is, that with this configuration the server is very slowly.
In the background I'm using a MySQL-Database to get some data. And when I connect to it,
it needs up to 8 seconds to get my request on the browser (in the LAN)...
If I change my search and replace statements to less, it is really fast!!!

if u like, take a look at: http://www.datentechnik-moll.de/neu2/katalog.html

Does anybody knows how to solve my problem?
Maybe with another / better configuration?

Thanks

Christian Heiss

Mime
View raw message