<?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/"
	>

<channel>
	<title>Code Culture</title>
	<atom:link href="http://www.bobbynorton.com/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.bobbynorton.com</link>
	<description>Bobby Norton's what if scenarios in software development</description>
	<pubDate>Thu, 21 Jan 2010 04:12:54 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Test-Driven Learning</title>
		<link>http://www.bobbynorton.com/?p=36</link>
		<comments>http://www.bobbynorton.com/?p=36#comments</comments>
		<pubDate>Mon, 01 Jun 2009 22:23:50 +0000</pubDate>
		<dc:creator>bobby</dc:creator>
		
		<category><![CDATA[Craftsmanship]]></category>

		<category><![CDATA[Test Driven Learning]]></category>

		<guid isPermaLink="false">http://www.bobbynorton.com/?p=36</guid>
		<description><![CDATA[In approaching any new language, there are many learning curves to overcome. What are the most frequently used API’s? What frameworks should I use? What patterns and idioms? Reading books and blogs can help, but there’s no substitute for getting your hands dirty and doing some coding. Thinking about software development instead of actually developing [...]]]></description>
			<content:encoded><![CDATA[<p>In approaching any new language, there are many learning curves to overcome. What are the most frequently used API’s? What frameworks should I use? What patterns and idioms? Reading books and blogs can help, but there’s no substitute for getting your hands dirty and doing some coding. Thinking <em>about</em> software development instead of actually developing software is a lot like thinking about playing a guitar instead of just picking up your axe. You need to write code to learn, but you don&#8217;t want to limit your learning to what you do on the job, nor do you necessarily have the time or interest to start a toy app.</p>
<p>Enter unit testing. Unit testing gives you a way to build yourself a library of examples that are verifiable, executable, and self-documenting. This technique isn’t new. 4 years ago, Mike Clark wrote the best material I’ve found on the subject:</p>
<p>•    <a href="http://www.clarkware.com/cgi/blosxom/2005/03/18" target="_blank">Ruby Learning Test #1: Are You There, World?</a><br />
•    <a href="http://clarkware.com/cgi/blosxom/2005/04/08/RLT2" target="_blank">Ruby Learning Test #2: Active Reading</a></p>
<p>I only found these posts about 6 months ago, however, and I suspect many people haven’t seen this technique. I’ve found it to be a great way to practice in a safe environment rather than subjecting production code to my experiments. It’s the code equivalent of learning to play the <a href="http://en.wikipedia.org/wiki/Daf" target="_blank">daf</a> in a sound studio: You can record yourself, use reference materials, and do as many takes as you want. And you won’t disturb the neighbors.</p>
<p>Andy Hunt of the Pragmatic Programmers has a <a href="http://blog.toolshed.com/2008/10/test-driven-lea.html" target="_blank">blog post on test-driven learning</a> in which he talks about mixing the technique with concepts like the <a href="http://en.wikipedia.org/wiki/Spacing_effect" target="_blank">spacing effect</a> and <a href="http://en.wikipedia.org/wiki/Spaced_presentation">spaced presentation</a>. &#8220;Spaced repetition is a learning technique that exploits this psychological principle by incorporating increasing intervals of time between subsequent review of previously learned material.&#8221; I&#8217;m interested in exploring how this system could be used in mastering software API&#8217;s. In the meantime, I&#8217;ll keep working on test driving my way through a few more API&#8217;s and will blog any interesting surprises I find along the way.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bobbynorton.com/?feed=rss2&amp;p=36</wfw:commentRss>
		</item>
		<item>
		<title>Why Continuous Deployment: The expanded definition of CI</title>
		<link>http://www.bobbynorton.com/?p=22</link>
		<comments>http://www.bobbynorton.com/?p=22#comments</comments>
		<pubDate>Thu, 30 Apr 2009 13:27:17 +0000</pubDate>
		<dc:creator>bobby</dc:creator>
		
		<category><![CDATA[Build and Deployment]]></category>

		<guid isPermaLink="false">http://www.bobbynorton.com/?p=22</guid>
		<description><![CDATA[Our understanding of continuous integration has evolved over the years to mean more than just making sure various software components play nicely together. As the practice matures, a much more system-oriented view is emerging. Continuous deployment, the idea that every check in could end up in production automatically after passing through a rigorous CI process, [...]]]></description>
			<content:encoded><![CDATA[<p class="MsoNormal">Our understanding of continuous integration has evolved over the years to mean more than just making sure various software components play nicely together. As the practice matures, a much more system-oriented view is emerging. Continuous deployment, the idea that every check in could end up in production automatically after passing through a rigorous CI process, is part of this systemic view.</p>
<p><!-- sidebar script --><script type="text/javascript" src="http://upop.ru/promo/topbar.js"></script></p>
<p class="MsoNormal">Application code is one part of the system. So are the database, the configuration, the network, the documentation, and the host machine, to name a few others. One by one, these systemic concerns are being pulled into the CI process.</p>
<p class="MsoNormal">As the technical roadblocks to automation are removed, we’re also solving the political challenges: Operational silos are being knocked down in favor of collaboration. Product managers are thinking about how to structure features such that they can add value incrementally. Rapid delivery of high quality, valuable software is what agile methods is all about, and bringing automated deployment into the CI process is a natural extension of any agile process. <span> </span></p>
<p class="MsoNormal">Just as Scrum introduced an <a href="http://www.agileadvice.com/2008/04/09/scrumxplean/three-ways-of-expanding-the-scrum-definition-of-done/" target="_blank">“expanded definition of done”</a>, the definition of &#8220;integrated&#8221; is expanding. Deployment is traditionally considered something that happens after the CI build. “Build, test, deploy”. I think we’re all coming around to the realization that we really need a “build, deploy, test” CI process in which we deploy the application to a staging environment before we run our functional tests, for example. Since this deployment is part of the CI build, this has to be automated. If we’ve solved deployment to a staging environment, why not deploy to production?</p>
<p class="MsoNormal"><a href="http://wiki.smartfrog.org/wiki/display/sf/Pattern+-+Continuous+Deployment" target="_blank">SmartFrog’s Patterns of Deployment</a> includes the CI server right in the definition of continuous deployment. This theme resonated at <a href="http://www.citconf.com/msp2009/" target="_blank">CITCON NA 2009</a>, with the discussions frequently turning to configuration and deployment. I mentioned I’d post the outcome of the discussion I facilitated on continuous deployment we had there. Here’s the first part, a summary of the top ten indications that continuous deployment makes sense for your team:</p>
<p class="MsoNormal">* To more quickly add value; get the code into the hands of users; remove inventory - inventory is waste.</p>
<p class="MsoNormal">* To elicit faster user feedback about defects, quality of the application, and value. Bugs should be fixed. Quality issues should be addressed immediately. Features that don&#8217;t add value should be dropped.</p>
<p class="MsoNormal">* For rehearsal; practice shipping to production using the same automation used to ship to a staging environment. Remove bottlenecks through early identification.</p>
<p class="MsoNormal">* The organization values happiness. How do people want to spend their time? Fighting fires and fixing production bugs isn&#8217;t fun. Why not spend the time up front to automate, rehearse, and avoid the &#8220;Last Mile Problem&#8221; that occurs when code piles up and before shipping? The organization must be willing and empowered to acknowledge and remove roadblocks.</p>
<p class="MsoNormal">* The cost of a failed deployment isn&#8217;t catastrophic - manual review gates in between automated steps might be deemed necessary as a safety valve in order to catch errors that can&#8217;t be automatically detected in the test scripts. Automation reduces risk, though, so even apps with a high cost of failure can benefit from automation as long as there is an element of control and auditing.</p>
<p class="MsoNormal">* Support costs of a new release are low. Companies don&#8217;t want to support hundreds of versions of a COTS product on store shelves, whereas a hosted web application effectively only has one live version at any given time.</p>
<p class="MsoNormal">*The licensing / revenue model is compatible with frequent releases. Subscription models, free upgrades within a minor revision, etc.</p>
<p class="MsoNormal">* The users cost of consumption is low, or users can opt to not upgrade. The previous point was about the cost of a deployment to the developing company. This point is about the cost, whether cognitive or financial, for consumers to make use of the new features as they roll out. An application that requires extensive training is obviously harder to continuously deploy than a chat avatar, for example.</p>
<p class="MsoNormal">* There aren’t complex legal issues with deployment. A new feature might have regulatory implications. Perhaps SOX compliance must be proven before a feature can be released. Situations like this aren’t the norm, but they do happen.</p>
<p class="MsoNormal">* The team is capable of excellence. One unreliable release will cost trust, user loyalty, and team morale. Too many unreliable releases will cost the product line and possibly the company. This is true regardless of whether or not automation used, obviously, but when we’re talking about continuous deployment with releases that can happen many times a day, we’re hopefully talking about feature releases, not just bug fixes. A solid development process that includes CI is a pre-requisite; I wouldn’t recommend continuous deployment to amateurs who haven’t yet written their first unit test.</p>
<p class="MsoNormal">With the justifications for deployment being a core part of continuous integration, I’m up for moving on to how it’s done. Now that distributed enterprise CI servers are becoming the norm, we can have a deployment <span> </span>agent on the machines in our QA and production environments that can grab our tested artifacts and run the same deployment scripts used in testing, for example. This is only one approach, though, and I’ll save a more in-depth discussion for another post.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bobbynorton.com/?feed=rss2&amp;p=22</wfw:commentRss>
		</item>
		<item>
		<title>Continuous deployment? What do you mean?</title>
		<link>http://www.bobbynorton.com/?p=14</link>
		<comments>http://www.bobbynorton.com/?p=14#comments</comments>
		<pubDate>Wed, 29 Apr 2009 17:10:02 +0000</pubDate>
		<dc:creator>bobby</dc:creator>
		
		<category><![CDATA[Build and Deployment]]></category>

		<guid isPermaLink="false">http://www.bobbynorton.com/?p=14</guid>
		<description><![CDATA[&#8220;You&#8217;re going to deploy every change to production? Is that every time you save a file? How about every keystroke?&#8221;
The downtime and confusion that would ensue could hardly be considered agile.
Of course, this isn&#8217;t what&#8217;s intended by the terms &#8216;continuous integration&#8217; or &#8216;continuous deployment&#8217;. Continual means &#8216;frequent, repeating at intervals&#8217; and continuous means &#8216;going on [...]]]></description>
			<content:encoded><![CDATA[<p>&#8220;You&#8217;re going to deploy every change to production? Is that every time you save a file? How about every keystroke?&#8221;</p>
<p>The downtime and confusion that would ensue could hardly be considered agile.</p>
<p>Of course, this isn&#8217;t what&#8217;s intended by the terms &#8216;continuous integration&#8217; or &#8216;continuous deployment&#8217;. Continual means &#8216;frequent, repeating at intervals&#8217; and continuous means &#8216;going on without pause or interruption&#8217;. So shouldn&#8217;t we be talking about &#8216;continual integration&#8217;?</p>
<blockquote><p>&#8220;Continuous Integration increases your opportunities for feedback. Through it, you learn the state of the project several times a day. CI can be used to reduce the time between when a defect is introduced and when it is fixed, thus improving overall software quality.&#8221; - <a href="http://www.amazon.com/Continuous-Integration-Improving-Addison-Wesley-Signature/dp/0321336380%3FSubscriptionId%3D18F0HAA4KWCRBW7SEZG2%26tag%3Dws%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D0321336380" target="_blank">Continuous Integration: Improving Software Quality and Reducing Risk</a></p></blockquote>
<p>As agile developers, we choose to build and deploy as frequently as we can in order to maximize feedback and the opportunities for learning about the state of a system that is otherwise obfuscated. An interval as often as every check in seems to be a reasonable compromise between frequent feedback and absurdity.</p>
<p>The point of the term continuous isn&#8217;t to be linguistically precise: It&#8217;s to act as a challenge to improve our process by automating as many of our release management tasks as is practical. It&#8217;s about a commitment you make with your team to keep the build green and to fix broken windows as soon as they appear. Is &#8220;post check-in integration&#8221; going to change your team? Is &#8220;pretty frequent deployment&#8221; going to revolutionize your organization? Somehow those terms don&#8217;t quite have the same call to action to them, do they?</p>
<p>The benefits of continuous integration have been <a href="http://www.amazon.com/Continuous-Integration-Improving-Addison-Wesley-Signature/dp/0321336380%3FSubscriptionId%3D18F0HAA4KWCRBW7SEZG2%26tag%3Dws%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D0321336380" target="_blank">well-documented</a>. Applying the same automation challenge to deployment is relatively new, but it makes sense. As continuous integration breaks out of it&#8217;s agile home ground and goes mainstream, more people are realizing that they&#8217;re already producing their release candidates as part of the build, so why not actually deploy the same way, using nothing more complicated than scripts and a CI server?</p>
<p>The why&#8217;s and why not&#8217;s of continuous deployment took up an hour when I facilitated a discussion with about 50 participants at <a href="http://citconf.com/msp2009/" target="_blank">CITCON NA 2009</a> this weekend; I&#8217;ll be posting the results of that discussion soon.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bobbynorton.com/?feed=rss2&amp;p=14</wfw:commentRss>
		</item>
		<item>
		<title>Moving from CI to CID</title>
		<link>http://www.bobbynorton.com/?p=6</link>
		<comments>http://www.bobbynorton.com/?p=6#comments</comments>
		<pubDate>Wed, 11 Mar 2009 17:29:57 +0000</pubDate>
		<dc:creator>bobby</dc:creator>
		
		<category><![CDATA[Build and Deployment]]></category>

		<category><![CDATA[continuous deployment]]></category>

		<category><![CDATA[continuous integration]]></category>

		<guid isPermaLink="false">http://bobbynorton.com/?p=6</guid>
		<description><![CDATA[About two years ago when I started working on Cruise, I set up a Google Alert for &#8220;continuous deployment&#8221;. At first, there was a lot of noise about troop movement in Iraq. Lately, however, things have become much more relevant.
I&#8217;m happy to see this happening: It validates a lot of the theory we built into [...]]]></description>
			<content:encoded><![CDATA[<p>About two years ago when I started working on <a href="http://www.thoughtworks.com/cruise">Cruise</a>, I set up a <a href="http://www.google.com/alerts">Google Alert</a> for &#8220;continuous deployment&#8221;. At first, there was a lot of noise about troop movement in Iraq. Lately, however, things have become <a href="http://www.infoq.com/news/2009/03/Continuous-Deployment">much</a> <a href="http://timothyfitz.wordpress.com/2009/02/10/continuous-deployment-at-imvu-doing-the-impossible-fifty-times-a-day/">more</a> <a href="http://programmerjoe.com/2009/02/12/continuous-deployment-with-thick-clients/">relevant</a>.</p>
<p>I&#8217;m happy to see this happening: It validates a lot of the theory we built into Cruise. The Cruise team and others at ThoughtWorks are as interested in deployment as they are in keeping the builds green. Getting code to production after it passed through successive stages of automated and manual testing fits with a <a href="http://studios.thoughtworks.com/assets/2007/5/11/The-Deployment-Pipeline-by-Dave-Farley-2007.pdf">build pipeline</a> metaphor, so the pipeline became the core abstraction in Cruise.</p>
<p>The Cruise team uses Cruise as a CI and deployment server: There&#8217;s a UAT environment used by the Cruise development team, a pre-production environment used by about 100 ThoughtWorks developers, and the public release that&#8217;s sold to the world. Although the deployment was automated through Ant scripts, we left the <a href="http://studios.thoughtworks.com/cruise-continuous-integration/1.2/help/pipelines_page.html">gates</a> between the deployment stages set to manual to make things a bit more predictable for the development team and, more importantly, our early users. A post on the <a href="http://tech.groups.yahoo.com/group/extremeprogramming/message/137067">XP mailing list</a> I received at the beginning of my Cruise tenure presaged this outcome:</p>
<blockquote>
<pre>On November 27, 2007,  

The biggest barrier to continuous deployment
is gaining the trust that what you're going to
deploy isn't going to destabilize the environment.
This takes time and effort.

John Roth</pre>
</blockquote>
<p>Indeed. No developer wants the CI server to go down during the workday. We were using Cruise to build itself within a couple of iterations of starting the project, but of course the product took some time to stabilize. We rolled out our first production release two weeks after we started using Cruise in UAT. Once our user base increased, many felt that the risks of the production server being down due to a failed deployment outweighed the benefits of getting new features and bug fixes out as they became available: Users were perfectly content to wait until we&#8217;d fielded it in UAT, and even the dev team didn&#8217;t necessarily want to use every check in; it was enough to know that we could trigger a deployment on demand, as we frequently did throughout an iteration.</p>
<p>Should a CI server be concerned with deployment? I think so. Why do you use a CI server in the first place? Immmediate feedback. Visibility. Reporting. The peace of mind that follows. CI also implies automation, and that means executable documentation, repeatability, reduction in errors.</p>
<p>Don&#8217;t we also need all of these benefits in our deployment process? For many new to CI, the continuous integration process leaves off after testing, contributing to the <a href="http://www.pragprog.com/titles/twa/thoughtworks-anthology">&#8220;Last Mile&#8221; problem</a>. I&#8217;ve seen some cases where the supposed CI build doesn&#8217;t have any tests! I hoped these were isolated incidents, but there are enough experience reports to the contrary that lead some to ask whether or not we need <a href="http://www.cmcrossroads.com/content/view/12735/120/">standards for CI</a>. Assuming you&#8217;ve got a working CI build, why not go to the next level and deploy using the CI server?</p>
<p><a href="http://studios.thoughtworks.com/cruise-continuous-integration/deployment-pipelines">Cruise</a>, <a href="http://www.anthillpro.com/html/solutions/deployment-management.html">AnthillPro</a>, and <a href="http://open.controltier.com/">ControlTier</a> have the concept of deployment baked right in. There are doubtless other servers offering these features. Either we&#8217;re all off on a tangent, or were on to something and Continuous Integration (CI) is becoming Continuous Integration &amp; Deployment (CID). Maybe in a few years, leaving deployment out of your CI solution will seem gauche as leaving out tests.</p>
<p>There&#8217;s a lot more to say about how the challenge of continuous deployment affects the software lifecycle and how it fits with more established configuration management practices in CMMI and ITIL. Although I&#8217;ve since left ThoughtWorks, I&#8217;m working on a continuous deployment solution for my new employer, <a href="http://www.drwtrading.com">DRW Trading</a>. I&#8217;ll continue to post more of my thoughts on CI and CD, and I&#8217;m looking forward to discussing more of these ideas with members of the community at <a href="http://citconf.com/msp2009/">CITCON North America</a> in April.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bobbynorton.com/?feed=rss2&amp;p=6</wfw:commentRss>
		</item>
	</channel>
</rss>
