<?xml version="1.0" encoding="UTF-8"?><rss
version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
> <channel><title>Comments on: Dependency Injection Inversion Rejection</title> <atom:link href="http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/feed/" rel="self" type="application/rss+xml" /><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/</link> <description>inquisitive: adjective. given to inquiry, research, or asking questions; eager for knowledge; intellectually curious</description> <lastBuildDate>Wed, 08 Feb 2012 11:42:42 +0000</lastBuildDate> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.1</generator> <item><title>By: Inversion Of Control Containers And Factories Aren&#8217;t Mutually Exclusive &#124; The Inquisitive Coder &#8211; Davy Brion&#39;s Blog</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25904</link> <dc:creator>Inversion Of Control Containers And Factories Aren&#8217;t Mutually Exclusive &#124; The Inquisitive Coder &#8211; Davy Brion&#39;s Blog</dc:creator> <pubDate>Sat, 23 Jan 2010 15:23:24 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25904</guid> <description>[...] Dependency Injection Inversion Rejection [...]</description> <content:encoded><![CDATA[<p>[...] Dependency Injection Inversion Rejection [...]</p> ]]></content:encoded> </item> <item><title>By: igorbrejc.net &#187; Fresh Catch For January 21st</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25637</link> <dc:creator>igorbrejc.net &#187; Fresh Catch For January 21st</dc:creator> <pubDate>Thu, 21 Jan 2010 14:05:51 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25637</guid> <description>[...] Dependency Injection Inversion Rejection &#124; The Inquisitive Coder &#8211; Davy Brion&#8217;s Blog [...]</description> <content:encoded><![CDATA[<p>[...] Dependency Injection Inversion Rejection | The Inquisitive Coder &ndash; Davy Brion&#8217;s Blog [...]</p> ]]></content:encoded> </item> <item><title>By: Mel Grubb</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25539</link> <dc:creator>Mel Grubb</dc:creator> <pubDate>Wed, 20 Jan 2010 17:37:12 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25539</guid> <description>I would have to say that there are very valid reasons for moving the code which &quot;touches&quot; the IoC into a factory. I can value centralizing this code in one place because, quite frankly, if you&#039;ve got a lot of code touching the IoC, you&#039;re doing it wrong. In my case I can see definite value to wanting the IoC to be swappable as well. From one client to the next, I have found that I very rarely use exactly the same set of components. Usually this is because client &quot;A&quot; was already using StructureMap, client &quot;B&quot; was already using Ninject, and the new client &quot;C&quot; has a &quot;Microsoft by default&quot; mentality which mandates Unity. As a result, I try to isolate ALL such dependencies on external tools whenever it&#039;s practical, just so that I can reuse as much of my reference code as possible.</description> <content:encoded><![CDATA[<p>I would have to say that there are very valid reasons for moving the code which &#8220;touches&#8221; the IoC into a factory. I can value centralizing this code in one place because, quite frankly, if you&#8217;ve got a lot of code touching the IoC, you&#8217;re doing it wrong. In my case I can see definite value to wanting the IoC to be swappable as well. From one client to the next, I have found that I very rarely use exactly the same set of components. Usually this is because client &#8220;A&#8221; was already using StructureMap, client &#8220;B&#8221; was already using Ninject, and the new client &#8220;C&#8221; has a &#8220;Microsoft by default&#8221; mentality which mandates Unity. As a result, I try to isolate ALL such dependencies on external tools whenever it&#8217;s practical, just so that I can reuse as much of my reference code as possible.</p> ]]></content:encoded> </item> <item><title>By: The Morning Brew - Chris Alcock &#187; The Morning Brew #521</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25514</link> <dc:creator>The Morning Brew - Chris Alcock &#187; The Morning Brew #521</dc:creator> <pubDate>Wed, 20 Jan 2010 10:54:41 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25514</guid> <description>[...] Dependency Injection Inversion Rejection - Davy Brion picks up on some of the points in Uncle Bob&#8217;s recent post on Dependency injection mostly discussing the flip side of the pointsand how the suggested usage still causes too much coupling to the container. Jimmy Bogard also follows up on the same topic with his post Poor use of DI versus need for DI. [...]</description> <content:encoded><![CDATA[<p>[...] Dependency Injection Inversion Rejection &#8211; Davy Brion picks up on some of the points in Uncle Bob&#8217;s recent post on Dependency injection mostly discussing the flip side of the pointsand how the suggested usage still causes too much coupling to the container. Jimmy Bogard also follows up on the same topic with his post Poor use of DI versus need for DI. [...]</p> ]]></content:encoded> </item> <item><title>By: Davy Brion</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25496</link> <dc:creator>Davy Brion</dc:creator> <pubDate>Wed, 20 Jan 2010 08:14:08 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25496</guid> <description>@NimaYeah i kinda agree with that... something really bad would have to happen before i&#039;d want to switch containers in one of our projects.  The whole thing about switching containers during the lifetime of a project is very similar to how people talk about being able to switch ORM&#039;s during the lifetime of a project.  A lot of people say they want to be able to do that, while in reality hardly anyone actually does it.</description> <content:encoded><![CDATA[<p>@Nima</p><p>Yeah i kinda agree with that&#8230; something really bad would have to happen before i&#8217;d want to switch containers in one of our projects.  The whole thing about switching containers during the lifetime of a project is very similar to how people talk about being able to switch ORM&#8217;s during the lifetime of a project.  A lot of people say they want to be able to do that, while in reality hardly anyone actually does it.</p> ]]></content:encoded> </item> <item><title>By: Nima</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25495</link> <dc:creator>Nima</dc:creator> <pubDate>Wed, 20 Jan 2010 08:10:52 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25495</guid> <description>The question is why somebody wants to change his IoC container anyway? To me an IoC frmaework is like the system backbone (because most of IoC frameworks are Application frameworks too) We use Castle in our projects and I can&#039;t imagine that we can live without it for a second.not only it&#039;s our IoC container but we are using it to intercept our code using DynamicProxy to manage our transactions using NHibernate and Transaction facilities.</description> <content:encoded><![CDATA[<p>The question is why somebody wants to change his IoC container anyway? To me an IoC frmaework is like the system backbone (because most of IoC frameworks are Application frameworks too) We use Castle in our projects and I can&#8217;t imagine that we can live without it for a second.not only it&#8217;s our IoC container but we are using it to intercept our code using DynamicProxy to manage our transactions using NHibernate and Transaction facilities.</p> ]]></content:encoded> </item> <item><title>By: Davy Brion</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25493</link> <dc:creator>Davy Brion</dc:creator> <pubDate>Wed, 20 Jan 2010 07:50:10 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25493</guid> <description>@Juliani&#039;m gonna reply to that post later on :)@Willyou don&#039;t really need to put a layer on top of it... that&#039;s only useful when you&#039;re writing a framework/library which needs to be able to support multiple containers but for most applications, it&#039;s unnecessary.  Again, if you want to switch containers it should only be a very minor change in very few places.  Unless of course, you&#039;re using very specific features of a certain container that aren&#039;t supported by other containers.  But in that case, a layer on top of it wouldn&#039;t give you any benefit either.</description> <content:encoded><![CDATA[<p>@Julian</p><p>i&#8217;m gonna reply to that post later on <img
src='http://d18sni7re4ly7f.cloudfront.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /></p><p>@Will</p><p>you don&#8217;t really need to put a layer on top of it&#8230; that&#8217;s only useful when you&#8217;re writing a framework/library which needs to be able to support multiple containers but for most applications, it&#8217;s unnecessary.  Again, if you want to switch containers it should only be a very minor change in very few places.  Unless of course, you&#8217;re using very specific features of a certain container that aren&#8217;t supported by other containers.  But in that case, a layer on top of it wouldn&#8217;t give you any benefit either.</p> ]]></content:encoded> </item> <item><title>By: Will</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25479</link> <dc:creator>Will</dc:creator> <pubDate>Wed, 20 Jan 2010 00:33:32 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25479</guid> <description>The thing I don&#039;t understand is why Uncle Bob wouldn&#039;t just put a layer over his IoC container so that it is truly invisible to the rest of the application.  Wouldn&#039;t that be the ideal approach rather than ditching the container altogether?</description> <content:encoded><![CDATA[<p>The thing I don&#8217;t understand is why Uncle Bob wouldn&#8217;t just put a layer over his IoC container so that it is truly invisible to the rest of the application.  Wouldn&#8217;t that be the ideal approach rather than ditching the container altogether?</p> ]]></content:encoded> </item> <item><title>By: Julian Birch</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25461</link> <dc:creator>Julian Birch</dc:creator> <pubDate>Tue, 19 Jan 2010 21:23:45 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25461</guid> <description>I think the factory idea has a lot more legs than you give it credit for.  I&#039;m afraid my justification of that ran to four pages.http://www.colourcoding.net/Blog/archive/2010/01/19/dependency-reversi.aspx</description> <content:encoded><![CDATA[<p>I think the factory idea has a lot more legs than you give it credit for.  I&#8217;m afraid my justification of that ran to four pages.</p><p><a
href="http://www.colourcoding.net/Blog/archive/2010/01/19/dependency-reversi.aspx" rel="nofollow">http://www.colourcoding.net/Blog/archive/2010/01/19/dependency-reversi.aspx</a></p> ]]></content:encoded> </item> <item><title>By: Davy Brion</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25454</link> <dc:creator>Davy Brion</dc:creator> <pubDate>Tue, 19 Jan 2010 18:50:24 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25454</guid> <description>@Mortenin the case of WebForms, we did something like this:have each page inherit from your YourProjectPage.  YourProjectPage has a generic type parameter of TPresenter (or TController of whatever you want to call it).  The constructor of YourProjectPage resolves the TPresenter (or TController) in its constructor and all of its dependencies will be supplied by the IOC container.  And that&#039;s it... one Resolve statement in your entire Web Application.In the case of a service layer, either use Castle&#039;s WCF facility to automatically resolve your service instance, or use something like Agatha which does it for you.  When the request is received in your service layer, there is essentially one resolve being executed by the container which gives you the component to handle the request.  And obviously, all of its dependencies (and their dependencies, etc...) will be fulfilled.</description> <content:encoded><![CDATA[<p>@Morten</p><p>in the case of WebForms, we did something like this:</p><p>have each page inherit from your YourProjectPage.  YourProjectPage has a generic type parameter of TPresenter (or TController of whatever you want to call it).  The constructor of YourProjectPage resolves the TPresenter (or TController) in its constructor and all of its dependencies will be supplied by the IOC container.  And that&#8217;s it&#8230; one Resolve statement in your entire Web Application.</p><p>In the case of a service layer, either use Castle&#8217;s WCF facility to automatically resolve your service instance, or use something like Agatha which does it for you.  When the request is received in your service layer, there is essentially one resolve being executed by the container which gives you the component to handle the request.  And obviously, all of its dependencies (and their dependencies, etc&#8230;) will be fulfilled.</p> ]]></content:encoded> </item> <item><title>By: Awkward Coder</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25448</link> <dc:creator>Awkward Coder</dc:creator> <pubDate>Tue, 19 Jan 2010 16:44:31 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25448</guid> <description>@Davy - totally on the same wave length...People seem to think that using an IoC is going to reduce explicit code complexity, it doesn&#039;t (well may be StructureMap does with it&#039;s fluent candy). It&#039;s better to centralise your thinking around object life in a central location than have it splintered and spread around multiple factory classes.My current project is exactly as you describe a central registry and we specifi bootstrappers for WCF, NH and HTTP handlers.Awkward Coder</description> <content:encoded><![CDATA[<p>@Davy &#8211; totally on the same wave length&#8230;</p><p>People seem to think that using an IoC is going to reduce explicit code complexity, it doesn&#8217;t (well may be StructureMap does with it&#8217;s fluent candy). It&#8217;s better to centralise your thinking around object life in a central location than have it splintered and spread around multiple factory classes.</p><p>My current project is exactly as you describe a central registry and we specifi bootstrappers for WCF, NH and HTTP handlers.</p><p>Awkward Coder</p> ]]></content:encoded> </item> <item><title>By: Morten Jacobsen</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25445</link> <dc:creator>Morten Jacobsen</dc:creator> <pubDate>Tue, 19 Jan 2010 15:58:20 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25445</guid> <description>Being relatively new to the whole IoC container thing (started experimenting with Castle Windsor based on one of your posts), I was wondering if you could maybe comment a bit more on your the use of your container..You write in your post&quot; ... you’d only have to change your registration code and the one or two places where you resolve something manually through the container.&quot;Now, as I said I am still new to IoC containers, so this may be a stupid question, but could you give some examples of how to achieve this goal of one or two manual resolves to the container? In the Website I am writing at the moment I seem to have quite a few manual resolves compared to your statement... I am using ASP.NET (but not MVC unfortunately)..Regards,
Morten</description> <content:encoded><![CDATA[<p>Being relatively new to the whole IoC container thing (started experimenting with Castle Windsor based on one of your posts), I was wondering if you could maybe comment a bit more on your the use of your container..</p><p>You write in your post</p><p>&#8221; &#8230; you’d only have to change your registration code and the one or two places where you resolve something manually through the container.&#8221;</p><p>Now, as I said I am still new to IoC containers, so this may be a stupid question, but could you give some examples of how to achieve this goal of one or two manual resolves to the container? In the Website I am writing at the moment I seem to have quite a few manual resolves compared to your statement&#8230; I am using ASP.NET (but not MVC unfortunately)..</p><p>Regards,<br
/> Morten</p> ]]></content:encoded> </item> <item><title>By: Davy Brion</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25440</link> <dc:creator>Davy Brion</dc:creator> <pubDate>Tue, 19 Jan 2010 13:52:19 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25440</guid> <description>@Krzysztofdismissing a practice almost in its entirety based on one bad IOC container or some people&#039;s bad usage of it is completely unprofessional, irresponsible and i&#039;d even say ignorantHe should realize that many people will take his advice and run with it. When that advice is based on faulty data (the &#039;bad&#039; IOC container, or the &#039;bad&#039; usage of some people), there&#039;s quite a bit of damage being done which essentially doesn&#039;t help _anyone_</description> <content:encoded><![CDATA[<p>@Krzysztof</p><p>dismissing a practice almost in its entirety based on one bad IOC container or some people&#8217;s bad usage of it is completely unprofessional, irresponsible and i&#8217;d even say ignorant</p><p>He should realize that many people will take his advice and run with it. When that advice is based on faulty data (the &#8216;bad&#8217; IOC container, or the &#8216;bad&#8217; usage of some people), there&#8217;s quite a bit of damage being done which essentially doesn&#8217;t help _anyone_</p> ]]></content:encoded> </item> <item><title>By: Dependency Injection Inversion &#124; YOOT</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25438</link> <dc:creator>Dependency Injection Inversion &#124; YOOT</dc:creator> <pubDate>Tue, 19 Jan 2010 13:50:52 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25438</guid> <description>[...] Several people have reacted to a controversial post by Uncle Bob on that topic with, among the most vocal ones, Davy. [...]</description> <content:encoded><![CDATA[<p>[...] Several people have reacted to a controversial post by Uncle Bob on that topic with, among the most vocal ones, Davy. [...]</p> ]]></content:encoded> </item> <item><title>By: Krzysztof Koźmic</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25437</link> <dc:creator>Krzysztof Koźmic</dc:creator> <pubDate>Tue, 19 Jan 2010 13:48:17 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25437</guid> <description>Davy,well - I was really one of the first people to comment on his post (http://twitter.com/kkozmic/statuses/7873032098)
I don&#039;t want to sound like one of these people who follow Uncle Bob blindly, as you described it, but I would give him benefit of a doubt.
The way I see it (I don&#039;t know guice beyond what he shows in the post) - he&#039;s just working with pretty basic container, which does not offer things that .NET container do (what I alluded to in my 140chars tweet). There&#039;s no batch registration, no conventions based injection. It&#039;s .NET 2003 IoC. We were doing the same thing in 2003, and if anything, I treat this post as a testament of how .NET IoC tools are ahead of Java.</description> <content:encoded><![CDATA[<p>Davy,</p><p>well &#8211; I was really one of the first people to comment on his post (<a
href="http://twitter.com/kkozmic/statuses/7873032098" rel="nofollow">http://twitter.com/kkozmic/statuses/7873032098</a>)<br
/> I don&#8217;t want to sound like one of these people who follow Uncle Bob blindly, as you described it, but I would give him benefit of a doubt.<br
/> The way I see it (I don&#8217;t know guice beyond what he shows in the post) &#8211; he&#8217;s just working with pretty basic container, which does not offer things that .NET container do (what I alluded to in my 140chars tweet). There&#8217;s no batch registration, no conventions based injection. It&#8217;s .NET 2003 IoC. We were doing the same thing in 2003, and if anything, I treat this post as a testament of how .NET IoC tools are ahead of Java.</p> ]]></content:encoded> </item> <item><title>By: Bjarte</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25433</link> <dc:creator>Bjarte</dc:creator> <pubDate>Tue, 19 Jan 2010 11:55:54 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25433</guid> <description>I agree as well. Jimmi Bogard had a similar response (http://www.lostechies.com/blogs/jimmy_bogard/archive/2010/01/18/poor-use-of-di-versus-need-for-di.aspx)</description> <content:encoded><![CDATA[<p>I agree as well. Jimmi Bogard had a similar response (<a
href="http://www.lostechies.com/blogs/jimmy_bogard/archive/2010/01/18/poor-use-of-di-versus-need-for-di.aspx" rel="nofollow">http://www.lostechies.com/blogs/jimmy_bogard/archive/2010/01/18/poor-use-of-di-versus-need-for-di.aspx</a>)</p> ]]></content:encoded> </item> <item><title>By: Mike</title><link>http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/comment-page-1/#comment-25428</link> <dc:creator>Mike</dc:creator> <pubDate>Tue, 19 Jan 2010 10:43:23 +0000</pubDate> <guid
isPermaLink="false">http://davybrion.com/blog/2010/01/dependency-injection-inversion-rejection/#comment-25428</guid> <description>Agree! Also read his post and using StructureMap my self and the only place where I do any IoC-stuff is in my registry classes and some bootstrapping.</description> <content:encoded><![CDATA[<p>Agree! Also read his post and using StructureMap my self and the only place where I do any IoC-stuff is in my registry classes and some bootstrapping.</p> ]]></content:encoded> </item> </channel> </rss>
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced
Database Caching 2/21 queries in 0.011 seconds using disk: basic
Object Caching 590/591 objects using disk: basic
Content Delivery Network via Amazon Web Services: CloudFront: d18sni7re4ly7f.cloudfront.net

Served from: davybrion.com @ 2012-02-08 19:12:36 -->
