<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Making the Complex Simple &#187; Tools</title>
	<atom:link href="http://simpleprogrammer.com/category/tools/feed/" rel="self" type="application/rss+xml" />
	<link>http://simpleprogrammer.com</link>
	<description>Software Development from John Sonmez&#039;s Perspective</description>
	<lastBuildDate>Tue, 07 Feb 2012 17:47:46 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='simpleprogrammer.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Making the Complex Simple &#187; Tools</title>
		<link>http://simpleprogrammer.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://simpleprogrammer.com/osd.xml" title="Making the Complex Simple" />
	<atom:link rel='hub' href='http://simpleprogrammer.com/?pushpress=hub'/>
		<item>
		<title>Getting Up to BAT: Picking a Browser Automation Tool</title>
		<link>http://simpleprogrammer.com/2011/03/06/getting-up-to-bat-picking-a-browser-automation-tool/</link>
		<comments>http://simpleprogrammer.com/2011/03/06/getting-up-to-bat-picking-a-browser-automation-tool/#comments</comments>
		<pubDate>Mon, 07 Mar 2011 03:00:30 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Automation]]></category>
		<category><![CDATA[BAT]]></category>
		<category><![CDATA[Functional]]></category>
		<category><![CDATA[Testing]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/?p=1267</guid>
		<description><![CDATA[Now that you’ve gotten an “Automation Lead” for your BAT (Black-box Automated Testing,) it&#8217;s time to make a very important decision. It is time to pick the browser automation tool you are going to use for driving your automation efforts. Before we can build an automation framework, we need a basic set of tools to [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1267&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Now that you’ve gotten an “Automation Lead” for your BAT (Black-box Automated Testing,) it&#8217;s time to make a very important decision.</p>
<p>It is time to pick the browser automation tool you are going to use for driving your automation efforts.</p>
<p>Before we can build an automation framework, we need a basic set of tools to build it on.&#160; We want our automation framework to be tailored to our application under test specifically.&#160; Our automation framework will act like a Domain Specific Language (DSL) for testing our application, but we need to build that automation framework on top of something.</p>
<h2>What is a browser automation tool?</h2>
<p>It is essentially what we will use to drive the web browser.</p>
<p><a href="http://complextosimple.files.wordpress.com/2011/03/older_driver.jpg"><img style="background-image:none;padding-left:0;padding-right:0;display:inline;padding-top:0;border-width:0;" title="BC-WV--BC-PRI--Older Drivers--Eighty-seven-year-old Dorothy Wulfers, who learned to drive a Model T Ford at age 15, prepares to pull out of her parking space Friday, June 4, 2004 in Morgantown, WV. Wulfers said only her and God will decide when she stops driving. (AP PHOTO/DALE SPARKS)" border="0" alt="BC-WV--BC-PRI--Older Drivers--Eighty-seven-year-old Dorothy Wulfers, who learned to drive a Model T Ford at age 15, prepares to pull out of her parking space Friday, June 4, 2004 in Morgantown, WV. Wulfers said only her and God will decide when she stops driving. (AP PHOTO/DALE SPARKS)" src="http://complextosimple.files.wordpress.com/2011/03/older_driver_thumb.jpg?w=491&#038;h=325" width="491" height="325" /></a></p>
<p>We need to pick a tool or framework that will easily allow us to interact with the web browser so we don’t have to write that code ourselves.</p>
<p>We will need to be able to click buttons, enter text, select drop downs, and check values on web pages.</p>
<p>Some of the things we will want to consider when choosing a browser automation tool include:</p>
<ul>
<li>Language we can use with the driver </li>
<li>Browsers it supports </li>
<li>How we interact with the browser (do we use XPath, JQuery, or some other mechanism) </li>
<li>If we can access and manipulate everything we need to be able to in the browser </li>
<li>Speed of execution </li>
<li>Ability to execute in parallel </li>
<li>Support and future development </li>
</ul>
<p>Let’s take a quick look at each of these considerations.</p>
<p><strong>What language can we use?</strong></p>
<p>This is an important consideration because you will want to be able to utilize your other programming resources to help with building an automation framework and to eventually create automation tests.</p>
<p>If you pick a browser driver that supports a language your regular programmers don’t like, or don’t know, you may not end up with their support, and you are definitely going to want their support.</p>
<p><strong>What browsers does it support?</strong></p>
<p>This is a tricky topic to discuss.&#160; It might seem that a browser automation tool would need to support all of the browsers your application supports, but that is not really true.</p>
<p>You really have to think about what your goal is with your BATs.&#160; I could certainly devote a whole blog post to this topic, but I will try and summarize my main point here.</p>
<p>BATs should be designed to test functionality of the application, not to test compatibility.&#160; (At least most of your BATs should be, although you might have some that are specifically for compatibility.)&#160; With that goal in mind, a browser driver supporting each and every browser your application supports is not really necessary.</p>
<p>You do need to consider that the browser automation tool should support at least one of your supported browsers, preferably the main one.</p>
<p><strong>How do we interact with the browser?</strong></p>
<p>There are several different APIs which are used to communicate with the web browser that are employed by various different browser drivers.</p>
<p>Some tools have APIs that are very low level and allow you to very easily manipulate objects in the web browser while others are at a much higher level and rely more on your understanding of the brower’s DOM.</p>
<p>For example, one API might expose elements on a web page by their actual element name and let you interact with them directly.</p>
<p><em>browser.Button(Find.ByName(“submitButton”)).Click();</em></p>
<p>vs</p>
<p><em>instance.click(“submitButton”);</em></p>
<p>In the first example, the API is aware of element types like buttons.&#160; In the second example, the API is more generic and will send a “click” to an element with the ID value you specify.</p>
<p>You’ll have to decide how important the ease of use is to your project at this level.&#160; There are some tradeoffs to consider here.</p>
<p>The lower level the API is, the easier it will be to use, but the more dependent you will be on that API and the more language specific that API will be.</p>
<p>The higher level the API is, the harder it will be to use, but it will free you from depending so much on the API, because you will be interacting more directly with the browser’s DOM.</p>
<p>I prefer lower level APIs because I find that it is much easier to write the framework code on top of these.</p>
<p>You will also want to consider here the skill levels of the programmers who will be creating the framework.&#160; If your API is lower level, native language skills are more important.&#160; If it is higher level, DOM and HTML, and perhaps Javascript skills, are more important.</p>
<p><strong>Can we access what we need?</strong></p>
<p>If your application makes use of Javascript pop-up dialogs and your browser automation tool doesn’t give you a way to interact with them, you don’t want to find this out when you have already invested significantly into your automation framework.</p>
<p>Different automation frameworks support different features of browser; not all of them will allow you to interact with every single browser feature that exists.&#160; As new features are introduced, you could also get stuck with a tool that is no longer being maintained and doesn’t add support for the new features.</p>
<p>You will want to consider things like how much your application uses AJAX or JQuery.&#160; You will want to select a browser automation tool which would make it easy to interact with AJAX calls if your application relies on them heavily.</p>
<p><strong>Speed of execution</strong></p>
<p>Not all browser automation tools are the same in execution speed either.</p>
<p>This may not be important to you, depending on how you address the issue of concurrency, but you should at least consider that if you have a large number of automated tests, a small difference in execution speed can result in a large difference in total time to run the tests.</p>
<p>The faster the automated tests can be run, the more valuable they are.&#160; I won’t get into the details here but there are many reason why this is true.</p>
<p>Also influencing the speed in which you can run your tests will be if you automation tool choice requires you to put pauses into the test to wait for the browser instead of responding to events that occur in the browser.</p>
<p><strong>Ability to execute in parallel</strong></p>
<p>This consideration will depend greatly on the volume of and speed in which your tests can execute.</p>
<p>At some time (sooner than you think) you will likely get to the point where you can no longer run all of your automated tests in 24 hours.&#160; Perhaps even before this point, you will want to consider running your BATs in parallel to reduce the total time to execute the tests.</p>
<p>Some automation tools have built-in support and others will require you to build your own way to do this.&#160; It is good to at least have an idea of how you are going to achieve parallel execution when considering what browser automation tool to use.</p>
<p><strong>Support and future development</strong></p>
<p>We are in a pretty rapid pace of browser development.&#160; Many things in the web browser world are changing much more rapidly than ever before.&#160; Tools to automate the browser must also change or you could end up in a very bad place.</p>
<p>If your application is going to take advantage of the latest browsers and browser features, you should make sure the automation tool you choose is in active development.</p>
<p>There is nothing worse than investing into an open-source project and then having that project die, resulting in you having to rip it out to replace it with another library.</p>
<p>You can always design your automation framework to be abstracted away as much as possible from the underlying browser driver, but that will be extra work, so consider this point carefully.</p>
<h2>Name names sir!</h2>
<p>Nope, I’m not going to do it.</p>
<p>I’m not going to tell you to use Watin or Watij or Selenium or WebAii or any other browser driver.&#160; I don’t want to put the focus on the tool, since the real focus will be building the automation framework on top of the tool you use to drive the browser.</p>
<p>I would suggest that you try writing a few simple tests in each of the major browser drivers so that you can get a good feel of what the API is like and how it will work with your application.</p>
<p>I will say that I have used most of the major choices out there and there really is no clear winner in my mind.&#160; It really is going to depend on what your environment is like and what kind of application you are testing.</p>
<p>I would also recommend picking a browser driver and sticking to it.&#160; I’ve tried in the past to abstract away the browser driver from the automation framework and while it is possible, it can become quite messy and add quite a bit of overhead to your project.</p>
<p>My only other hints would be to not put too much emphasis on supporting multiple browsers or on using recording tools.&#160; Neither of these things will benefit you much in the long run because you will find that you will not want to try and run all of your BATs on each browser. Recording tools will not be nearly as effective as writing your own custom framework (which I will talk about in my next post.)</p>
<h6>As always, you can subscribe to this <a href="http://feeds.feedburner.com/MakingTheComplexSimple">RSS feed</a> to follow my posts on Making the Complex Simple.&#160; Feel free to check out <a href="http://elegantcode.com/">ElegantCode.com</a> where I post about the topic of writing elegant code about once a week.&#160; Also, you can follow me on twitter <a href="http://twitter.com/jsonmez">here</a>.</h6>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/1267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/1267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/1267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/1267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/1267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/1267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/1267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/1267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/1267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/1267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/1267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/1267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/1267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/1267/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1267&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2011/03/06/getting-up-to-bat-picking-a-browser-automation-tool/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2011/03/older_driver_thumb.jpg" medium="image">
			<media:title type="html">BC-WV--BC-PRI--Older Drivers--Eighty-seven-year-old Dorothy Wulfers, who learned to drive a Model T Ford at age 15, prepares to pull out of her parking space Friday, June 4, 2004 in Morgantown, WV. Wulfers said only her and God will decide when she stops driving. (AP PHOTO/DALE SPARKS)</media:title>
		</media:content>
	</item>
		<item>
		<title>Living Dangerously: Refactoring without a Safety Net</title>
		<link>http://simpleprogrammer.com/2010/10/01/living-dangerously-refactoring-without-a-safety-net/</link>
		<comments>http://simpleprogrammer.com/2010/10/01/living-dangerously-refactoring-without-a-safety-net/#comments</comments>
		<pubDate>Fri, 01 Oct 2010 16:53:49 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[IDEs]]></category>
		<category><![CDATA[Refactoring]]></category>
		<category><![CDATA[Testing]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Unit Testing]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/2010/10/01/living-dangerously-refactoring-without-a-safety-net/</guid>
		<description><![CDATA[It’s usually a good idea to have unit tests in place before attempting to refactor some code. I’m going to go against the grain here today though and tell you that it is not always required. Many times code that should be refactored doesn’t get refactored due to the myth that you must always have [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1124&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>It’s usually a good idea to have unit tests in place before attempting to refactor some code.</p>
<p>I’m going to go against the grain here today though and tell you that it is not always required.</p>
<p>Many times code that should be refactored doesn’t get refactored due to the myth that you must always have unit tests in place before refactoring.&#160; </p>
<p>In many cases the same code stays unimproved over many revisions because the effort of creating the unit tests needed to refactor it is too high.</p>
<p>I think this is a shame because it is not always necessary to have unit tests in place before refactoring.</p>
<p><a href="http://complextosimple.files.wordpress.com/2010/10/manonwire3.jpg"><img style="background-image:none;border-bottom:0;border-left:0;padding-left:0;padding-right:0;display:inline;border-top:0;border-right:0;padding-top:0;" title="Philippe Petit" border="0" alt="Philippe Petit" src="http://complextosimple.files.wordpress.com/2010/10/manonwire3_thumb.jpg?w=503&#038;h=310" width="503" height="310" /></a></p>
<h2>Forgoing the safety net</h2>
<p>If you go to the circus, you will notice that some acts always have a safety net below because the stunt is so dangerous that there is always a chance of failure.&#160; </p>
<p>You’ll also notice that some acts don’t have a safety net, because even though there is risk of danger, it is extremely small, because of the training of the performers.</p>
<p>Today I’m going to talk about some of the instances where you don’t necessarily need to have a safety net in place before doing the refactor.</p>
<p><strong>Automatic refactorings</strong></p>
<p>This is an easy one that should be fairly obvious.&#160; If you use a modern IDE like Visual Studio, Eclipse, or IntelliJ, you will no doubt have seen what I call “right-click refactor” options.</p>
<p>Any of these automatic refactors are pretty much safe to do anytime without any worry of changing functionality.&#160; These kinds of automated refactors simply apply an algorithm to the code to produce the desired result and in almost all cases do not change functionality.</p>
<p>These refactoring tools you can trust because there is not a chance for human error.</p>
<p>Any time you have the option of using an automatic refactoring, do it!&#160; It just makes sense, even if you have unit tests.&#160; I am always surprised when I pair up with someone and they are manually doing refactorings like “extract method” or “rename.”</p>
<p>Most of the time everything you want to do to some code can be found in one of the automatic refactoring menus.</p>
<p><strong>Small step refactors</strong></p>
<p>While not as safe as automatic refactors, if you have a refactor that is a very small step, there is a much higher chance your brain can understand it and prevent any side effects.</p>
<p>A good example of this would be my post on <a href="http://simpleprogrammer.com/2010/01/18/how-to-refactor-removal-of-conditions/">refactoring the removal of conditions</a>.</p>
<p>The general idea is that if you can make very simple small steps that are so trivial that there is almost no chance of mistake, then you can end up making a big refactor as the net effect of those little changes.</p>
<p>This one is a judgment call.&#160; It is up to you to decide if what you are doing is a small step or not.&#160; </p>
<p>I do find that if I want to do a refactor that isn’t a small step refactor, I can usually break it down into a series of small steps that I can feel pretty confident in.&#160; (Most of the time these will be automated refactors anyway.)</p>
<p><strong>Turning methods into classes</strong></p>
<p>I hate huge classes.&#160; Many times everyone is afraid to take stuff out of a huge class, because it is likely to break and it would take years to write unit tests for that class.</p>
<p>One simple step, which greatly improves the architecture and lets you eventually create unit tests, is to take a big ol’ chunk of that class, move it to a new class, and keep all the logic in there exactly how it is.</p>
<p>It’s not always totally clean, you might have to pass in some dependencies to the new method or new class constructor, but if you can do it, it can be an easy and safe refactor that will allow you to write unit tests for the new class.</p>
<p>Obviously this one is slightly more dangerous than the other two I have mentioned before, but it also is one that has a huge “bang for your buck.”</p>
<p><strong>Unit tests, or test code themselves</strong></p>
<p>Another obvious one.&#160; Unless you are going to write meta-unit tests, you are going to have to live a little dangerously on this one.&#160; You really have no choice.</p>
<p>I think everyone will agree that refactoring unit tests is important though.&#160;&#160; So, how come no one is afraid to refactor unit tests?</p>
<p>I only include this example to make the point that you shouldn’t be so scared to refactor code without having unit tests.&#160; You probably do it pretty frequently with your unit tests.</p>
<h2>I’m not advocating recklessness here</h2>
<p>I know some of you are freaking out right now.</p>
<p>Be assured, my message is not to haphazardly refactor code without unit tests.&#160; My message is simply to use temperance when considering a refactor.</p>
<p>Don’t forgo a refactor just because you are following a hard and fast rule that you need unit tests first.</p>
<p>Instead, I am suggesting that some refactorings are so trivial and safe that if it comes between the choice of leaving the code as it is because unit testing will take too long, or refactoring the code without the safety net, don’t be a… umm… <strike>pu…</strike> wimp.&#160; Use your brain!</p>
<h2></h2>
<h2>Things that will bite you hard</h2>
<p>There are a few things to watch out for, even with the automatic refactorings.&#160; Even those can fail and cause all kinds of problems for you.</p>
<p>Most of these issues won’t exist in your code base unless you are doing some crazy funky stuff.</p>
<ul>
<li>If you’re using <em>dynamic </em>in C#, or some kind of PInvoke, <em>unsafe </em>(pointer manipulation) or COM interop, all bets are off on things like rename. </li>
<li>Reflection.&#160; Watch out for this one.&#160; This can really kick you in the gonads.&#160; If you are using reflection, changing a method name or a type could cause a failure that is only going to be seen at runtime. </li>
<li>Code generation.&#160; Watch out for this one also.&#160; If generated code is depending on a particular implementation of some functionality in your system, refactoring tools won’t have any idea. </li>
<li>External published interfaces.&#160; This goes without saying, but it is so important that I will mention it here.&#160; Watch out for other people using your published APIs.&#160; Whether you have unit tests or not, refactoring published APIs can cause you a whole bunch of nightmares. </li>
</ul>
<p>This list isn’t to scare you off from refactoring, but if you know any of the things in this list are in your code base, check before you do the refactor.&#160; Make sure that the code you are refactoring won’t be affected by these kinds of things.</p>
<h6><strong>As always, you can subscribe to this </strong><a href="http://feeds.feedburner.com/MakingTheComplexSimple"><strong>RSS feed</strong></a><strong> to follow my posts on Making the Complex Simple.&#160; Feel free to check out </strong><a href="http://elegantcode.com/"><strong>ElegantCode.com</strong></a><strong> where I post about the topic of writing elegant code about once a week.&#160; Also, you can follow me on twitter </strong><a href="http://twitter.com/jsonmez"><strong>here</strong></a><strong>.</strong></h6>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/1124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/1124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/1124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/1124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/1124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/1124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/1124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/1124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/1124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/1124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/1124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/1124/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/1124/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/1124/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1124&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/10/01/living-dangerously-refactoring-without-a-safety-net/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/10/manonwire3_thumb.jpg" medium="image">
			<media:title type="html">Philippe Petit</media:title>
		</media:content>
	</item>
		<item>
		<title>When to Build the Sawhorse</title>
		<link>http://simpleprogrammer.com/2010/08/31/when-to-build-the-sawhorse/</link>
		<comments>http://simpleprogrammer.com/2010/08/31/when-to-build-the-sawhorse/#comments</comments>
		<pubDate>Tue, 31 Aug 2010 20:47:47 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Architecture]]></category>
		<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Frameworks]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/?p=1077</guid>
		<description><![CDATA[I love talking about tools and automating.  I’ve written about having a dedicated developer tools team, and what you should automate. This time I want to talk about choosing between what I call vertical difficulty and horizontal difficulty. Horizontal difficulty Horizontal difficulty is difficulty that is associated with just doing the work as the current [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1077&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I love talking about tools and automating.  I’ve written about having a <a href="http://simpleprogrammer.com/2009/12/03/dedicated-developer-tools-teams/">dedicated developer tools team</a>, and <a href="http://simpleprogrammer.com/2010/03/22/what-to-automate/">what you should automate.</a></p>
<p>This time I want to talk about choosing between what I call vertical difficulty and horizontal difficulty.</p>
<h2>Horizontal difficulty</h2>
<p>Horizontal difficulty is difficulty that is associated with just doing the work as the current structure or tooling exists at that moment.</p>
<p>Consider the problem of moving a washer and dryer.  If you have no tools and you just have to lift it, there is some horizontal difficulty involved.</p>
<p>In programming terms horizontal difficulty might look like writing a complicated SQL statement with multiple conditional joins because the data is all over the place.  Or writing a web page without using a framework, because your application doesn’t have one.</p>
<h2>Vertical difficulty</h2>
<p>This is the difficulty associated with mainly building tools or frameworks.  It is the kind of difficulty that exists in simplifying a problem by going a layer up to “meta” solve the problem.</p>
<p>If you are familiar with Calculus in mathematics, Calculus is an example of what I would call vertical difficulty.  Many mathematical problems are solved through the use of Calculus by taking the level up one higher and solving the problem there.</p>
<p>To keep with the same example of moving a washer and dryer, the vertical difficulty would be building a cart or dolly to move the washer and dryer.  <strong>An important point here, which I will make again, is that in many cases the amount of raw effort required to build a dolly or cart, or even to figure out a way to procure one, will be equivalent to the effort required to move the washer and dryer.</strong></p>
<p>In terms of code, vertical difficulty might be creating an error handling framework, creating a custom control for your web page, using views to simplify SQL data access, or even to repartition and move data to make a better model.</p>
<p><strong>Where horizontal difficulty represents brute force, vertical difficulty represents mental fatigue.</strong></p>
<h2>What about that sawhorse?</h2>
<p><a href="http://complextosimple.files.wordpress.com/2010/08/sawhorse.jpg"><img style="background-image:none;padding-left:0;padding-right:0;display:inline;padding-top:0;border:0;" title="sawhorse" src="http://complextosimple.files.wordpress.com/2010/08/sawhorse_thumb.jpg?w=478&#038;h=470" border="0" alt="sawhorse" width="478" height="470" /></a></p>
<p>If you are familiar with woodworking or construction, you will have no doubt seen a sawhorse.  A sawhorse is platform that can be used to hold something so you can cut it.</p>
<p>Sawhorses are usually constructed on the jobsite before any other work begins.</p>
<p>Why?</p>
<p>Well, have you ever tried to hold a piece of wood and cut it straight?  How about searching for different objects in your garage that you can prop the wood on so that you can get it high enough above the ground that you can put a saw through it?</p>
<p>Experienced craftsman build the sawhorse first.  They don’t start cutting pieces of wood and then build the sawhorse.  An experienced craftsman knows that by building the sawhorse first, he will save time by not wasting time on each cut.  His cuts will be more accurate and he might just be able to bring that sawhorse to his next job.</p>
<p><strong>Every time you sit down to solve a programming problem, you should think about whether or not you should be building a sawhorse first.</strong></p>
<h2>Are you saying always build the sawhorse?</h2>
<p>No, not at all.  If you are going to cut one piece of wood, do not build a sawhorse.  If you are going to cut two pieces of wood, don’t do it either.  I won’t tell you how many pieces of wood that it will take to pay off, but I will tell you 3 things.</p>
<ol>
<li>It doesn’t take many cuts for a sawhorse to pay back the time it takes to build it.</li>
<li>The more sawhorses you build, the faster you get at building them.</li>
<li>You are always wrong about how many cuts you are going to make.  When you estimate 3 it might end up being 20.</li>
</ol>
<h2>Vertical vs horizontal difficulty</h2>
<p>It is very important to weigh out the pros and cons of each before making a decision which way to go.  I am of course going to try and lean you towards choosing vertical difficulty over horizontal most of the time, but ultimately it is up to you.</p>
<p>Let&#8217;s look quickly at some pros and cons for each (very generalized.)</p>
<p><strong>Horizontal</strong></p>
<p><em>Pros:</em></p>
<ul>
<li>Can follow a well ridden path.  Usually there is an example of how to solve the problem already.  (Someone has done it before.)</li>
<li>Less thinking, you just follow the approach and go, after some amount of hours you will be done.  (Consider copy and pasting each cell of an html table to a spreadsheet, vs writing a program to parse it.)</li>
<li>Less risk, you are very likely to get to your destination with minimal problems.</li>
</ul>
<p><em>Cons:</em></p>
<ul>
<li>Boring.  This is not really going to challenge that programmer blog reading brain of yours.</li>
<li>You or someone else will be probably doing the same thing again.  Solving the problem once, only helps to beat down the weeds in the trail, but it doesn’t make it shorter.</li>
<li>You might be building on top of a bad foundation.  By adding one-offs as individual solutions to the problem, the general case can become more hidden.  (If you want to solve the problem better later, you make it harder each time you solve it the horizontal way.)</li>
</ul>
<p><strong>Vertical</strong></p>
<p><em>Pros:</em></p>
<ul>
<li>Simplified working space.  Once you solve a problem a vertical way, you end up building an abstraction that makes the problem seem easier at the lower level.  (Think about connectors on your motherboard vs individually connecting each wire.)</li>
<li>Reuse.  Many times when you solve a problem the vertical way, you can reuse that solution to solve future problems in almost no time at all.  (Build connector couplings for wires and next time you can just snap them together.)</li>
<li>Bigger picture understanding of the system.  When you take the time to go up a level and solve a problem, you can see the bigger picture better and can understand the system as a whole better.  This will lead to better solutions and fewer mistakes later.</li>
<li>You are developing a skill that is multi-purpose and can be applied more widely than a very specific skill which might be developed in a horizontal solution.  (Thinking about working at McDonald&#8217;s vs running several McDonald&#8217;s.)</li>
<li>Clean.  Usually you will end up with less code.  Less code means less bugs.  Changes happen in one place instead of 50.</li>
</ul>
<p><em>Cons:</em></p>
<ul>
<li>It can be hard mentally.  It can require a higher level of skill.  Not everyone who can solve the problem horizontally can solve it vertically.</li>
<li>Higher risk.  If you mess up along the path of the horizontal solution, you can probably go back a few steps and fix it.  If you mess up along the vertical solution, you might have to scrap it and start over.  (Building a house vs building a microchip.)</li>
</ul>
<p>Okay, that’s it.</p>
<p>Wait what?  Did you say I forgot the biggest con of Vertical difficulty?</p>
<p>No, I didn’t.  I left it out on purpose.</p>
<p>Vertical difficulty does not always mean it takes more time.  Sometimes it is actually faster to do the vertical difficulty path even when “cutting one piece of wood.”</p>
<p>I have seen Perl programmers and gurus parse through text or whip up a meta-solution that can solve a problem faster than I could have done it manually once.  And they have a script around to do it again.</p>
<p>I have seen VI wizards edit the heck out of a text file much faster than I could point and click to do the same thing.</p>
<p>Scripting languages and editors like VI are designed for solving vertical problems.  When you are using VI and issuing commands to edit text, you are solving a vertical problem.  You are operating at a high level to edit a text file.</p>
<p>Many times you will find that the vertical solution is not only faster the first time you implement it, but it also makes the solution almost instant the next time around.</p>
<h6>As always, you can subscribe to this <a href="http://feeds.feedburner.com/MakingTheComplexSimple">RSS feed</a> to follow my posts on Making the Complex Simple.  Feel free to check out <a href="http://elegantcode.com/">ElegantCode.com</a> where I post about the topic of writing elegant code about once a week.  Also, you can follow me on twitter <a href="http://twitter.com/jsonmez">here</a>.</h6>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/1077/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/1077/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/1077/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/1077/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/1077/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/1077/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/1077/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/1077/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/1077/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/1077/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/1077/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/1077/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/1077/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/1077/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1077&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/08/31/when-to-build-the-sawhorse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/08/sawhorse_thumb.jpg" medium="image">
			<media:title type="html">sawhorse</media:title>
		</media:content>
	</item>
		<item>
		<title>Why The IDE Has Failed Us</title>
		<link>http://simpleprogrammer.com/2010/08/03/why-the-ide-has-failed-us/</link>
		<comments>http://simpleprogrammer.com/2010/08/03/why-the-ide-has-failed-us/#comments</comments>
		<pubDate>Tue, 03 Aug 2010 15:20:21 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[IDEs]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/2010/08/03/why-the-ide-has-failed-us/</guid>
		<description><![CDATA[There is so much talk lately about using VI instead of Visual Studio, or VI in general instead of whatever IDE you normally use. If you never had the fortune of being introduced to VI, it is basically a bare bones text editor designed to be used without a mouse and focused more on manipulating [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1033&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>There is so much talk lately about using VI instead of Visual Studio, or VI in general instead of whatever IDE you normally use.</p>
<p>If you never had the fortune of being introduced to VI, it is basically a bare bones text editor designed to be used without a mouse and focused more on manipulating text than creating it.&#160; VI is on just about every platform you can think of and will be for the foreseeable future.</p>
<p>It is not my point today to bash VI.&#160; VI is a great text editing tool that can make you a wiz at slinging lines and words around your files.&#160; VI is the evolution of text editing because when you are using VI you are actually programming your text.</p>
<p><a href="http://complextosimple.files.wordpress.com/2010/08/microsoft_visual_basic_for_msdos_professional_edition_version1-00.png"><img style="display:inline;border-width:0;" title="Microsoft_Visual_Basic_for_MS-DOS_(Professional_Edition_Version1.00)" border="0" alt="Microsoft_Visual_Basic_for_MS-DOS_(Professional_Edition_Version1.00)" src="http://complextosimple.files.wordpress.com/2010/08/microsoft_visual_basic_for_msdos_professional_edition_version1-00_thumb.png?w=507&#038;h=283" width="507" height="283" /></a> </p>
<h2>The problem with IDEs</h2>
<p>Basically there are two problems with IDEs.&#160; One I think is a valid complaint, the other appeals to engineers wanton desire to be simple, pure and take things apart.</p>
<p><strong>The Bloat</strong></p>
<p>The first problem with modern IDEs is the bloat.&#160; The IDEs are big beasts that take up lots of memory, are fairly slow to load and tend to have so many bells and whistles that they feel messy and clunky.</p>
<p>As I write this part of me thinks “what’s the big deal?”&#160; I’ve got a pretty fast machine, it can run VS2010 pretty well.&#160; But, there is something that doesn’t sit right for me and I am sure for other developers.&#160; The IDE should feel clean, but it doesn’t.</p>
<p>I’m not sure if I can completely identify why IDEs have suddenly gone sour in our mouths.&#160; Perhaps part of the bloat problem is that the IDE has kind of become a swiss army knife instead of a focused tool.</p>
<p>Strangely enough, I think part of the problem might be tools like Resharper, that are helping us a little too much.&#160; The tool is so good that sometimes you wonder what life would be like without all those little hints and the IDE doing so many things for you.&#160; Perhaps sometimes you feel like you are “cheating.”</p>
<p><strong>The Imagined</strong></p>
<p>Then there are the imagined problems with IDEs.&#160; The ones that don’t really have any justification, but some of the “cool kids” like to talk about on their blogs.</p>
<p>If I can summarize what I gleaned from the argument here, I would say it basically is… IDEs that give me auto-complete, intellisense, and visual designers rot my brain.&#160; To really program I should be able to write code without the help of an IDE.</p>
<p>I couldn’t agree more with that statement.&#160; </p>
<p>As a matter of fact, for that reason I don’t use electric toothbrushes, because it is not really brushing my teeth.&#160; </p>
<p>I also abhor graphing calculators, it’s not really calculus unless you are cranking it out by hand.&#160; </p>
<p>Email? Psha, everyone knows the pure way to communicate is by registered mail typed from a typewriter.</p>
<p>Oh, and don’t get me started on those GPS things.&#160; You are not really navigating if you aren’t using a map and a compass, seriously.</p>
<p>Sorry for all the sarcasm, but I hope you get my point.</p>
<h2></h2>
<h2>What is the solution then?</h2>
<p>Is it to abandon the IDE and jump over to VI and notepad to edit our files so we don’t “rot our brain?”</p>
<p>I know that is the popular stance among the best and brightest right now, but sometimes the best and brightest are wrong.&#160; Sometimes they are so bestest and so brightest that they can navigate with a map and a compass better than you or I can with a GPS.</p>
<p>I think the solution is to bring more VI-ness to IDEs.&#160; The good thing about jumping to VI is that you can sling text around like nobody’s business.&#160; The bad thing about jumping to VI is that you are forgoing some of the most useful productivity tools in dealing with APIs and libraries.</p>
<p>Why can’t we take the good VI-ness and put it into Visual Studio?&#160; Looks like someone already has (<a href="http://www.viemu.com/">ViEmu</a>.)</p>
<p>The other part of the problem is the bloat.&#160; Honestly, I think Eclipse deals with this fairly well, by making everything modular.&#160; Unfortunately, some of the modules look plain ugly and don’t integrate well into Eclipse, but with Visual Studio you have to pull out a swiss army knife with 50 gadgets on it when you are just trying to eat some beans with a fork.</p>
<p>The answer is modularization and perhaps some competition for Visual Studio and some of the other IDEs that are a bit bloaty.&#160; Perhaps we need an IDE that is built up from a VI or Emacs heritage?</p>
<p>I know for sure the solution is not to throw the baby out with the bathwater.&#160; IDEs have made some truly amazing advancements that help bring the level of abstraction of software development to a much higher level.&#160; </p>
<p>Features like intellisense have made it easier then ever to hit the ground running with a new API like never before.</p>
<p>Automatic refactoring tools built into IDEs, and with add-ons like Resharper, have made refactoring code so much easier and so much more accessible.</p>
<p>Ctrl+Click goto definition and backwards / forwards navigation to jump to parts of the code greatly increase productivity.</p>
<p>I don’t need to go into all of the features of modern IDEs to make the point that there is value there and a large amount of it.</p>
<p>So before you abandon the IDE, consider strongly why exactly the IDE has failed us, and consider whether jumping to VI is really the best solution to the problem.&#160; If you don’t know what problem you are trying to solve by jumping to VI, you might just be following the “cool kids” and drinking their “cool aid.”</p>
<h6>As always, you can subscribe to this <a href="http://feeds.feedburner.com/MakingTheComplexSimple">RSS feed</a> to follow my posts on Making the Complex Simple.&#160; Feel free to check out <a href="http://elegantcode.com/">ElegantCode.com</a> where I post about the topic of writing elegant code about once a week.&#160; Also, you can follow me on twitter <a href="http://twitter.com/jsonmez">here</a>.</h6>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/1033/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/1033/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/1033/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/1033/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/1033/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/1033/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/1033/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/1033/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/1033/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/1033/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/1033/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/1033/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/1033/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/1033/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=1033&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/08/03/why-the-ide-has-failed-us/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/08/microsoft_visual_basic_for_msdos_professional_edition_version1-00_thumb.png" medium="image">
			<media:title type="html">Microsoft_Visual_Basic_for_MS-DOS_(Professional_Edition_Version1.00)</media:title>
		</media:content>
	</item>
		<item>
		<title>Simple Branching Strategy Part 2: Implementation</title>
		<link>http://simpleprogrammer.com/2010/06/07/simple-branching-strategy-part-2-implementation/</link>
		<comments>http://simpleprogrammer.com/2010/06/07/simple-branching-strategy-part-2-implementation/#comments</comments>
		<pubDate>Mon, 07 Jun 2010 16:12:48 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Continuous Integration]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[Process Improvement]]></category>
		<category><![CDATA[Source Control]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/?p=915</guid>
		<description><![CDATA[In my previous post, I talked about the idea of having a simple branching strategy and why I prefer one where everyone works off the same branch. In this post I will show you how to create what I believe is the most simple and effective branching strategy. Take a look at this diagram of [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=915&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>In my <a href="http://simpleprogrammer.com/2010/06/04/simple-branching-strategy-part-1-back-to-basics/">previous post</a>, I talked about the idea of having a simple branching strategy and why I prefer one where everyone works off the same branch.</p>
<p>In this post I will show you how to create what I believe is the most simple and effective branching strategy.</p>
<p>Take a look at this diagram of a sample project’s code lines:</p>
<p><a href="http://complextosimple.files.wordpress.com/2010/06/simplebranch.png"><img style="display:inline;border-width:0;" title="SimpleBranch" src="http://complextosimple.files.wordpress.com/2010/06/simplebranch_thumb.png?w=511&#038;h=279" border="0" alt="SimpleBranch" width="511" height="279" /></a></p>
<h2>Walking through it</h2>
<p>The idea here is very simple.  Let&#8217;s walk through a development cycle together:</p>
<ol>
<li>Development starts.  Everyone works off of trunk.  Code is frequently checked into trunk, many developers checking in code 3-4 times a day, as they complete small quality sections of development.</li>
<li>The continuous build server is continuously building and checking the quality of the code every single time code is checked in.  Any integration problems are immediately fixed.</li>
<li>Enough features are done to create a release.  Trunk is tagged for release and a release 1 branch is created representing the currently release production code.</li>
<li>Developers continue to work on trunk not being interrupted by the release.</li>
<li>A customer finds a high priority issue in Release 1.</li>
<li>A Rel 1 Hot Fix branch is created, branched off of Release 1 to fix the high priority issue.  It turns out that a good fix will take some time.  Team decides the best course of action is to apply a temporary fix for now.</li>
<li>Rel 1 Hot Fix is done and merged back into Release 1 branch.  Release 1 is re-deployed to production.</li>
<li>In the meantime another emergency problem shows up that must be fixed before the next release.  Rel 1 Hot Fix 2 branch is created.</li>
<li>The bug fix for Rel 1 Hot Fix 2 is a good fix which we want in all future releases.  Rel 1 Hot Fix 2 branch is merged back to Release 1 branch, and merged back to trunk.  Release 1 is redeployed.</li>
<li>In the meantime work has been going on on trunk, team is ready for Release 2.</li>
<li>Release 2 branch is created…</li>
</ol>
<h2>Breaking it down</h2>
<p>I gave a pretty detailed walk-through for a very simple set of actual steps.  But, I hope you can see how simple this process really is.</p>
<p>The basic idea here is that we are trying to decouple releases from development as much as possible.  The team is always going to keep chugging along, building new features and enhancing the code base.  When we decide we have enough features for a release, we simply branch off of trunk and create the release branch.</p>
<p>We can even do some testing on the release branch before we go to production if we need to without impacting future development.</p>
<p>The release branch code-lines never come back to trunk.  They don’t need to, they only exist so that we can have the exact production code and make modifications to it as hot-fixes if we need to.</p>
<p>We branch hot-fixes off of the release branch so that we can work on them independently, because not all hot-fixes go back to the main code-line.  We can make a hot-fix just for the current release, or we can merge it back to trunk to make it a permanent fix.</p>
<p>That is all there is to it.  This kind of branching strategy almost completely eliminates merges.  The only merge you ever do is small merges for hot-fixes.</p>
<p>Your branching strategy does not have to be complicated.  A simple strategy like this can fit almost any software development shop.</p>
<h2>Frequently disputed points</h2>
<p>Almost immediately when I introduce this simple system someone says:</p>
<p><strong>What about half-completed features?  I don’t want to release half-completed features.  Using this strategy with everyone working off trunk, you will always have half-completed features.</strong></p>
<p>So what?  How many times does a half-completed feature cause a potential problem in the system?  If the code is quality and incrementally developed, it should not impact the rest of the system.  If you are adding a new feature, usually the last thing you do is actually hook-up the UI to it.  It won’t hurt anything to have its back-end code released without any way to get to it.</p>
<p>Continuous integration, (especially running automated functional tests), trains you to always keep the system releasable, with every commit of new code.  It really isn’t hard to do this, you just have to think about it a little bit.</p>
<p>If worse comes to worst, and you have a half-finished feature that makes the code releasable, you can always pull out that code on the release branch.  (Although I would highly recommend that you try and find a way to build the feature incrementally instead.)</p>
<p>If you know you&#8217;re going to do something that will disrupt everything, like redesigning the UI, or drastically changing the architecture, then go ahead and create a separate branch for that work.  That should be a rare event though.</p>
<p><strong>I need to be able to develop the features in isolation.  If everyone is working off of trunk, I can’t tell if what I did broke something or if it is someone else’s code.  I am impacted by someone else breaking things.</strong></p>
<p>Good, that is some pain you should feel.  It hurts a lot less when you&#8217;re continuously integrating vs. working on something for a week, merging your feature and finding that everything is broken.</p>
<p>It is like eating a meal.  All the food is going to end up in the same place anyway.  Don’t worry about mixing your mashed potatoes with your applesauce.</p>
<p>If something someone else is doing is going to break your stuff, <strong>better to fail fast</strong>, then to fail later.  Let’s integrate as soon as possible and fix the issue rather than waiting until we both think we are done.</p>
<p>Besides that, it is good to learn to always check in clean code.  When you break other people and they shoot you with Nerf guns and make you wear a chicken head, you are taught to test your code locally before you check it in.</p>
<h2>How to be successful</h2>
<p>How can you be successful at this simple strategy?</p>
<ul>
<li>Make sure you have a continuous integration server up and running and <a href="http://simpleprogrammer.com/2009/12/30/continuous-integration-best-practices/">doing everything it should be doing</a>.</li>
<li>When you work on code, find ways to break it up into small incremental steps of development which never break the system.  Hook up the UI last.</li>
<li>Always think that every time you check in code, it should be code you are comfortable to release.</li>
<li>Check in code at least once a day, preferably as soon as you make any incremental progress.</li>
<li>Test, test, test.  Test locally, unit test, test driven development, automated functional tests.  Have ways to be confident the system never moves backward in functionality.</li>
<li>So important I’ll say it twice.  Automated functional tests.  If you don’t know how to do this, <a href="http://simpleprogrammer.com/2010/01/05/automated-ui-testing-framework-a-real-example/">read this</a>.</li>
<li>Release frequently instead of hot-fixing.  If you never hot-fix you will never have to merge.  If you never have to merge, you will live a longer, less-stressed life.</li>
<li>Don’t go back and clean up code later.  Write it right the first time.  Check it in right the first time.</li>
</ul>
<p>Hopefully that helps you to simplify your branching process.  Feel free to email me or post here if you have any questions, or are skeptical that this could work.</p>
<p><strong>As always, you can subscribe to this </strong><a href="http://feeds.feedburner.com/MakingTheComplexSimple"><strong>RSS feed</strong></a><strong> to follow my posts on Making the Complex Simple.  Feel free to check out </strong><a href="http://elegantcode.com/"><strong>ElegantCode.com</strong></a><strong> where I post about the topic of writing elegant code about once a week.  Also, you can follow me on twitter </strong><a href="http://twitter.com/jsonmez"><strong>here</strong></a><strong>.</strong></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/915/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/915/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/915/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/915/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/915/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/915/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/915/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/915/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/915/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/915/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/915/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/915/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/915/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/915/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=915&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/06/07/simple-branching-strategy-part-2-implementation/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/06/simplebranch_thumb.png" medium="image">
			<media:title type="html">SimpleBranch</media:title>
		</media:content>
	</item>
		<item>
		<title>Powershell is Pretty Cool</title>
		<link>http://simpleprogrammer.com/2010/05/31/powershell-is-pretty-cool/</link>
		<comments>http://simpleprogrammer.com/2010/05/31/powershell-is-pretty-cool/#comments</comments>
		<pubDate>Mon, 31 May 2010 21:31:52 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Career]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/?p=889</guid>
		<description><![CDATA[I’m pretty behind on the Powershell thing.  I have to admit, I never really was that interested in using it.  But now that it is included in Windows 7, I feel like it is much more of a worthwhile investment since those skills are likely to be usable on any machine you&#8217;re on. Dev machines [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=889&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I’m pretty behind on the <a href="http://www.microsoft.com/windowsserver2003/technologies/management/powershell/default.mspx">Powershell</a> thing.  I have to admit, I never really was that interested in using it.  But now that it is included in Windows 7, I feel like it is much more of a worthwhile investment since those skills are likely to be usable on any machine you&#8217;re on.</p>
<h2>Dev machines woes</h2>
<p><a href="http://complextosimple.files.wordpress.com/2010/05/the_woes_poster2.jpg"><img style="display:inline;border-width:0;" title="the_woes_poster2" src="http://complextosimple.files.wordpress.com/2010/05/the_woes_poster2_thumb.jpg?w=369&#038;h=491" border="0" alt="the_woes_poster2" width="369" height="491" /></a></p>
<p>I been having lots of fun trying to build and setup my new dev machine for my new job.  Ended up working over the weekend on it, but it has been a pretty good learning experience.</p>
<p>I have learned many things from the experience, including:</p>
<ul>
<li>Power supplies can make beeping noises.</li>
<li>Just because your computer beeps, doesn’t mean it’s not working, check to see if there is video.</li>
<li>You must pull the processor securing lever all the way up before panicking, calling everyone you know and screaming “MY PROCESSOR IS STUCK IN THE MOTHERBOARD, OH GOD HELP ME NOW!”</li>
<li>Installing Windows in SATA mode, then switching to ACHI mode will probably require a reinstall.</li>
<li>Installing Windows on a hd connected to a motherboard and processor, and switching to another motherboard and processor will probably require a reinstall.</li>
<li>IIS is not installed by default.
<ul>
<li>When IIS is installed, ASP.NET support is not installed by default in the IIS install.  (I always install IIS to serve up static content in 2010… yeah)</li>
</ul>
</li>
<li>Drives raided together need to have their partitions recreated before a Windows 7 install will recognize the drive at all.</li>
<li>4 monitor stand clamps don’t work to well on glass desktops for supporting four 24” monitors.</li>
<li>You can never have too many monitors.  It’s just not possible.</li>
</ul>
<h2>Making lemonade</h2>
<p>Out of all the bad things that seemed to go wrong, I did learn a large amount of stuff, so overall I think it was worth it.</p>
<p>One of the really cool things I started learning is Powershell.  After setting up my dev environment for about the 4th time, I decided I would try to start to build something to benefit the rest of the team and new developers.</p>
<p>I started writing a Powershell script that would set up all the little tricky things that need to be done in order to get our development environment ready.  I am eating my own dog food, from my <a href="http://simpleprogrammer.com/2010/05/28/zero-configuration-development-environments/">previous post</a>.</p>
<p>One value I hold pretty highly is that if I have to do something manually more than 3 times, I need to figure out a way to automate it.  Powershell makes many automation tasks very possible.</p>
<p>I’ll include some pictures of my dev cave on my next post!</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/889/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/889/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/889/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/889/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/889/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/889/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/889/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/889/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/889/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/889/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/889/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/889/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/889/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/889/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=889&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/05/31/powershell-is-pretty-cool/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/05/the_woes_poster2_thumb.jpg" medium="image">
			<media:title type="html">the_woes_poster2</media:title>
		</media:content>
	</item>
		<item>
		<title>Zero Configuration Development Environments</title>
		<link>http://simpleprogrammer.com/2010/05/28/zero-configuration-development-environments/</link>
		<comments>http://simpleprogrammer.com/2010/05/28/zero-configuration-development-environments/#comments</comments>
		<pubDate>Fri, 28 May 2010 15:29:32 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[Process Improvement]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/?p=883</guid>
		<description><![CDATA[I have bee working on getting set up this week to develop for my new, awesome employer, TrackAbout. In doing so, I have once again felt the pain of getting a development environment configured.  I forgot how painful it can be.  This is in no way a reflection of TrackAbout, the truth is most development [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=883&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have bee working on getting set up this week to develop for my new, awesome employer, TrackAbout.</p>
<p>In doing so, I have once again felt the pain of getting a development environment configured.  I forgot how painful it can be.  This is in no way a reflection of TrackAbout, the truth is most development environments are a pain to get setup.  Unless you&#8217;re actively trying to build a painless development environment, it is going to probably be the opposite.</p>
<p>I’ve seen a large number of development environments and I’ve built my share of them.  From all this, I have a pretty good idea of what I consider ideal, what we should strive for.</p>
<p><a href="http://complextosimple.files.wordpress.com/2010/05/lg_cocacola_zero_can.jpg"><img style="display:inline;border:0;" title="lg_cocacola_zero_can" src="http://complextosimple.files.wordpress.com/2010/05/lg_cocacola_zero_can_thumb.jpg?w=240&#038;h=453" border="0" alt="lg_cocacola_zero_can" width="240" height="453" /></a></p>
<h2>The basic outline</h2>
<ol>
<li>Install non-scriptable tools or start with a fresh image.  (Basically getting IDE and SQL Server installed locally)</li>
<li>Get branch from version control.</li>
<li>Build database</li>
<li>Build code</li>
<li>Local deploy</li>
</ol>
<p>The idea here is that I should be able to either get an image that has my base tools installed, or install them myself, then pull down one source control location and everything else that happens from there is the result of  build scripts or some other automated process.</p>
<p>I know, it is easier said than done.  Let’s break it down step by step and look at some of the possible solutions.</p>
<h2>Install tools</h2>
<p>If you are in an organization where everyone will have the same hardware, it is much easier to create an image of a developer machine with say Visual Studio and SQL Server installed.</p>
<p>Another possible solution is to create a dev VM that is maintained and updated regularly, so that it has all the required tools and you have a uniform structure.  I have tried this approach, and I find that the biggest problem is that many times you want to run native to get the performance improvements.  As hardware capabilities increase though, I am seeing this as a more viable route.</p>
<p>Finally, if you can’t get either of those situations, it is ideal to put all the tools that must be installed on a network share or some other easily accessible place.</p>
<p>Ideally, you want to keep the number of required tools down to an absolute minimum.  In most .NET environments this should be Visual Studio and SQL Server.  The other kinds of tools can be handled via dlls (usually).</p>
<h2>Get branch from version control</h2>
<p>Ideally, you should be able to point a person to one source control location, and that should get everything necessary for them to build and deploy the entire system locally.</p>
<p>If different applications your organization is developing have different branches, then you might need to check out one location per project, but even that can be automated to some degree with a “get latest” script or symbolic links.</p>
<h2>Build the database</h2>
<p>This one is kind of hard.  It requires quite a bit of forethought on how to get this working.  The idea here is that I should be able to build the entire database from a set of scripts.</p>
<p>The challenge is getting together a process which allows for the construction of the database from scratch and to populate tables that are required for the application, and be able to apply patches to existing database.  I won’t go into how to do that here.</p>
<h2>Build the code</h2>
<p>There is quite a bit lumped into here.  From a developer perspective I should just be able to run one build command that is the same build that will be run on the <a href="http://simpleprogrammer.com/2009/12/30/continuous-integration-best-practices/">continuous integration server</a> and everything that I need should get built for me.</p>
<p>From behind the scenes, this is a difficult step.</p>
<ul>
<li>You have to make sure everything works from relative paths or environment variables.</li>
<li>You have to have your scripts check to see if things are installed and install them if not (registry keys, etc).</li>
<li>You have to have all the libraries in a place that the build can find on the client machine.</li>
</ul>
<p>The key to success here is to eliminate as much as possible and locate in one place, as much as possible, all configuration differences.</p>
<h2>Local deploy</h2>
<p>It should be very easy to do a local deployment of the application.  For .NET developers this usually isn’t a challenge, but in the Java world it can take some thinking on how to do this properly.</p>
<p>At anytime someone should be able to deploy locally to their machine.  Ideally, anyone should be able to take a build from the build server and deploy it with a single command.</p>
<h2>It is all about the mindset</h2>
<p>Basically, you have to think about zero configuration development environment from the beginning if you really want to be successful at it.  It is much harder to add it on later.</p>
<p>You do have to weigh the effort involved carefully though.  Most developers only set up their configuration once or twice. If you are going to have a growing team where you are constantly adding new developers, you should probably put considerable effort into getting as close to zero configuration as possible.  On the other hand, if you have a small team and don’t have new developers very often, it might not be worth the extra effort.  You have to find the balance.</p>
<p>In all honesty, my experience at my new job has been pretty good in contrast to some of the development environment setups I have seen.  There is a huge amount of consistency in configuration locations, which is good.</p>
<p>I’m looking forward to figuring out how to make it easier for the next guy though, once I understand everything better myself.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/883/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/883/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/883/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/883/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/883/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/883/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/883/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/883/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/883/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/883/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/883/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/883/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/883/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/883/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=883&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/05/28/zero-configuration-development-environments/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/05/lg_cocacola_zero_can_thumb.jpg" medium="image">
			<media:title type="html">lg_cocacola_zero_can</media:title>
		</media:content>
	</item>
		<item>
		<title>Developer Machine Considerations</title>
		<link>http://simpleprogrammer.com/2010/05/24/developer-machine-considerations/</link>
		<comments>http://simpleprogrammer.com/2010/05/24/developer-machine-considerations/#comments</comments>
		<pubDate>Mon, 24 May 2010 21:05:07 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/?p=869</guid>
		<description><![CDATA[I’m back from vacation.  And I’m actually starting a new job today.  I will be working remotely from home for a company called TrackAbout. One of the first things I have been doing to get ready to start this new job is setting up my development workstation at home.  There are really quite a few [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=869&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I’m back from vacation.  And I’m actually starting a new job today.  I will be working remotely from home for a company called <a href="http://trackabout.com">TrackAbout</a>.</p>
<p>One of the first things I have been doing to get ready to start this new job is setting up my development workstation at home.  There are really quite a few considerations to think about when setting up your home office.</p>
<p><a href="http://complextosimple.files.wordpress.com/2010/05/monstermachinebox.jpg"><img class="alignnone size-full wp-image-870" title="MonsterMachineBox" src="http://complextosimple.files.wordpress.com/2010/05/monstermachinebox.jpg?w=500" alt=""   /></a></p>
<h2>Hardware</h2>
<p>I was debating between going all out with the Intel 6 core chip or getting the nicely priced AMD 6 core.  I ended up choosing the AMD chip because the Intel chip was 3 times the cost, and the chipsets on the motherboards for the AMD chip are a little more stable since they have been around longer.</p>
<p>The processor doesn’t really matter that much anymore since processors are so fast nowadays.  What really matters though is the hard disk.  On this case I opted for a super fast SSD drive.  256GB should be plenty of space, with an additional hard drive just for back ups.  The speed improvement when using a really good SSD drive is amazing.  It is the single best upgrade you can do in a developer machine.</p>
<p>I also went with a large amount of RAM because I know that if you need to run a virtual machine, RAM is going to be a big deal there.  16GB should meet any need just fine.</p>
<p>Finally, I am trying out a quad-monitor setup for the first time.  I have been using dual 24” monitors for a long time now, but I have always thought two more would be even better.  It is really important to be able to quickly see multiple things going on at once without having to switch between applications.</p>
<p>I’m planning on setting up the monitors like so:</p>
<ol>
<li>IDE</li>
<li>Reference: web pages, API, etc</li>
<li>Communications: twitter, pidgin, email</li>
<li>Secondary IDE for debug, or SQL server</li>
</ol>
<h2>Desktop or laptop</h2>
<p>Most developers are getting laptops with docking stations these days and while I see the appeal, I like a good old tower and a cheap laptop instead.</p>
<ul>
<li>With a desktop you can get beefier hardware for less $$$.</li>
<li>You can pick the hardware yourself (which is a big deal for me since I do a large amount of research on each component).</li>
<li>You can have more monitors natively (just buy a 4 port video card).</li>
<li>More upgrade options.</li>
</ul>
<p>I still have a laptop, but it is a cheap light one.  The advantage here is that I can just remote desktop into my powerful machine and get all the benefits of both worlds.  If I am really ambitious I can even remote in with my iPad or phone.</p>
<p>So, while I can definitely understand the appeal to many for having a laptop that they can just disconnect and carry with them, I still prefer the desktop.</p>
<h2>Virtualize?</h2>
<p>I almost did it this time.  I keep going back and forth on this one.  I really want to have my development machine be a VM so that I can just load it up and go, but after thinking about it more, I am not sure it is worth the cost.</p>
<p>I kept thinking about why I want to have a virtual machine for my development machine.  Really the answer comes down to me liking to have things in a nice separate little box.  Sure, I can drop my dev virtual machine on an external drive and take it with me, but I can achieve the same by remoting into it instead.</p>
<p>The thing that made me finally decide on no VM is the idea of optimizing for the rule rather than the exception.  The truth of the matter is when I am on my PC, I am going to be spending 90% of my time doing development work, and doing it on that one machine.</p>
<p>When I look at it that way, I can’t see a good reason to take the performance hit of virtualization for the 10% case.  I can achieve most of the “neatness” of virtualization by cloning my disk at a good configuration.</p>
<p>I’ll probably still have some sandbox VMs for testing out “crazy stuff”, but I think I am going to go native so I can really utilize the max out of my new hardware.</p>
<p>I’ll just have to treat my Windows install like I treat my source code.  “Leave it better than when I started.”</p>
<p>Anything I’m missing here or not seeing?</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/869/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/869/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/869/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/869/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/869/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/869/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/869/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/869/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/869/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/869/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/869/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/869/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/869/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/869/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=869&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/05/24/developer-machine-considerations/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/05/monstermachinebox.jpg" medium="image">
			<media:title type="html">MonsterMachineBox</media:title>
		</media:content>
	</item>
		<item>
		<title>Mr. Developer, Prod is Not For You</title>
		<link>http://simpleprogrammer.com/2010/05/03/mr-developer-prod-is-not-for-you/</link>
		<comments>http://simpleprogrammer.com/2010/05/03/mr-developer-prod-is-not-for-you/#comments</comments>
		<pubDate>Mon, 03 May 2010 15:18:21 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://simpleprogrammer.com/?p=803</guid>
		<description><![CDATA[In my Kanbanand guide, I have a rule for infrastructure that says, &#8220;Production data never goes to any other environment.&#8221; Someone recently asked what exactly this means. It means that the database data that is in production never goes into dev, integration, qual, or whatever other environments you may have set up at your workplace. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=803&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>In my <a href="http://simpleprogrammer.com/2010/04/28/the-kanbandand-guide/">Kanbanand guide</a>, I have a rule for infrastructure that says, &#8220;Production data never goes to any other environment.&#8221;</p>
<p>Someone recently asked what exactly this means.</p>
<p>It means that the database data that is in production never goes into dev, integration, qual, or whatever other environments you may have set up at your workplace.  I think more important than the &#8220;what&#8221; is the &#8220;why&#8221;, and while I&#8217;m at it, I&#8217;ll tell you why I won&#8217;t give you, as a developer, access to production data at all.</p>
<p><a href="http://complextosimple.files.wordpress.com/2010/05/puzzle_lock.jpg"><img class="size-full wp-image-804 alignnone" title="puzzle_lock" src="http://complextosimple.files.wordpress.com/2010/05/puzzle_lock.jpg?w=500&#038;h=424" alt="" width="500" height="424" /></a></p>
<h2>Why production data stay in production</h2>
<p>Let&#8217;s start with a simple reason: security.  Production data in most cases is going to contain at least some amount of sensitive information.  If your company leaks sensitive information about customers or clients, you can almost guarantee that you will have a lawsuit on your hands.</p>
<p>It is much better to keep production data as safe as possible.  The best way to do that is to limit access to it as much as possible.  If you move production data to different environments, you will be greatly increasing the amount of places that data lives and correspondingly the number of people who have access to it.</p>
<p>Aside from just the security concerns, is the problem of reliance on exact data to recreate a problem.  <strong>Debugging an issue which is seen in production should not require the actual production data. </strong>If it does, there is a problem with the tooling you have created to support your application.  You might consider <a href="http://simpleprogrammer.com/2009/12/03/dedicated-developer-tools-teams/">creating some development tools</a> that will allow you to simulate any production issue in a different environment without having to use real production data.</p>
<p>I know it is much easer to just use production data, but it is a bad habit that masks other problems with your tooling and support.  It also has a large cost to the infrastructure and support of an application if you require frequent data migration between environments.</p>
<h2>Why developers stay out of production</h2>
<p>The reasoning is very similar.  We could talk again about security.  We could talk again about the problems with relying on production data to debug a problem in your application.</p>
<p>This really comes down to a discipline and constraint issue.  By enforcing this constraint and practicing this discipline, you gain quite a few things out of necessity:</p>
<ul>
<li>Logging must be improved to understand what happened in production</li>
<li>You are forced to consider creating a user click tracking mechanism</li>
<li>Test data generation is forced to be considered</li>
<li>Testing becomes more complete, because your team is forced to recreate issues independently rather than using production data</li>
</ul>
<p>It might not be immediately apparent to you how these things are connected, but if you enforce this kind of a policy, you will quickly find that you will need better ways of understanding what the user did.</p>
<p>It may seem counter-productive to make a developer&#8217;s job harder by preventing them from accessing production, but in the long run, being forced to create tooling and better logging to understand how the user is using the system, and having more complete testing will save time.</p>
<h2>Some tips on making this reality</h2>
<p>Yes, I know, easier said than done.  Let me help you get it done with these tips:</p>
<ol>
<li>Build enough logging into the application to make it easy to understand what the system is doing and the flow through the system.</li>
<li>Build a detailed level of logging that can be turned on for different parts of a live running production system.</li>
<li>Build or use tools that take data from your web server logs and application logs and translate that into a digest of how the user clicked through the system.  (Doing this well will allow you to recreate most scenarios that may have happened in production.)</li>
<li>Create migration tools that allow you to migrate and cleanse a particular piece of data.  The goal here is not to take the whole database and dump it to another environment, but to take specific sets of data, cleanse them (get rid of all personally identifiable information), and put them somewhere else to examine and debug.</li>
<li>Have ways to generate volumes of clean test data to put into non-production environments.  This may look like a test script that runs though the application and clicks through many scenarios to generate test data, or a bunch of SQL scripts that populate test data tables.</li>
</ol>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/803/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/803/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/803/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/803/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/803/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/803/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/803/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/803/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/803/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/803/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/803/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/803/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/803/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/803/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=803&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/05/03/mr-developer-prod-is-not-for-you/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/05/puzzle_lock.jpg" medium="image">
			<media:title type="html">puzzle_lock</media:title>
		</media:content>
	</item>
		<item>
		<title>The Scrum Bubble</title>
		<link>http://simpleprogrammer.com/2010/04/30/the-scrum-bubble/</link>
		<comments>http://simpleprogrammer.com/2010/04/30/the-scrum-bubble/#comments</comments>
		<pubDate>Fri, 30 Apr 2010 22:30:53 +0000</pubDate>
		<dc:creator>jsonmez</dc:creator>
				<category><![CDATA[Agile]]></category>
		<category><![CDATA[Scrum]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">https://complextosimple.wordpress.com/2010/04/30/the-scrum-bubble/</guid>
		<description><![CDATA[I thought today would be a good day to talk about what I am calling the &#34;Scrum Bubble.&#34;&#160; There seems to be just tons of heat on the Scrum and certifications topic going on lately.&#160; From my original post on Scrum for the Money to Ron Jeffries post on Certifications to Uncle Bob&#8217;s post on [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=802&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I thought today would be a good day to talk about what I am calling the &quot;Scrum Bubble.&quot;&#160; There seems to be just tons of heat on the Scrum and certifications topic going on lately.&#160; From my original post on <a href="http://simpleprogrammer.com/2010/03/31/scrum-for-the-money/">Scrum for the Money</a> to <a href="http://xprogramming.com/articles/scrum-alliance-drop-certified/">Ron Jeffries post on Certifications</a> to<a href="http://blog.objectmentor.com/articles/2010/04/27/certification-dont-waste-your-time"> Uncle Bob&#8217;s post on Certifications</a>, to <a href="http://elegantcode.com/2010/04/29/scrum-and-the-c-word/">David Starr&#8217;s post on Certifications</a>.</p>
<p>Here is the thing about a dead horse.&#160; Well, you just can&#8217;t really know it&#8217;s dead.&#160; I mean, sure its eyes are closed.&#160; Sure, it’s lying there in a bloody mess on the floor, but is it really dead?&#160; The only sensible thing to do is beat it just one more time, just to make sure.&#160; Let’s kill that horse good!</p>
<p><a href="http://complextosimple.files.wordpress.com/2010/04/beating_a_dead_horse.jpg"><img style="display:block;float:none;margin-left:auto;margin-right:auto;border-width:0;" title="beating_a_dead_horse" border="0" alt="beating_a_dead_horse" src="http://complextosimple.files.wordpress.com/2010/04/beating_a_dead_horse_thumb.jpg?w=240&#038;h=213" width="240" height="213" /></a>There is an underlying problem here… I call it</p>
<h2>THE SCRUM BUBBLE</h2>
<p>Remember the .com era.&#160; Ah, wasn’t that great.</p>
<p>How about that whole stock market always rises decade…</p>
<p>Oh, and don’t forget the housing boom.&#160; The housing boom was great!</p>
<p>But then… What happened?</p>
<p>Oh yes, we got nuked back to the stone age.&#160; </p>
<p>The same thing is happening with Scrum.&#160; Certification proliferation is fueling it.&#160; What happens when everyone in the software development world is a Certified Scrum Master, and we are still building shitty software?&#160; What then?</p>
<h2>BOOM!</h2>
<p>It implodes, just like a bubble.&#160; That bubble will burst and when that happens it is going to take Agile right along with it.</p>
<p>A wise man once said</p>
<blockquote><p>You can shear a sheep many times, but skin him only once. </p>
</blockquote>
<p>When you arm people with useless certifications and send them into organizations to go and conquer the beast of software development, you are skinning that sheep.&#160; All the consultants that are milking so much money out of Scrum will eventually find that tit dry.</p>
<h2>Scrum is good</h2>
<p>It is.&#160; It is really a great tool for building software.&#160; It makes sense, it is practical and if you apply it correctly you will get a good result.&#160; The problem is applying it correctly.&#160; The problem is it isn’t addressing the other things that need to change to really be able to do Agile development.&#160; (Which is why I suggested a <a href="http://simpleprogrammer.com/2010/04/28/the-kanbandand-guide/">new process Kanbanand</a> that does address those things.)</p>
<p>Training and consultants are good also.&#160; Getting good hands on training from someone who really knows what they are doing can accelerate you on your learning curve like nothing else.&#160; Consultants who have already been through a process and can look at things with a fresh eye can be invaluable in making positive changes in an organization.</p>
<p>The problem is Scrum is not the end-all-be-all to software development.&#160; It is not the silver bullet that kills death march zombies.&#160; It is a tool.&#160; I really like <a href="http://blog.crisp.se/henrikkniberg/">Henrik Kniberg’s</a> approach to Scrum and Kanban, where he talks about each being a tool to help you develop software.&#160; In his <a href="http://www.amazon.com/Kanban-Scrum-making-most-both/dp/0557138329/ref=sr_1_2?ie=UTF8&amp;s=books&amp;qid=1272660312&amp;sr=8-2">book</a>, (buy it this book is really good), he asks the question, which is better a fork or a knife?&#160; A pretty silly question to ask, which illustrates the point well. </p>
<p>When we hype up Scrum to the point of rock star stardom, and then use it as a tool to extract large amounts of money out of the software development eco systems quickly, we are creating a bubble.&#160; Just like any bubble, we should expect that to burst if we keep inflating it.</p>
<h2>There are a lot of good people in Scrum</h2>
<p>There are plenty of good people that have a sincere passion for the craft that are really investing into Scrum because they know it is a good way to deliver value to customers, and it is a simple framework that can be easily taught and implemented.&#160; There are plenty of people like <a href="http://elegantcode.com/about/david-starr/">David Starr</a> and <a href="http://www.scrumalliance.org/profiles/59-tobias-mayer">Tobias Mayer</a> that are honestly trying to do good in the world of software development and using Scrum to do it.&#160; I honestly believe that.</p>
<p>But, there are plenty of other people that are riding on the success of Scrum and building careers out of being a certificate factory.&#160; We have to take away the keys to the kingdom from those people if we want to avoid destroying the good that others are doing in the name of Scrum.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/complextosimple.wordpress.com/802/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/complextosimple.wordpress.com/802/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/complextosimple.wordpress.com/802/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/complextosimple.wordpress.com/802/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/complextosimple.wordpress.com/802/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/complextosimple.wordpress.com/802/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/complextosimple.wordpress.com/802/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/complextosimple.wordpress.com/802/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/complextosimple.wordpress.com/802/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/complextosimple.wordpress.com/802/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/complextosimple.wordpress.com/802/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/complextosimple.wordpress.com/802/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/complextosimple.wordpress.com/802/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/complextosimple.wordpress.com/802/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=simpleprogrammer.com&amp;blog=10597120&amp;post=802&amp;subd=complextosimple&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://simpleprogrammer.com/2010/04/30/the-scrum-bubble/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/695e2a956b2dcb5ac45a7095b6ee338a?s=96&#38;d=retro&#38;r=PG" medium="image">
			<media:title type="html">jsonmez</media:title>
		</media:content>

		<media:content url="http://complextosimple.files.wordpress.com/2010/04/beating_a_dead_horse_thumb.jpg" medium="image">
			<media:title type="html">beating_a_dead_horse</media:title>
		</media:content>
	</item>
	</channel>
</rss>
