[Zope] performance concern
Oliver Bleutgen
myzope@gmx.net
Fri, 05 Apr 2002 19:59:10 +0200
Bill Ort wrote:
> Hi,
>
> We are new to Zope and are trying to create a form- and db-intensive web
> application using Zope 2.4.0 (though I'm testing in 2.5 also). I've noticed
> that our complex forms (which use nested dtml-in loops) are running
> extremely slow, taking more than 30 seconds on the server side (450MHz
> Pentium II w/ linux). So I created a snippet benchmark and noticed
> something peculiar, in that running a simple loop for the first time is
> often very slow, however in subsequent refreshes of the document the loop
> runs almost 8-10 times faster. I turned off caching as much as I know how
> (in the browser and zope). Here is the benchmark I'm using:
>
> <dtml-var standard_html_header>
> <dtml-comment>Note: My standard header turns off browser
> caching.</dtml-comment>
> <dtml-call "REQUEST.set('starttime',_.DateTime().millis())">
> Start Time (ms): <dtml-var starttime><br>
> <dtml-call
> "REQUEST.set('testlist',['1','2','3','4','5','6','7','8','9','10'])">
> <dtml-in "testlist">
> <dtml-var sequence-item>
> </dtml-in>
> <br>
> <dtml-call "REQUEST.set('endtime',_.DateTime().millis())">
> End Time (ms): <dtml-var endtime><br>
> <hr size=1>
> Delay (ms) = <dtml-var "endtime - starttime"><br>
> <dtml-var standard_html_footer>
>
> Any help would be extremely welcome...as is, the site is too slow to demo to
> potential clients.
Whaddayamean, slow?
bleutgen@baal:~ > cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 5
model name : Pentium II (Deschutes)
stepping : 2
cpu MHz : 350.799293
cache size : 512 KB
Start Time (ms): 1018026618031L
1 2 3 4 5 6 7 8 9 10
End Time (ms): 1018026618038L
--------------------------------------------------------------------------------
Delay (ms) = 7L
bleutgen@baal:~/work/bin > ab -n 100 http://localhost:30080/test/testrequest
This is ApacheBench, Version 1.3c <$Revision: 1.38 $> apache-1.3
Copyright (c) 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Copyright (c) 1998-1999 The Apache Group, http://www.apache.org/
Server Software: Zope/Zope
Server Hostname: localhost
Server Port: 30080
Document Path: /test/testrequest
Document Length: 270 bytes
Concurrency Level: 1
Time taken for tests: 3.247 seconds
Complete requests: 100
Failed requests: 0
Total transferred: 46900 bytes
HTML transferred: 27000 bytes
Requests per second: 30.80
Transfer rate: 14.44 kb/s received
Connnection Times (ms)
min avg max
Connect: 0 0 1
Processing: 31 31 33
Total: 31 31 34
30 req. per second from localhost, 7ms over 100Mbit ethernet is too slow?
Guess there's something else going on.
cheers,
oliver