[kdewebdev-webdeveloper] test
Andrew Lowe
andrew.lowe at manildra.com.au
Thu Mar 6 17:32:30 EST 2008
On Thu, 6 Mar 2008 23:09:37 Isaak wrote:
> Hey,
>
>
> I've made my mind and just use PHP to read the XML file(s), too bad because
> using AJAX was way more fun.. But hey, performance and user experience
> should be #1 :).
>
Any new tech will be fun...
> I was rather vague about the "filesystem being much slower than the
> database" but your explanation explains it so there is no need for me to go
> deeper into this. Well, even newbies know that PHP wins over AJAX for
> parsing the same data so benchmarking the AJAX solution would be out of the
> question. As you brought the benchmarking up this really interests me, I'm
> going to test the differences in performance using PHP with XML and PHP
> with MySQL. So if I'm correct, you would vote for PHP with XML as long as
> no file searching is done and the file is of small size? As a web developer
> using the database system most of the time I'm going to place my bet on PHP
> with MySQL using MyISAM tables (even though I'm not very confident about
> it). I'm going to give this some time and let you know the results.
I am not really sure if the XML will be faster or slower... I am not a fan of
storing data in XML or even transferring in XML - I prefer traditional comma
separated text, but I am coming around to the idea as it can be very useful.
I tend to deal with very dynamic data with users adding new data and reading
very often, so stick with database.
For benchmarking, I suggest using a bash/php script like to request each page
a set number of times (10,000) using wget within a loop:
wget -q -O /dev/null http://www.domain.com/index.php
And check how long it takes to run in total time, and also the server load
before and after: uptime - the numbers are 1minute, 5minute, 15 minute load
averages - you probably only need to worry about the 1 minute average. You
also want to try to run this when the server is not taking other requests -
this is the only load.
>
>
> Most people would start with simpler projects unlike your first project, my
> first AJAX experiment was the famous and simple "username already exists?"
> lookup. And perhaps you won't believe this but this simple project was a
> real pain for my first time..
>
I wrote the music player, and wanted to add more features, and got a bit
carried away - but I had some experience with javascript before, and playing
with data stored in arrays in the javascript code loaded with the page (way
before AJAX hit the spotlight).
--
Andrew Lowe
System Administrator & Programmer
Information Technology
Manildra Group
Email: andrew.lowe at manildra.com.au
Phone: 02 4423 8270
Mobile: 04 1323 8270
Fax: 02 4421 7760
More information about the kdewebdev-webdeveloper
mailing list