Integrate Button Weblog

Archive for June, 2007

Received my copy of Continuous Integration today

Friday, June 29th, 2007

Finally! After over two years, I got to see the results of my work today. We live in a world of bits and bytes and, of course, I’ve already seen the book in PDF form. But, there is something about holding the paper copy that is exhilarating. This is an advance copy I received from my publisher. It will be available to everyone else in about a week. 5,000 copies are being shipped to a warehouse as I write. They’re selling fast, so order your copy now.

Vidcast: Build Software with Every Change

Saturday, June 23rd, 2007

Videocast demonstrating the first of the 46 practices in the book, Build Software with Every Change. This five-minute video uses CruiseControl, Ant and Subversion to demonstrate the processes involved in this important practice. The video has sound, so “turn them headphones up! Turn ‘em up. Turn them s#$%’s up!” (I will send a free copy of the Continuous Integration book to the first person to name that reference.)

JavaWorld CI book excerpt

Thursday, June 21st, 2007

JavaWorld has posted an excerpt of the CI book. If you can’t wait to get your hands on the hard copy (don’t worry, it’s only about a week away) then check out the advantages and disadvantages of CI and how CI complements other software development practices over on JavaWorld!

Share your Continuous Integration war stories hosted by Stelligent

Tuesday, June 19th, 2007

The company I work for, Stelligent, is hosting a “Share Your Continuous Integration War Stories” wine and cheese event at our offices in Reston, VA on Thursday, June 28th from 5:30PM - 7:00PM. You need to RSVP, so respond soon because space is limited. We are raffling off the first signed copy of the Continuous Integration book at the event.

Continuous Integration book is available on Safari

Monday, June 18th, 2007

The Continuous Integration book is available online on Safari at http://safari.informit.com/9780321336385. You can preview it or enroll in the Safari service to view the entire book online.

The Future of Continuous Integration: Long Running Builds

Sunday, June 17th, 2007

In a recent post of the future of Continuous Integration , I pondered how the broken build can affect your development team and offered potential solutions. My next topic is what many consider to be the bane of CI, Long-Running Builds. Again, I don’t think there’s a silver bullet answer to this conundrum. But, depending on how the problem manifests, there are some solutions. I spend quite a bit of time in chapter 4 discussing long-running builds, so this is a quick synopsis.

The Problem

  • In the context of CI, long-running builds can slow developers from moving onto their next task. For instance, on Agile projects, many employ the rule that you don’t work on your next development task until the integration build is successful

How Long is too Long?

Symptoms

  • The obvious: developers complaining about how long it takes for the builds to run
  • Developers check in their code less often (making integrations more painful when they do happen)
  • People sitting around waiting for the integration build to complete

Possible Solutions

First, as I describe in the book , it’s useful to know what the actual problem is. From my experience, I’ve found that long-running tests are often the cause for a “long-running build”.

  • Add some horsepower - Increase your CPU speed, disk speed, and/or your RAM. This is often a cost-effective and quick solution to the problem.
  • Stage your Builds - Run a quick commit build that consists of compilation, fast-running automated tests (i.e. unit tests without heavy dependencies), and deployment. After this commit build succeeds, run a slower-running tests, full database integration, inspections, and installation (depending on your build)
  • Categorize your Tests - Segment your unit, component, system, functional, etc. tests so that you can run them at different frequencies
  • Run Tasks in Parallel - Run certain build tasks in parallel - such as tests. This can only work if the result status of one task is mutually exclusive to another

As I mentioned, this is only a high-level view on a difficult problem. There’s a lot more detail in the book addressing this issue. Depending on the situation, there are simpler and more difficult solutions than others.

CI Inspection Tools for Java

Friday, June 15th, 2007

Below, is a list of tools for running automated inspections (static and dynamic analysis) for the Java platform:

  • PMD - verify code is adhering to the project’s coding standards
  • CheckStyle - verify code is adhering to the project’s coding standards
  • CPD - Copy Paste Detector (part of PMD project)
  • Simian - Similarity Analyzer
  • JDepend - Object-oriented metrics for determining robustness of the architecture
  • JavaNCSS - tool for measuring cyclomatic complexity
  • SourceMonitor - tool for measuring cyclomatic complexity and general code metrics
  • Metrics - Eclipse plugin for gathering many types of code metrics
  • Coverlipse - code coverage tool for Eclipse
  • JDepend4Eclipse - JDepend plugin for Eclipse
  • Cobertura - Code Coverage tool
  • FindBugs - code metrics and analysis tool. Provides more advanced metrics than the “average” static analysis tools such as security warnings, etc.

In chapter 7, Continuous Inspection, we cover the practices, tools and techniques for discovering potential defects in your software.

CI Testing tools for .NET

Thursday, June 14th, 2007

In Chapter 6, Andy covers practices for automated testing tools. He uses plenty of examples for the Java and .NET platforms. Below, is a list of developer testing tools for .NET:

  • NUnit - unit testing tool for .NET
  • NMock - Dynamic mock object library for .NET
  • NUnitASP - tool for automatically testing ASP.NET web pages.
  • NDbUnit - seed your database to assist in component testing
  • Selenium - Web-based functional testing that is cross browser
  • Watir - Web-based functional testing for Internet Explorer

Separate your IDE from your Build

Wednesday, June 13th, 2007

The problem with using an IDE as the sole means to build your software (i.e. on your integration build machine) is that it’s unlikely your IDE will be deployed into production (or at least it shouldn’t be). One of the themes I visit in chapter 2 of the book is that of reducing assumptions (risks or whatever you want to call them). Many of the IDEs wrap everything but the kitchen sink into them (I won’t name any names), so if you assume that the particular files and configuration provided by the IDE are there, you are setting yourself up for problems. If you can’t script your build, be ready to debug problems right before you’re ready to release into production…or worse, when your users are using the software. As a developer, use your IDE to execute your automated build. However, your automated build should have no dependencies with your IDE. Separate build from IDE

Levent Gurses vidcast on Code Quality Plugins for Eclipse

Tuesday, June 12th, 2007

I interviewed Levent Gurses of Stelligent (the company I work for) over on Test Early in a vidcast where he gave a preview of his upcoming talk on code quality plugins for Eclipse that he is doing at the Better Software Conference in Las Vegas next week. He also blogged several times on the topic at Test Early providing detailed tutorials on JDepend4Eclipse, Coverlipse, CheckStyle, CheckStyle and Metrics plugins.