[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mtos-dev
Subject:    [MTOS-dev] Performance
From:       Alvar Freude <alvar () a-blast ! org>
Date:       2008-02-25 22:02:27
Message-ID: C04B4BB24931C147EDCCDB0F () Chefkoch ! local
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


Hi,

[it seems that something has eaten my first mail about this some days 
ago, so I try to repost it (with two small typo corrections)]


inspired by 4.1.1 and the performance monitoring framework I made some 
simple performance tests -- first steps and without the new monitoring 
framework ;-)

I am sure that one of the bottlenecks is the SQL. So I looked into my 
PostgreSQL-Log and there it mentions before *every* request the following 
request:

  SELECT 'DBD::Pg ping test'


For a simple page (entrie administration of a test blog with one entry) 
there are 24 SQL queries and for each there is such a ping. It is very 
fast, but in summary it costs some time.

The Ping comes from DBD::Pg via $dbh->ping in line 68 of 
Data::ObjectDriver::Driver::DBI. I think the pings should be reduced to 
one per HTTP-Request.


For my taste there also too much SQL queries; in the entry list there is 
one additional query for each displayed entry, so on another blog with 5 
entries I get 28 queries.

I guess that this can be reduced dramatically by using some more joins 
etc.
Perhaps it may be possible to create manually some views and tell 
Data::ObjectDriver about them.


All SQL-Queries are no prepared queries; using $dbh->prepare_cached (at 
least when running in a persistent environment) should speed up 
everything a little bit.

As far as i remember the queries were (server side) prepared in an older 
version, but only executed once and every time newly prepared?
I think that the prepared statements should be reactivated when running 
in a persistent environment.


Ciao
  Alvar

-- 
** Alvar C.H. Freude, http://alvar.a-blast.org/
** http://www.assoziations-blaster.de/
** http://www.wen-waehlen.de/
** http://odem.org/

[Attachment #5 (application/pgp-signature)]

_______________________________________________
MTOS-dev mailing list
MTOS-dev@sixapart.com
http://www.sixapart.com/mailman/listinfo/mtos-dev


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic