You are here: Re: DB -> Flat file, did I waste my time? « PHP Programming Language « IT news, forums, messages
Re: DB -> Flat file, did I waste my time?

Posted by Norman Peelman on 01/25/07 11:29

FFMG wrote:
> 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
>

And in addition to my previous post... you can include your config
table in your regular backups and it's one less thing to worry about if
you happen to lose anything.

Norm

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация