Benchmark results f or the TYPO3 DBAL extensionIntroductionAl l tests with ab (Apac heBench) run on a Pen tium M 1.5 G Hz, 512MB RAMwith Apache 1.3.29, PHP 4. 3.4, Zend Optimizer v2.5.2. running on De bianGNU/Linux (unstable). MySQL was version 4.0.18, Postgre SQL was version7.4.2.The re sults shown are always from the second of two identical runs don eright after each other.The 'webs ite' has one toplevel page with 5 su bpages. The t oplevel pagecontains a text- only CE with a few lin es of text. The template use s cSetstylesheet and content (default) plus a few lines of TS:# De fault PAGE object:page = PAGEpage.typeN um = 0page.5 = HMENUpage.5 { 1 = TMENU 1.NO.allWrap = &r aquo; | }page.10 = TEXTpage.10.value = page.15 < styles.content. getIt looks lik e this (impressive, eh? ):The DBAL was co nfigured like this for MySQL a nd PostgreSQL with exceptionof the driv er use d ( mysql vs. postgres7 ):$TYP O3_CONF_VAR S['EX TCONF']['dbal']['handlerC fg'] = array ( '_DEFAULT' => array ( 'type' => 'adodb', 'config' => array( 'driver' => 'mysql', ) ));SummaryHere are th e sum marized results of Apa cheBench calling this page 300 timeswith a concurrenrcy leve l of 5. The graph shows the n umber of re quests persecond. Th e numb er in parenthesis in the Setup c olumn indicates theunderlying ADOdb ver sion.Setup requests p er sec ms p er requestMySQL 12.59 396.98MySQL, D BAL 6.32 791 ...
Introduction All tests with ab (ApacheBench) run on a Pentium M 1.5 GHz, 512MB RAM with Apache 1.3.29, PHP 4.3.4, Zend Optimizer v2.5.2. running on Debian GNU/Linux (unstable). MySQL was version 4.0.18, PostgreSQL was version 7.4.2. The results shown are always from the second of two identical runs done right after each other. The 'website' has one toplevel page with 5 subpages. The toplevel page contains a text-only CE with a few lines of text. The template usescSet stylesheetandcontent (default)plus a few lines of TS:
The DBAL was configured like this for MySQL and PostgreSQL with exception of the driver used (mysqlvs.postgres7): $TYPO3_CONF_VARS['EXTCONF']['dbal']['handlerCfg'] = array ( '_DEFAULT'=> array ( 'type'=> 'adodb', 'config'=> array( 'driver'=> 'mysql', ) ) );
Summary Here are the summarized results of ApacheBench calling this page 300 times with a concurrenrcy level of 5. The graph shows the number of requests per second. The number in parenthesis in the Setup column indicates the underlying ADOdb version.
Setup MySQL MySQL, DBAL PostgreSQL, DBAL * PostgreSQL, DBAL PostgreSQL, DBAL ** MySQL *** PostgreSQL, DBAL *** PostgreSQ, DBAL **,***
ms per request 396.98 791.62 871.97 871.38 883.13 55.02 277.98 275.37
* DBAL ext used ADOdb 4.22 instead of 4.51 100 ** ADOdb C extension 5.0.1 was installed *** Turck MMCache 2.4.6 was installed90 80 What we can see is that in this setup the M ySQL 70 ADOdb C extension does not hold it's M ySQL,DBAL PostgreSQL, promises. It may well be that this changes DBAL * 60 with larger result sets (dozens or even PostgreSQL, DBAL 50 hundreds of pages) and other databases PostgreSQL, DBAL ** (Oracle is suspectible here, it is mentioned40 M ySQL*** specifically in the documentation). PostgreSQL, 30 DBAL *** We have roughly half of the performance PostgreSQ, with the DBAL in use for MySQL and a bit20DBAL **,*** less than that for PostgreSQL. 10 Things change radically when using Turck 0 MMCache. For PostgreSQL we get more requests per sec than for native MySQL without MMCache, and native access to MySQL simply flies. So when using DBAL the use of an accellerator is a must.
Detailed Results
MySQL without DBAL extension, running the unmodified TYPO3core from CVS ab -n 300 -c 5 'http://localhost/DBAL/mysql/index.php?id=1'
Concurrency Level:5 Time taken for tests:23.819 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:837000 bytes HTML transferred:737400 bytes Requests per second:12.59 [#/sec] (mean) Time per request:396.98 [ms] (mean) Time per request:79.40 [ms] (mean, across all concurrent requests) Transfer rate:35.14 [Kbytes/sec] received
Concurrency Level:5 Time taken for tests:47.497 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:837000 bytes HTML transferred:737400 bytes Requests per second:6.32 [#/sec] (mean) Time per request:791.62 [ms] (mean) Time per request:158.32 [ms] (mean, across all concurrent requests) Transfer rate:17.62 [Kbytes/sec] received
Concurrency Level:5 Time taken for tests:52.318 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:837000 bytes HTML transferred:737400 bytes Requests per second:5.73 [#/sec] (mean) Time per request:871.97 [ms] (mean) Time per request:174.39 [ms] (mean, across all concurrent requests) Transfer rate:16.00 [Kbytes/sec] received
Concurrency Level:5 Time taken for tests:52.283 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:837000 bytes HTML transferred:737400 bytes Requests per second:5.74 [#/sec] (mean) Time per request:871.38 [ms] (mean) Time per request:174.28 [ms] (mean, across all concurrent requests) Transfer rate:16.01 [Kbytes/sec] received
Concurrency Level:5 Time taken for tests:52.988 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:837000 bytes HTML transferred:737400 bytes Requests per second:5.66 [#/sec] (mean) Time per request:883.13 [ms] (mean) Time per request:176.63 [ms] (mean, across all concurrent requests) Transfer rate:15.80 [Kbytes/sec] received
Concurrency Level:5 Time taken for tests:3.301 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:822900 bytes HTML transferred:737400 bytes Requests per second:90.88 [#/sec] (mean) Time per request:55.02 [ms] (mean) Time per request:11.00 [ms] (mean, across all concurrent requests) Transfer rate:249.29 [Kbytes/sec] received
PostgreSQL running the modified TYPO3core and the DBAL extension (ADOdb 4.51), with MMCache ab -n 300 -c 5 'http://localhost/DBAL/pgsql/index.php?id=1'
Concurrency Level:5 Time taken for tests:16.679 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:822900 bytes HTML transferred:737400 bytes Requests per second:17.99 [#/sec] (mean) Time per request:277.98 [ms] (mean) Time per request:55.60 [ms] (mean, across all concurrent requests) Transfer rate:49.34 [Kbytes/sec] received
Concurrency Level:5 Time taken for tests:16.522 seconds Complete requests:300 Failed requests:0 Broken pipe errors:0 Total transferred:822900 bytes HTML transferred:737400 bytes Requests per second:18.16 [#/sec] (mean) Time per request:275.37 [ms] (mean) Time per request:55.07 [ms] (mean, across all concurrent requests) Transfer rate:49.81 [Kbytes/sec] received