Benchmarking Zend_Config_Xml and Zend_Config_Ini

Posted 23:59, on 18/7/2008 in Web

Comments (3) Tags: xml, zend framework, ini

Comments

Rob
08:07, on 22/7/2008
From a performance point of view, I would recommend caching the loaded Zend_Cache object and then using your preferred format. Configuration params usually change so infrequently, that you can generally use a really long cache expiry too.

Regards,

Rob...
Sebastian
08:57, on 20/1/2009
I am profiling an app of ours and it turned out, that Zend_Config_Xml consumed over 40% of the overall script runtime. This is definitely a lot and happens due to the internal conversion from XML to Array by using the protected _toArray-function.

I then used the Zend_Cache and File-frontend which comes in very handy when using configuration files since you can set a master-file. Any modification to this file automatically refreshes the cache. You don't have to worry about cache expiry.

Well, now that we are using cached configuration objects, the speed was enhanced by a factor of 10!

Conclusion: Even though xml-Config files are nice, be sure to keep em cached since Zend_Config_Xml isn't very fast.
Jason
21:12, on 23/4/2009
On my machine:
xml 3.0941619873 3.0941619873 1 51.27% Global (1)
ini 2.94120907784 2.94120907784 1 48.73% Global (1)

Add Comment

External articles that may be of interest:

Rasmus - PHP Performance

Full video of a talk Rasmus gave at Digg HQ on PHP performance. After a brief look at PHP 5.3's new features he sets about improving the performance of an out-of-the-box Wordpress installation.

Adobe releases 64-bit flash player for Linux

Adobe have released an alpha of their 64-bit flash player for Linux (I believe this is the first 64-bit player they've done on any platform, it's not available for Windows or Mac yet). And it works great. It may be an alpha but so far I've found it considerably more stable than the released 32-bit wrapper version. It also uses considerably less CPU power. Easy installation instructions via. this blog entry.

MS Office in the browser

The most interesting thing about this announcement is that MS say the system will work in Firefox and Safari as well as IE. The Microsoft of 10 years ago would have used proprietary IE only code and used it as a way to leverage IE market share.

The Future of Advertising, Branding, Media and Communications

Video of a very interesting talk by Gerd Leonhard on the future of the media industry, and content on the Internet.

Future of web browsing from Mozilla Labs

Some interesting ideas about how web browsing might look in the future (watch the first video).