Issues

ZF-5649: Reduce Zend_Gdata latency

Description

Performance for Zend_Gdata is currently less than ideal. Excluding time blocked on network I/O, we're spending 650 ms to parse the YouTube top rated videos feed. This should be lower.

This is a general tracking bug. Fixes for individual performance hotspots should be filed as subtasks.

Comments

While profiling an application that uses the Zend_Gdata_Photos API, I discovered that lookupNamespace() was particularly heavily called and dominates the runtime of the app. I tracked this down to the implementation of the various takeChildFromDOM methods.

I've attached a zip file containing a test program, test data and a patch against ZF 1.7.8 that illustrate the issue. With the patch applied I achieved a 2.5x increase in performance.

Test program, data and patch that highlight poor performance of the various takeChildFromDOM methods.

Paul, thanks for this patch!

However, before I can review and commit it, you'll need to have a CLA on file with the Zend Framework project. The instructions for this are here:

http://framework.zend.com/community/contribute

Would you be okay with this? If so, please let me know once your CLA has been received and processed.

Hi Trevor,

I'm happy to help!

I didn't intend for the patch to be directly applied. I produced it to illustrate the issue and help people think about a solution. I'd be delighted if you can use it to inform the development of a better patch. You surely know the Gdata architecture far better than I. :)

I'm currently investigating both this issue and ZF-5959. I hope to soon provide a more comprehensive and holistic set of recommendations to improve the performance of the Gdata library. I'm comfortable signing the CLA but it doesn't seem necessary at this early stage. If, however, you need me to sign it in order to use what I have provided thus far, of course I shall do so forthwith.

my temportary context