You are previewing Hudson Continuous Integration in Practice.
O'Reilly logo
Hudson Continuous Integration in Practice

Book Description

Best Practices for Implementing Continuous Integration with Hudson Optimize productivity while reducing risk and complexity by adopting a highly agile, “automate everything” software design philosophy. Hudson Continuous Integration in Practice shows you how to streamline and stabilize each process in your development lifecycle. Get expert tips for deploying a Hudson server, managing test and reporting frameworks, using source code management (SCM), and incorporating third-party CI tools. Distributed builds, plugin development, and system administration are also covered in this Oracle Press guide.

  • Install, configure, and secure Hudson

  • Automate build, integration, release, and deployment processes
  • Set up jobs and add SCM from the Web-based GUI

  • Administer QA tools, issue trackers, and build notifiers
  • Incorporate IDEs, browsers, desktops, and mobile devices

  • Publish Hudson build artifacts to Oracle Middleware utilities
  • Work with plug-in manager and develop your own plugins

  • Create custom dashboards and organize your jobs with views
  • Develop a custom publisher, recorder, and notifier for your jobs

Table of Contents

  1. Cover 
  2. Title Page
  3. Copyright Page
  4. About the Authors
  5. Contents 
  6. Foreword
  7. Acknowledgments
  8. Introduction
  9. PART I: Essential Knowledge
    1. Chapter 1: Getting Started
      1. Installing Hudson
        1. Trying Hudson with the Easy Installation Method
        2. Installing Hudson as a Windows Service
        3. Installing Hudson to Start When a User Logs in to Mac OS X
        4. Installing Hudson Within Tomcat
        5. Installing Hudson on GNU/Linux
        6. Basic Hudson Configuration
        7. Your First Job: Back Everything Up
      2. Summary
    2. Chapter 2: Hudson Precondition Primer
      1. Hudson in the Software Development Lifecycle
        1. Developer
        2. Tester
        3. Manager
        4. Architect
        5. Release Engineer
        6. Example: Orchestration of Roles Around Hudson
      2. Software Development as Marionette Theatre Production
        1. Development Platforms
        2. Software Configuration Management
        3. Builders
      3. Integrated Development Environments
        1. Eclipse
        2. Oracle JDeveloper
        3. IntelliJ IDEA
        4. NetBeans
      4. Testing Tools
        1. Soft Correctness Testing Tools
      5. Summary
    3. Chapter 3: Basic Concepts
      1. Intermediate Hudson Configuration
        1. Adding Source Code Management (SCM) to Your Jobs
        2. Your Second Job: A Simple Java Program
        3. Your Third Job: A Simple Servlet
        4. Using the Plugin Center
        5. Your Fourth Job: Advanced Backup Options
        6. Hudson Authentication Security
        7. Adding Quality Assurance Systems
      2. Build Notifiers
        1. Configuring E-mail Server
        2. Configuring the Job to Send Build Status Message
      3. Summary
  10. PART II: Applying Hudson
    1. Chapter 4: Hudson as a Continuous Integration Server
      1. What Is Continuous Integration?
      2. Setting Up the CI Environment
      3. Sherwood County Library
        1. Sherwood Library Software Components
      4. Source Code Management
      5. Build Automation
        1. Maven as an Automated Build Tool
        2. Speeding Up the Build
        3. Managing the Upstream–Downstream Jobs Complexity
      6. Continuous Testing
        1. Types of Tests
        2. Viewing the Unit Test Results
        3. Test Result Trends
        4. Code Metrics and Code Coverage
      7. Continuous Feedback
        1. Extended E-mail Notification
      8. Continuous Delivery or Deployment
        1. Deploying a Java Application to an Applications Server
        2. Uploading Build Artifacts to Another Machine
        3. Executing Commands on a Remote Machine
      9. Summary
    2. Chapter 5: Hudson and Automated Testing
      1. Containing Code and Code Under Test
      2. A Quick Tour of the Maven Build Lifecycle
      3. Quick Code Jumpstart: Simple Servlet Testing
      4. Automated Testing: Shields Up!
        1. The Software Lineup
        2. Who Writes the Tests?
        3. Kinds of Tests
        4. Unit and Component Testing with Arquillian in Hudson
        5. Hudson Automated Testing Tips
      5. Summary
    3. Chapter 6: Hudson as Part of Your Tool Suite
      1. IDE Integration
        1. Creating a New Hudson Job Directly from a NetBeans Project
        2. Eclipse Hudson Integration
        3. IntelliJ IDEA Hudson Integration
        4. JDeveloper Hudson Integration
      2. Hudson Issue Tracker Integration
        1. Atlassian JIRA Integration
        2. Bugzilla Integration
        3. Other Issue Trackers
      3. Browser and Desktop Integration
        1. Browser Integration
        2. Desktop Integration
        3. Mobile Integration
      4. Publishing Build Artifacts from Hudson
        1. Artifact Repository
        2. Deploy to Container
        3. FTP Publisher Plugin
      5. Summary
    4. Chapter 7: Distributed Building Using Hudson
      1. Master-Slave Mode
        1. Hudson Slaves
        2. Types of Slaves
        3. Adding a Slave Node to Hudson
        4. Adding an Unmanaged Slave via JNLP Launcher
        5. Adding an SSH-Based Managed Slave
        6. Distributing the Builds
        7. Managing Slaves
      2. Summary
    5. Chapter 8: Basic Plugin Development
      1. Writing a HelloWorld Plugin
        1. Creating the Plugin Project
        2. Creating a Service Hook
        3. Building the Plugin
        4. Testing the Plugin
      2. HPI Tool
        1. Creating a Skeleton Plugin Project
        2. Building and Running the Plugin Project
        3. Testing the Skeleton Plugin
      3. Understanding the Hudson Plugin Framework
        1. What Is an Extension Point?
        2. Extending an Extension Point
        3. Examining the Sample Extension
        4. Modifying the Sample Extension
      4. Extension UI Configuration
        1. Configuration File Conventions
        2. Configuration UI Rendering
        3. Interaction Between UI and Model
        4. UI Validation
        5. Global UI Configuration
      5. Summary
  11. PART III: The Hudson Lifestyle
    1. Chapter 9: Advanced Plugin Development
      1. Extending Various Aspects of Hudson Dashboards
        1. Creating a Custom Rendered Jobs Status View
        2. Using the Custom Rendered View
        3. Adding a Custom Column to the Default View
        4. Adding an Action to the Action Panel of the Main Dashboard
        5. Custom Decoration of Hudson Pages
      2. Extending Various Aspects of a Hudson Job
        1. Adding a Custom Notifier to a Job
        2. Adding a Custom Link to a Job Dashboard
        3. Creating a Custom Build Wrapper
      3. Summary
    2. Chapter 10 Hudson Best Practices
      1. Manage the Hudson Resources Effectively
        1. Tune Memory
        2. Restrict Job History Depth
        3. Monitor the Disk Space
      2. Put Your Hudson Behind a Web Proxy
        1. Do Not Use Your Hudson as a File Server
        2. Periodically Back Up Your Hudson Contents
      3. Set Up a Fail-Safe Mode for Your Hudson
        1. Redundant Hudson Server Setup
        2. Monitoring Hudson Setup
        3. Server Switch on Failure
        4. Redirecting HTTP Traffic to a Redundant Server
      4. Scale Up the Security of Your Hudson
        1. Restrict Job Access to Certain Users
        2. Add Roles to the Authorization Matrix
      5. Upgrade Your Hudson Diligently
        1. Understand the Hudson Versioning Scheme
        2. Upgrade in a Sandbox First
      6. Summary
  12. PART IV: Appendixes
    1. Appendix A: Widely Used Hudson Plugins
    2. Appendix B: Personal Hudson Instance
      1. Hudson-as-Valet
        1. Optimal Hudson-as-Valet Setup
      2. Hudson for Work Area Maintenance
        1. The Open-Source Liaison Role
        2. The Committer Role
      3. Hudson as General-Purpose Scheduler
        1. Hudson Plot Plugin
      4. Summary
    3. Appendix C: Hudson for Windows Developers
      1. Key Enablers for Using Hudson on Non-Java Platforms
        1. Build Step
        2. Collect Results Step
      2. Hudson and the Windows Software Platform
        1. Hudson and Automated Testing on Windows
      3. Summary
  13. Index