|
Posted by FFMG on 01/24/07 06:51
In my site I have a config table, (MySQL), with about 30 entries; the
data is loaded on every single page load. This is not the only call to
the db, (we do a total of about 8 calls to the db).
As with many configurations settings, once the options are set the
values will not change much.
So I thought it would be a good idea to move the data to a flat file.
I have written a small wrapper class to first look for the file, if it
exists then load the data from that file, if not the data is loaded
from the database and then saved to a file.
That way I can copy the database without worries about the cached data
itself.
It all works as expected, but the question is, did I waste my time?
How can I do some load test on my server to see what would be better?
Database call or flat file read.
My personal guess is that the flat file will only help under very heavy
load, (a couple of hundreds/thousand pages a seconds).
What do you think?
Will the flat file help at all?
Simon
Navigation:
[Reply to this message]
|