On 16-Apr-2002 Alexander Hartmaier wrote:
> I just reworte view-table.epl...it isn't faster than before....
>
> Here is the new version (the display of the number of lines isn't workling
> any more :(
> Maybe you can tell me what i do false:

Hmmm...

1. I'm unsure whether it's good to use eval around so much code... is it the
most efficient method?  You could wrap it just around the ->prepare and
->execute. Actually, you don't eval at all. The critical DBI method calls
return true or false, which you can catch:

$sth = $dbh->prepare($sqlcmd) || perish ($dbh->errstr);
$sth->execute || perish ($dbh->errstr);

Something to experiment with perhaps.

What does eval do??? (I'm really new!).
What has it to look like if I don't use eval around the perl code at the top of
the script?

(The scripts aren't written by me...I have to maintain and improve them)

--------------------------------

2. Are you able to pinpoint the slow down? E.g. Add statements like:

warn "here at: " . `date`;

To add warn statements into the error_log of where it's at. I've use this trick
quite often. Add one at the very top of the file, one after setting up $dbh,
one before executing, one after executing, one before fetching rows, one after
fetching rows, etc.

3. See what the Embperl docs say about the various debug modes; you should be
able to get a lot more verbose embperl.log debbuging then what your previous
attachment had.

The debug doesn't work :(

That's the config in my httpd.conf:

PerlSetEnv ORACLE_HOME  /opt/oracle/product/9.0.1
PerlSetEnv ORA_NLS33    /opt/oracle/product/9.0.1/ocommon/nls/admin/data
PerlSetEnv NLS_LANG     AMERICAN_AMERICA.WE8ISO8859P1

<Perl>
  use lib "/home/nac/lib";
</Perl>

PerlModule POSIX
PerlModule Time::Local
PerlModule Net::SNMP
PerlModule Embperl
PerlModule Apache::DBI
PerlModule DBD::Oracle
PerlModule Apache::AuthDBI

Embperl_UseEnv on

AddType text/html .epl
AddType text/html .pl

<Files *.epl>
  SetHandler  perl-script
  PerlHandler Embperl
  Options     ExecCGI
</Files>

<Files *.pl>
  SetHandler  perl-script
  PerlHandler Apache::Registry
  Options     ExecCGI
</Files>

# mod_gzip configuration
mod_gzip_on                     Yes
mod_gzip_keep_workfiles         No
mod_gzip_dechunk                Yes
mod_gzip_min_http               1001
mod_gzip_minimum_file_size      1024
mod_gzip_maximum_inmem_size     4194304
mod_gzip_temp_dir               "/tmp/mod_gzip"
mod_gzip_item_include           file    \.htm$
mod_gzip_item_include           file    \.html$
mod_gzip_item_include           file    \.php$
mod_gzip_item_include           file    \.pl$
mod_gzip_item_include           file    \.epl$
mod_gzip_item_include           file    \.cgi$
mod_gzip_item_include           mime    text/.*
mod_gzip_can_negotiate          Yes

# ---------
# Debugging
# ---------

PerlSetEnv EMBPERL_DEBUG 10477
PerlSetEnv EMBPERL_VIRTLOG /var/log/embperl
PerlSetEnv EMBPERL_LOG /var/log/embperl/embperl.log

<Location /var/log/embperl>
  SetHandler perl-script
  PerlHandler Embperl
  Options ExecCGI
</Location>

-----------------------------

Regards,

Wim Kerkhoff  -|-  www.nyetwork.org  -|-  [EMAIL PROTECTED]





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to