Issue Type: Bug Created: 2009-03-26T13:02:27.000+0000 Last Updated: 2009-09-17T15:30:29.000+0000 Status: Resolved Fix version(s): - 1.9.3 (22/Sep/09)
Reporter: Matthew Turland (elazar) Assignee: Benjamin Eberlei (beberlei) Tags: - Zend_Loader
Related issues: Attachments: - patch.diff
Zend_Loader_PluginLoader::addPrefixPath has no check to ensure that the same path is not added multiple times per prefix. This issue can be inadvertently triggered by the following process:
The solution is to have Zend_Loader_PluginLoader::addPrefixPath check $this->_prefixToPaths[$prefix] for $path before adding it. Though I'm not entirely certain how or why it would have this effect, making this change removed a huge bottleneck in a Zend_Form-based class I dealt with recently and shaved the load time from 15 seconds to 5 seconds.
A patch to implement the change is attached. (I svn blame Ralph for this. :P)
Posted by Matthew Turland (elazar) on 2009-03-26T13:34:28.000+0000
Added unittest.diff which patches tests/Zend/Loader/PluginLoaderTest.php to add a test case for this patch.
Posted by Benjamin Eberlei (beberlei) on 2009-09-17T15:30:28.000+0000
Patches by Matthew applied and tested, committed and merged into 1.9 release branch.
Have you found an issue?
See the Overview section for more details.