On Tue, Feb 3, 2009 at 5:59 PM, A.J. Brown <[email protected]> wrote: > > > On Mon, Feb 2, 2009 at 9:50 PM, till <[email protected]> wrote: >> >> > 2. The example app use Zend_Config_Ini to read ini file every request, >> > will it be slow in real apps? (since parsing take time) >> >> Yes, but keep in mind that you will only notice it when you get a lot >> of traffic. And you can always employ Zend_Cache later on. But I >> wouldn't fix this now since I gather it's your first ZF app. Just make >> a note (to yourself) and keep it in mind for later. >> >> Cheers, >> Till > > > While it is a good idea to cache the config file, you'll probably find > higher priority optimizations if you were to run a profiler (at least this > is what I've found). So don't sweat it too much :) > > Of course, it depends on the size of your config file. >
Parsing an .ini is *very* expensive. It's also extra i/o on each request. So if you can utilize APC and use shared memory to store it, it's a tremendous boost. I haven't tested with xml'ed config files. So this is all related to Zend_Config_Ini and parse_ini_file(). Till
