您的位置:首页 >> 编程开发 >> Java >> J2EE >> 正文
J2EE RSS
 

Taking Continuous Integration to the Next Level @ JDJ

http://www.rdxx.com 05年08月10日 20:26 Java频道 我要投稿

关键词: JDJ , ATI , NT

Sometimes, the easiest and most rewarding part of development is the actual coding. Managers and developers often dismiss the building, deploying, testing, and metrics-gathering aspects of the software life cycle.

Continuous integration is the concept of automating the build cycle so that code is built and tested many times during the day. This allows developers to integrate their code into the build daily or hourly, thus lowering the chances of integration problems.

In this article, I introduce an Ant-based build and integration system called BigBrother that leverages XP (Extreme Programming) principles. BigBrother combines several open-source tools into a "continuous integration" system. I also offer a real-world scenario in which BigBrother was used to successfully manage a continuous build process.

The concept of continuous integration has been around for a long time and one of its biggest proponents is Extreme Programming. XP is a disciplined approach to software development that stresses communication, simplicity, feedback, and iterative design. One of the main coding practices of XP is to integrate often. The benefits of integrating code are numerous:

  • Developers are guaranteed to be working with the latest version of software.
  • Compatibility problems are more likely to be detected and avoided early.
  • Integration cycles that used to take days or weeks are reduced to minutes.
  • Communication between developers increases.
  • Integration bugs are found much sooner than later.

    Automating the build-and-test cycle definitely brings many benefits to any software development life cycle, but this only scratches the surface of what can be done by combining some of the open-source tools available today.

    Paradise Found
    With the advent of Java and open-source projects, creating and automating a continuously integrated environment has become simple, yet extremely powerful. These open-source projects include components for compiling and deploying code, executing automated unit tests, computing and displaying unit test code coverage, calculating various code metrics, as well as many other tools for making a project successful. All of these individual components can then be wrapped and automated with the help of yet other open-source projects.

    Using each of these tools by themselves is helpful in the development of software, but the real power is when you combine them into a single continuous integration environment that compiles, tests, and reports metrics on a code base every time a file is checked in. Imagine a development environment with the following features:

  • Project Web site with up-to-the-minute build information and code metrics.
  • Development team is notified of broken builds immediately and accountability is placed on the last person(s) to check in code.
  • Unit tests for the entire project are run automatically after every code change. Results of these tests are reported on the project Web site.
  • Code metrics are run after every code change, showing such things as Javadoc coverage, cyclomatic complexity of each method, and lines of code.

    共5页  1 2 3 4 5


  •  
     
    标签: JDJ , ATI , NT 打印本文
     
     
      热点搜索
     
     
     



    Valid XHTML 1.0 Transitional
    Copyright ©2005 - 2008 Rdxx.Com,All Rights Reserved
    收藏本页
    收藏本站