Skip to content

Commit

Permalink
Site updated at 2012-08-07 19:38:31 UTC
Browse files Browse the repository at this point in the history
  • Loading branch information
chriseldredge committed Aug 7, 2012
1 parent 208325b commit 4602eba
Show file tree
Hide file tree
Showing 12 changed files with 603 additions and 45 deletions.
8 changes: 4 additions & 4 deletions about/index.html
Expand Up @@ -172,6 +172,10 @@ <h3>Apache Maven</h3>
<h1>Recent Posts</h1>
<ul id="recent_posts">

<li class="post">
<a href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/">How The Motley Fool uses NuGet (part 1)</a>
</li>

<li class="post">
<a href="/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/">MSBuild, Visual Studio & NuGet Hackery</a>
</li>
Expand All @@ -188,10 +192,6 @@ <h1>Recent Posts</h1>
<a href="/blog/2012/05/08/Introducing-Linq-to-Lucene/">Introducing LINQ to Lucene</a>
</li>

<li class="post">
<a href="/blog/2012/04/19/Lucene-NumericField-Gotcha/">Lucene NumericField Gotcha</a>
</li>

</ul>
</section>

Expand Down
98 changes: 97 additions & 1 deletion atom.xml
Expand Up @@ -4,7 +4,7 @@
<title><![CDATA[Chris Eldredge]]></title>
<link href="http://chriseldredge.github.com/atom.xml" rel="self"/>
<link href="http://chriseldredge.github.com/"/>
<updated>2012-07-26T14:52:10-04:00</updated>
<updated>2012-08-07T15:36:01-04:00</updated>
<id>http://chriseldredge.github.com/</id>
<author>
<name><![CDATA[Chris Eldredge]]></name>
Expand All @@ -13,6 +13,102 @@
<generator uri="http://octopress.org/">Octopress</generator>


<entry>
<title type="html"><![CDATA[How The Motley Fool uses NuGet (part 1)]]></title>
<link href="http://chriseldredge.github.com/blog/2012/08/07/how-the-motley-fool-uses-nuget/"/>
<updated>2012-08-07T14:25:00-04:00</updated>
<id>http://chriseldredge.github.com/blog/2012/08/07/how-the-motley-fool-uses-nuget</id>
<content type="html"><![CDATA[<p>This post describes how we came to using binary package management. In the next part I&#8217;ll get into NuGet.</p>
<p>In the beginning, there was one repository and it held all the projects for The Motley Fool, and it was good.
There were around a dozen asp.net web projects, a smattering of service and console apps, and a bunch of class libraries
to hold shared code. There was one Solution (sln) to rule them all.</p>
<p>As time went on, we found that there are downsides to the one-giant-solution approach to .net development:</p>
<ul>
<li><a href="http://www.laputan.org/mud/">Big Ball of Mud</a></li>
<li>Slow builds</li>
<li>Tight coupling</li>
<li>Configuration hell</li>
<li>Hard to release different applications on different schedules</li>
</ul>
<p>Typically our larger applications would be split into several projects following a typical N-tier layered architecture:</p>
<ul>
<li>Web</li>
<li>Service</li>
<li>Domain</li>
<li>Data Access</li>
</ul>
<p>Despite our attempts to encapsulate data access and domain logic behind the service project, code ended up leaking out
to the point where domain projects were using types and methods from unrelated domain projects. Cats and dogs were
sleeping together.</p>
<p>Around this time Steven Bohlen presented a <a href="http://unhandled-exceptions.com/blog/index.php/2010/11/27/dc-altnet-presentationthats-a-wrap/">talk</a>
to the Washington DC Alt.NET User Group titled &#8220;Domain Driven Design Implementation Patterns in .NET&#8221;. While some of us
were already familiar with concepts of DDD, this talk lit a spark for us to try fixing our big ball of mud.</p>
<p>In late 2010 we started to make some changes. Instead of having one giant repository, shared code would be split out
into separate repositories. We also took this opportunity to introduce a new project organization and architecture.</p>
<p>We established one repository to hold utility code, broken into specific class libraries:</p>
<ul>
<li><tt>Fool.Abstractions</tt> - similar in spirit to System.Web.Abstractions; adds interfaces and wrappers to various FCL types that lack them</li>
<li><tt>Fool.Lang</tt> - similar in spirit to <a href="http://commons.apache.org/lang/">Jakarta Commons Lang</a>; adds general utility classes and methods not found elsewhere</li>
<li>Other projects that extend 3rd party class libraries to make them easier for us to work with in standardized ways.</li>
</ul>
<p>Then we established another repository to hold Domain Driven, er, Domains. For example, many of our applications and web sites deal with
stock market data, so one of our business domains is Quotes. In the Quotes Domain we have these projects:</p>
<ul>
<li><tt>Fool.Quotes</tt> - contains service interfaces and value types; serves as an API to the domain</li>
<li><tt>Fool.Quotes.Core</tt> - contains domain logic, models, and entities; serves as a private implementation</li>
<li><tt>Fool.Quotes.Web.Api</tt> - exposes Fool.Quotes interfaces over a RESTful web API</li>
</ul>
<p>The key to keeping our domains distinct and decoupled is to keep Core projects private. While Core is required at runtime,
it should never be referenced at compile time. To bridge the gap, we use Dependency Injection to provide concrete implementations.</p>
<p>Domains may depend on other domains provided that they consume each other through the API project. That way entities and business logic
are kept focused on their own concerns and don&#8217;t leak out to other problem areas where they don&#8217;t fit.</p>
<h2>Gluing It Together</h2>
<p>Having projects split into different repositories and different solutions meant that we couldn&#8217;t simply have one mega Solution
that includes everything. That&#8217;s by design, so good on us. But this introduces a problem in that we still need to reference code
from our utility projects and DDD projects in our applications. The first solution we came up with to handle this problem was
to use the <a href="http://msdn.microsoft.com/en-us/library/wkze6zky.aspx">AssemblyFolders</a> registry to have our libraries
appear in the <tt>Add Reference</tt> dialog. Then to solve the runtime dependency on our private Core assemblies, we install
those to the GAC so they can be loaded using reflection by our IoC container.</p>
<p>This approach worked fine, mostly. But we encountered some downsides after using it for a while:</p>
<ul>
<li>Need to have all library code checked out and built on each development machine</li>
<li>No built-in way to manage different versions of the same dependency</li>
<li><a href="http://www.sellsbrothers.com/Posts/Details/12503">GAC considered harmful</a></li>
<li>Hard to debug build errors and runtime errors</li>
</ul>
<p>Using Continuous Integration means we&#8217;re producing new builds dozens of times a day, so it isn&#8217;t practical for us to
manage different assembly versions for each build. Like most shops, we leave our assembly versions at 1.0.0.0 despite
injecting actual version information into the AssemblyInformationalVersion attribute.</p>
<p>In order to support parallel development, we needed to find a more flexible way of managing dependencies, and
at this point we started to look at binary package management.</p>
]]></content>
</entry>

<entry>
<title type="html"><![CDATA[MSBuild, Visual Studio & NuGet Hackery]]></title>
<link href="http://chriseldredge.github.com/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/"/>
Expand Down
8 changes: 4 additions & 4 deletions blog/2012/03/29/Getting-Started-With-Relinq/index.html
Expand Up @@ -207,6 +207,10 @@ <h2>The Bare Bones</h2>
<h1>Recent Posts</h1>
<ul id="recent_posts">

<li class="post">
<a href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/">How The Motley Fool uses NuGet (part 1)</a>
</li>

<li class="post">
<a href="/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/">MSBuild, Visual Studio & NuGet Hackery</a>
</li>
Expand All @@ -223,10 +227,6 @@ <h1>Recent Posts</h1>
<a href="/blog/2012/05/08/Introducing-Linq-to-Lucene/">Introducing LINQ to Lucene</a>
</li>

<li class="post">
<a href="/blog/2012/04/19/Lucene-NumericField-Gotcha/">Lucene NumericField Gotcha</a>
</li>

</ul>
</section>

Expand Down
8 changes: 4 additions & 4 deletions blog/2012/04/19/Lucene-NumericField-Gotcha/index.html
Expand Up @@ -172,6 +172,10 @@ <h1 class="entry-title">Lucene NumericField Gotcha</h1>
<h1>Recent Posts</h1>
<ul id="recent_posts">

<li class="post">
<a href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/">How The Motley Fool uses NuGet (part 1)</a>
</li>

<li class="post">
<a href="/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/">MSBuild, Visual Studio & NuGet Hackery</a>
</li>
Expand All @@ -188,10 +192,6 @@ <h1>Recent Posts</h1>
<a href="/blog/2012/05/08/Introducing-Linq-to-Lucene/">Introducing LINQ to Lucene</a>
</li>

<li class="post">
<a href="/blog/2012/04/19/Lucene-NumericField-Gotcha/">Lucene NumericField Gotcha</a>
</li>

</ul>
</section>

Expand Down
8 changes: 4 additions & 4 deletions blog/2012/05/08/Introducing-Linq-to-Lucene/index.html
Expand Up @@ -280,6 +280,10 @@ <h2>Conclusion</h2>
<h1>Recent Posts</h1>
<ul id="recent_posts">

<li class="post">
<a href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/">How The Motley Fool uses NuGet (part 1)</a>
</li>

<li class="post">
<a href="/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/">MSBuild, Visual Studio & NuGet Hackery</a>
</li>
Expand All @@ -296,10 +300,6 @@ <h1>Recent Posts</h1>
<a href="/blog/2012/05/08/Introducing-Linq-to-Lucene/">Introducing LINQ to Lucene</a>
</li>

<li class="post">
<a href="/blog/2012/04/19/Lucene-NumericField-Gotcha/">Lucene NumericField Gotcha</a>
</li>

</ul>
</section>

Expand Down
8 changes: 4 additions & 4 deletions blog/2012/07/03/Speeding-Up-NuGet-Server/index.html
Expand Up @@ -239,6 +239,10 @@ <h2>Conclusion</h2>
<h1>Recent Posts</h1>
<ul id="recent_posts">

<li class="post">
<a href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/">How The Motley Fool uses NuGet (part 1)</a>
</li>

<li class="post">
<a href="/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/">MSBuild, Visual Studio & NuGet Hackery</a>
</li>
Expand All @@ -255,10 +259,6 @@ <h1>Recent Posts</h1>
<a href="/blog/2012/05/08/Introducing-Linq-to-Lucene/">Introducing LINQ to Lucene</a>
</li>

<li class="post">
<a href="/blog/2012/04/19/Lucene-NumericField-Gotcha/">Lucene NumericField Gotcha</a>
</li>

</ul>
</section>

Expand Down
Expand Up @@ -290,6 +290,10 @@ <h2>Eventual Consistency</h2>
<h1>Recent Posts</h1>
<ul id="recent_posts">

<li class="post">
<a href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/">How The Motley Fool uses NuGet (part 1)</a>
</li>

<li class="post">
<a href="/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/">MSBuild, Visual Studio & NuGet Hackery</a>
</li>
Expand All @@ -306,10 +310,6 @@ <h1>Recent Posts</h1>
<a href="/blog/2012/05/08/Introducing-Linq-to-Lucene/">Introducing LINQ to Lucene</a>
</li>

<li class="post">
<a href="/blog/2012/04/19/Lucene-NumericField-Gotcha/">Lucene NumericField Gotcha</a>
</li>

</ul>
</section>

Expand Down
10 changes: 6 additions & 4 deletions blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/index.html
Expand Up @@ -467,6 +467,8 @@ <h1 class="entry-title">MSBuild, Visual Studio & NuGet Hackery</h1>
<a class="basic-alignment left" href="/blog/2012/07/24/Unit-of-Work-and-Eventual-Consistency/" title="Previous Post: Unit of Work & Eventual Consistency">&laquo; Unit of Work & Eventual Consistency</a>


<a class="basic-alignment right" href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/" title="Next Post: How The Motley Fool uses NuGet (part 1)">How The Motley Fool uses NuGet (part 1) &raquo;</a>

</p>
</footer>
</article>
Expand All @@ -479,6 +481,10 @@ <h1 class="entry-title">MSBuild, Visual Studio & NuGet Hackery</h1>
<h1>Recent Posts</h1>
<ul id="recent_posts">

<li class="post">
<a href="/blog/2012/08/07/how-the-motley-fool-uses-nuget/">How The Motley Fool uses NuGet (part 1)</a>
</li>

<li class="post">
<a href="/blog/2012/07/26/MSBuild-NuGet-Visual-Studio-Hackery/">MSBuild, Visual Studio & NuGet Hackery</a>
</li>
Expand All @@ -495,10 +501,6 @@ <h1>Recent Posts</h1>
<a href="/blog/2012/05/08/Introducing-Linq-to-Lucene/">Introducing LINQ to Lucene</a>
</li>

<li class="post">
<a href="/blog/2012/04/19/Lucene-NumericField-Gotcha/">Lucene NumericField Gotcha</a>
</li>

</ul>
</section>

Expand Down

0 comments on commit 4602eba

Please sign in to comment.