Java Reference
In-Depth Information
Let's move on and take a look at another continuous integration server called Hud-
son. After we've covered both of them, you can compare them and choose whichever
one you want to use.
11.3
Another neat tool—Hudson
As we mentioned in the beginning of the chapter, CruiseControl was probably one of
the first continuous integration servers available. But there are a whole bunch of other
software tools out there, trying to compete with CruiseControl by introducing some
interesting new features. Some of those tools aren't even free (like AntHill Pro, Hud-
son, or Cruise 4 ), and those include not only the product you purchase but also training
and support.
For the sake of completeness, we need to cover another tool. This way you can
choose whichever tool you like. Remember, your software quality will improve not
from the tool you choose to use but rather from the fact that you decided to practice
continuous integration!
11.3.1
Introducing Hudson
Hudson ( http://hudson-ci.org /) is an open source project for continuous build. Like
any other software for continuous build, it's based on the idea of being able to contin-
uously poll the source code from the source control system and, in case it detects
changes, to fire up a build. Why do we cover it in this chapter? First, because it has
become popular, and second, because it's very different from CruiseControl.
11.3.2
Installation
Before installing Hudson, make sure you have J2SE version 1.5 or higher already
installed. Also make sure your JAVA_HOME environment variable points to where you've
installed Java.
The installation procedure itself is easy. You go to the project's website and down-
load the latest version of Hudson. At the time this topic is being written, the latest ver-
sion is 1.352. The Hudson distribution comes as a single WAR file, as opposed to
CruiseControl, where the distribution is a zip. You don't need to extract the WAR file,
because Hudson comes with a Winstone servlet container. You can start the server
from the command line with the following command:
java -jar hudson.war --httpPort=8888
Note first that we start Hudson on a port other than 8080 (simply because the exam-
ples in the topic require this port to be free), and second, if you start Hudson this way,
all of your logs will go to the console.
In order to start using the server, you need to navigate to http://localhost:8888 /. If
no errors occur, you should see something similar to what is shown in figure 11.5.
4
Cruise and CruiseControl aren't the same! Although they both originated from the same company, Thought-
Works, CruiseControl was open sourced and is free to use. Cruise is still commercial software.
 
 
 
 
 
 
 
 
Search WWH ::




Custom Search