News Feed
Jobs Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Phil Bennett:
Revisiting Benchmarking Dependency Injection Containers
July 30, 2013 @ 11:56:49

Phil Bennett has returned to a topic he covered earlier to refresh some of the statistics and add a few newer technologies to the mix. In this new post he benchmarks some of the more popular PHP-based dependency injection containers.

A few months ago I wrote a post detailing and benchmarking several dependency injection containers. Recently there have been some changes to some of these containers and some new packages have appeared in the community so I decided to revisit the post and update it a little. When I say a little, I'm going to be re-writing the entire post to give you a little more information about the containers and some more in-depth benchmarks.

Several new DI containers were added including the AuraDi, PHP-DI and LeagueDi. His benchmarks measure the time taken for these operations:

  • Extremely nested object fetching
  • Registering all objects
  • Resolving objects (w/dependencies) using a factory
  • Injecting pre-defined constructor values
  • Resolving dependencies with setter calls

Code for the test and graphs of the outcomes are provided for each benchmark on the list. There's also a bit of analysis at the end of the post detailing some of the pros and cons of each.

0 comments voice your opinion now!
benchmark dependency injection container di microseconds code

Link: http://happyaccidents.me/revisiting-benchmarking-dependency-injection-containers/

blog comments powered by Disqus

Similar Posts

Zend Developer Zone: PHP Security Tips #6 and #7

Paul Jones' Blog: Dependency Injection in Solar

Matthias Noback: There’s no such thing as an optional dependency

Sam Hennessy's Blog: A Dependency Injection for PHP Manifesto - Part 1 (What I Want)

Reddit.com: Where can I find a free place to edit PHP code and see the results?


Community Events











Don't see your event here?
Let us know!


facebook hack release package overview security unittest composer framework component application hhvm podcast code introduction install opinion example language symfony2

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework