BuildBot

From FIFE development wiki
Jump to: navigation, search

Contents

BuildBot

Overview

I have been asked to review a nice little piece of software called Buildbot [1] and determine if it would be beneficial to use with FIFE. For those that done know the BuildBot is a system to automate the compile/test cycle required by most software projects to validate code changes (I stole that from the website). The nice thing about BuildBot is that it's written in Python and can run on all platforms FIFE runs on. BuildBot comes in two pieces, the client and the server. The client would be installed on the target platform and connect to the BuildBot server. The client's wait for instructions from the server. These instructions can be any number of things but in FIFE's case would be to run "svn update" and "scons". The BuildBot client sends all output from all commands to the server and can be viewed by pointing your web browser at the server. BuildBot logs all builds and reports if it was successfull or not. BuildBot can be set up to notify developers or build managers via email or IRC.

Experiences using BuildBot for building FIFE

Configuring the BuildBot server was fairly simple. BuildBot ships with an example configuration file and has some pretty good documentation online. It took me about an hour to go through the entire configuration file and get the BuildBot server set up. I then went through the client configuration file and set up a BuildBot "bot" on my linux box. These "bots" can be set up on any platform and don't need to be local to the build server. I configured BuildBot to do an auto build every 24 hours. It also checks and logs source code updates. I configured it to check for updates in trunk but you can configure it to check every branch.

I've been running BuildBot for a few days now and haven't had any issues with it. Currently the client is set up to update FIFE's source from trunk and compile once a day. I have been watching it and everything runs smoothly. I did run into a problem where a build failed but the client automatically deleted it's local copy of the source and did a clean checkout of trunk and re-ran scons which fixed the problem. Needless to say I was pretty impressed the client was smart enough to do this.

I also tested BuildBot's notification capabilities. Everything works fine. You can be notified via email or IRC. I preferred email because I don't think everyone in IRC would really care about the status of a build on a Mac for example. I would think that the Mac build manager would want to be notified of a failed build though.

BuildBot also ships with a mini web-server that displays the status of the build clients (or bots) along with a log of builds and a log of source code changes. It doesn't look very nice but it has all the information build managers would care about.

Advantages of BuildBot

I can see several advantages for using BuildBot for FIFE.

First and foremost BuildBot would allow developers to receive feedback about their source code changes. When a developer makes a change he/she can be notified if the change broke a build on ANY platform. I don't know many FIFE developers that have access to all 3 target platforms so they wouldn't have to worry about testing a build on each platform.

Another advantage would be for MOD developers. Because BuildBot has the ability to be customized we could have BuildBot automatically upload the compiled FIFE library to a web server. We could also easily automate the packaging of FIFE for every platform. MOD developers could always be working with the newest FIFE library without having to compile FIFE on their local workstations.

Build managers roles would shift from building and packaging FIFE to maintaining the BuildBot clients. This is a very simple task. All they need is a workstation capable of compiling FIFE with scons on the required platform (with internet access of course).

Conclusion

Personally I would like to see BuildBot used for FIFE. Unfortunately it's one more thing to keep up and maintain. I already have a BuildBot server up and running for FIFE so adding build clients would be simple. I will continue to run the server for my own pleasure. If build managers feel like maintaining the client I'll be more than happy to help them set it up.

What does everyone else think?

Prock 21:37, 13 September 2007 (CEST)

Personal tools