The Best Continuous Integration Tools
In modern enterprise development, a complex project scope is very common. In this article, I will talk about the latest continuous instigation tools such as Apache's Continuum, Cruise Control (CC), and Hudson; all of them are designed to deal with project complexity, streamline build process, and report issues with the code as soon as they occur. They are perfect for use in an enterprise environment with large to medium size teams, may require a dedicated machine, and provide visual dashboards. These tools also enforce the process of continuous integration and are tightly coupled with a source control system, such as CVS, Subversion, and so forth. They may also simplify code maintenance and reduce the number of the issues that need to be fixed during the QA cycles.
The Continuous Integration Process Defined
The term "continuous integration" refers to a process that builds and tests code on a frequent basis. It was coined by Martin Fowler and Kent Beck, who first wrote about this process near the turn of the millennium.
The continuous integration servers constantly monitor source code repositories and as soon as new changes/commits are detected, they initiate a new build cycle. The build cycle actually involves code compilation and, in addition, may involve various tests and code analysis. If the process encounters errors, it may notify the build master or the culprit who checked in broken/invalid code.
The process can be summarized in these four steps:
- Team members check in code artifacts into the source control repository.
- The automated build server constantly monitors the repository.
- New code is continuously checked out [by this server].
- A new project build is continuously integrated and any issues are reported in real time.
There is much more to this concept and to the actual implementation of these automated build servers&mdahs;or continuous integration tools—such as definitions of best practices for the code structure, check-in locations, and so on. For instance, the process specifies that all working code should be in the main branch (trunk) of the code repository, and even though various tools can work with multiple branches, it is not recommended to do that.
Continuous Integration Tools
All continuous integration tools consist of a core engine that is designed to monitor and check out various artifacts that are needed to build the project from the source repository. On top of that, some tools can run automated scripts that can be extended to do much more robust functions then just code compilation.
For example, if the tool can run ANT scripts, developers may write their own script to FTP successful builds to a specific location, at the end of the build cycle.
Figure 1: Hudson Ant Configuration
The core of any continuous integration server is usually exposed via a UI control panel or dashboard (web-based or stand alone). Depending on the vendor, the tools also can offer other features, such as analysis of the code, execution of ANT scripts, configuration via command line or XML, statistics on the code quality, RSS feeds to see various processes and their outcome, and email functionality on the status of the build to the build master or specific people who broke the code.
As I mentioned, most of these tools support and tightly integrate with the most popular source control repositories, such as CVS, Subversion, SourceSafe, and the like to continuously monitor for the new code changes.
Cruise Control, Continuum, and Hudson
The most popular tools are Apache's Continuum, Cruise Control (CC), and Hudson. They are all free open source tools and have varying developer base support. All three tools have the ability to build and test code per a configurable schedule.
Hudson and Apache's Continuum are primarily designed for Java, and Cruise Control (CC) supports both Java and .Net (with the CC.Net version). Because these tools are designed to be very flexible, it's possible to extend them to support build processes in other development languages. For example, Hudson can be extended via plug-ins to work with C#, Python, Maven, Ruby, and others.
Cruise Control (CC)
Cruise Control is a free continuous integration tool designed for Java, but there is a version designed for .NET as well (Cruise Control .Net). All configurations are done via an XML file and there is a web dashboard component that can be installed to view the build progress. Compared to the other tools, CC does not have a configuration UI. This means that you have to look for special editors that can work with CC's config file if you don't want to edit XML by hand. (You can install CCNetConfig program, which helps somewhat with the XML writing). CC also has the most primitive web UI, and high learning curve; however, once installed and properly configured, it proves to be very powerful.
Figure 2: Cruise Control. NET (CC) build dashboard
Page 1 of 4