Delivering Quality Software with Continuous Integration



Similar documents
Test Automation Tool comparison HP UFT/QTP vs. Selenium - Prashant Malhotra

Software Construction

Jenkins Continuous Build System. Jesse Bowes CSCI-5828 Spring 2012

Implementing Continuous Integration Testing Prepared by:

Software Continuous Integration & Delivery

Continuous Integration: A case study

Build management & Continuous integration. with Maven & Hudson

Global Software Change Management for PVCS Version Manager

Continuous Integration and Bamboo. Ryan Cutter CSCI Spring Semester

CONTINUOUS INTEGRATION

Reduced 30% of IT infrastructure & operations costs by automating infrastructure monitoring for a global wireless distributor

Pipeline Orchestration for Test Automation using Extended Buildbot Architecture

Practicing Continuous Delivery using Hudson. Winston Prakash Oracle Corporation

Continuous Integration

Continuous Integration Multi-Stage Builds for Quality Assurance

Leveraging Rational Team Concert's build capabilities for Continuous Integration

<Insert Picture Here> Introducing Hudson. Winston Prakash. Click to edit Master subtitle style

Introduction to Programming Tools. Anjana & Shankar September,2010

Software infrastructure for Java development projects

Continuous Integration (CI)

Continuous Integration

Continuous Integration with Jenkins. Coaching of Programming Teams (EDA270) J. Hembrink and P-G. Stenberg [dt08jh8

Continuous Integration

Kevin Lee Technical Consultant As part of a normal software build and release process

Continuous Integration: Improving Software Quality and Reducing Risk. Preetam Palwe Aftek Limited

Continuous Delivery. Alejandro Ruiz

SOFTWARE DEVELOPMENT BASICS SED

Continuous Integration in Kieker

Jenkins: The Definitive Guide

Continuous Integration. CSC 440: Software Engineering Slide #1

Beginners guide to continuous integration. Gilles QUERRET Riverside Software

Software Configuration Management Best Practices for Continuous Integration

WHITE PAPER. Getting started with Continuous Integration in software development. - Amruta Kumbhar, Madhavi Shailaja & Ravi Shankar Anupindi

GECKO Software. Introducing FACTORY SCHEMES. Adaptable software factory Patterns

Meister Going Beyond Maven

Continuous Integration on System z

White Paper. CCRM Services on Cloud Benefits of Private Cloud for CCRM Services. Abstract. - Krishna Vaddadi

Hudson Continous Integration Server. Stefan Saasen,

Continuous Integration For Real: The Perforce Java Platform. Hamish Reid Perforce Software Inc.

Aspire's Approach to Test Automation

Java Software Quality Tools and techniques

IKAN ALM and Collabnet TeamForge

Introduction to Agile Software Development Process. Software Development Life Cycles

Continuous integration End of the big bang integration era

Improving your Drupal Development workflow with Continuous Integration

Continuous Delivery for Alfresco Solutions. Satisfied customers and happy developers with!! Continuous Delivery!

Continuous Integration

Software Development In the Cloud Cloud management and ALM

We ( have extensive experience in enterprise and system architectures, system engineering, project management, and

Java Power Tools. John Ferguson Smart. ULB Darmstadt 1 PI. O'REILLY 4 Beijing Cambridge Farnham Koln Paris Sebastopol Taipei Tokyo

Distributed Agile Development in the Cloud

Accelerate Software Delivery

HP SAP. Where Development, Test and Operations meet. Application Lifecycle Management

Software Engineering I (02161)

GENiC. Deliverable D5.1 Development & Integration guidelines including integration environment & means. Dissemination Level: Public

Continuous Integration: Put it at the heart of your development

How Silk Central brings flexibility to agile development

Beginner s guide to continuous integration. Gilles QUERRET Riverside Software

Nexus Professional Whitepaper. Repository Management: Stages of Adoption

Automate Your Deployment with Bamboo, Drush and Features DrupalCamp Scotland, 9 th 10 th May 2014

Software configuration management

Software Configuration Management and Continuous Integration

Coverity Services. World-class professional services, technical support and training from the Coverity development testing experts

Continuous Integration Processes and SCM To Support Test Automation

IKAN ALM Architecture. Closing the Gap Enterprise-wide Application Lifecycle Management

Software Configuration Management (SCM)

Modern practices TIE-21100/

Continuous integration with Jenkins CI

Achieving Rolling Updates & Continuous Deployment with Zero Downtime

Efficient Automated Build and Deployment Framework with Parallel Process

Visual Studio - Continuous Integration

Content. Development Tools 2(63)

The Importance of Continuous Integration for Quality Assurance Teams

Continuous Integration Just another buzz word?

a new generation software test automation framework - CIVIM

INTRODUCING CONTINUOUS DELIVERY IN THE ENTERPRISE

Application Lifecycle Management White Paper. Source Code Management Best Practice: Applying Economic Logic to Migration ALM

Jenkins on Windows with StreamBase

Upping the game. Improving your software development process

LECTURES NOTES Organisational Aspects of Software Development

Automated build service to facilitate Continuous Delivery

Continuous Integration: Aspects in Automation and Configuration Management

Automated performance testing using Maven & JMeter. George Barnett, Atlassian Software

Maven the Beautiful City. Healthy, Viable, and Productive Build Infrastructures

Finally, an agile test strategy (that works)! AS OW Test Model, Objectware

Continuous Integration Comes to China.

"Build and Test in the Cloud "

IBM Rational Software

CPSC 491. Today: Source code control. Source Code (Version) Control. Exercise: g., no git, subversion, cvs, etc.)

Software Configuration Management. Context. Learning Objectives

Agile ALM. Lightweight tools and Agile strategies MANNING MICHAEL HUTTERMANN. Shelter Island

Transcription:

Delivering Quality Software with Continuous Integration 01 02 03 04 Unit Check- Test Review In 05 06 07 Build Deploy Test In the following pages we will discuss the approach and systems that together make up the process called Continuous Integration. This document is written for IT management who are looking to improve the quality of the software product or application their teams build. Introduction Software development continues to grow increasingly more complex. Even when dealing with dynamic languages like PHP, the systems being built today dwarf the systems of even five years ago. Many development teams however have not upgraded their development process and systems to meet the new demands. Today s teams must be well versed in the best practices of software development like source code control, unit testing, integration testing and documentation. These practices, when coupled together, form the basis of a Continuous Integration (CI) system. Continuous Integration is a term coined by Martin Fowler in a paper by the same name. Continuous Integration is a software development practice where members of a team integrate their work frequently; usually each person integrates at least daily - leading to multiple integrations per day. Every integration is verified by an automated build (including test) to detect integration errors as quickly as possible. Many teams find that this approach leads to significantly reduced integration problems and allows a team to develop cohesive software more rapidly"- Martin Fowler When multiple developers work in an integrated environment for the same software, it is obvious that the code can be messed up or overwritten by other people and hence the functionality can be broken. The developers will generally take a copy of source code into their systems for further development. On a defined timeframe developers will check in their files. This may result in code complication problems, source code conflict and unit test failure in the repository. Ideally each developer should check-out the latest code from repository, integrate it with their source code, build and run all unit tests before they check-in any code into the repository to ensure the stability of the build. This is an unorganized process with respect to the developers. They may miss to do the build every time. To avoid the manual errors, automated builds have been introduced.

CI helps in such scenario to ensure that the checked-in source code doesn't make any problems like broken code, unit test failure etc. Below are the potential problems that may occur if CI is not there in a project: Broken code injection there may be broken code in the repository which may merge to the developer s machine while synchronize with repository and this results in injection of defects. Unit Test Unit test failure Test cases fail if somebody check-in improper code. Synchronization Merge Developer may not realize the code checked-in by them is having compilation error. Build Broken build It is a serious issue when there is code checked-in to repository with compilation errors. Nobody will be able to run the application unless and until the compilation issue is resolved. But they will only come to know when individual do the build. The diagram below shows the product life cycle after the successful implementation of Continuous Integration. 70 50 Quality Product Stability Product Version 30 10 Cost per feature Development Product Complexity Cost per Bug Availability of Latest Build Frequency of Realease Productivity 0 10 20 30 40 50 60 70 80 90 100 Product Size (KLOC) Agile Development and CI In agile development, developers develop and check-in very frequently and it demands availability of working software every time. Agile equip to build the product incrementally and improve it as move on. CI is more suitable for agile development and is introduced to address few problems in agile development. CI in Agile development is helpful to minimize the duration and effort required by each integration episode and will be able to deliver "at any moment" a product version suitable for release.

Key Elements of CI A CI system usually consists of the following key elements: Maintain a single repository All developers check in code to a single repository from where the build has been taken periodically and look for errors. Automate the build The build process is automated to avoid manual errors in taking build. This helps people to get a better, faster and periodic build. Dashboard display on build reports to everybody All the builds happening on the server will be tracked and logged along with build report. This can be made available on a public dashboard where all the relevant people can have look at the reports. Self-tested builds A good way to catch bugs more quickly and efficiently is to include automated tests in the build process. The automated tests will run along with the build so that the builds become self-tested. Each developer commits the code to main repo every day The developers practice daily check-in to the repository at the end of the day. This helps other developers to integrate the code on a daily basis which more efficient than one time integration. Latest deployable build is available to everyone all the time A periodic build happens from the latest available source code and it creates deployable build which is available to everyone. The Add-on s of CI Automated review quality is one of the major areas of concern in many of the software products. The quality issues results in huge maintenance activities which consumes lot of time and cost. To resolve this, code review is being practiced in the development phase of software. However, manual review has its own disadvantages like issues in documentation of code, lack of visibility of the code issues to all stakeholders, challenges in maintaining history of code quality and last but not the least the time consuming process which leads to delay in delivery. To avoid the above stated problems, continuous code review process can be automated. There are tools like PMD, FindBugs available in the market to automate code review. This can be plugged into the CI process so that source code will be automatically reviewed along with build process. Automated test case execution Test driven development is one the important factor of extreme programming. Developers write test first and then develop code until all the written test cases are passed. This improves the code quality to a great extent and ensures that all the developed functionalities in the software are fully functional. TDD also helps to identify the defects faster. Automated test cases can be hooked into the CI process and it runs on every build. Release Automation The working software should be released on the desired environments properly with all the parameters accurately configured. This is another error-prone area where deployment can be broken because of the wrong configuration of parameters or improper deployment.

The deployment process can be automated and plugged to the CI so that once after the successful build, it will be deployed into the provided environment. Tools and frameworks that supports CI Hudson Hudson is a continuous integration (CI) tool written in Java, which runs in a servlet container, such as Apache Tomcat or the Glass- Fish application server. It supports SCM tools including CVS, Subversion, Git, Perforce, Clearcase and RTC, and can execute Apache Ant and Apache Maven based projects, as well as arbitrary shell scripts and Windows batch commands. CruiseControl CruiseControl is a Java-based framework for a continuous build process. It includes, but is not limited to, plugins for email notification, Ant, and various source control tools. A web interface is provided to view the details of the current and previous builds. It allows one to perform a continuous integration of any software development process. Jenkins Jenkins provides continuous integration services for software development. It is a server-based system running in a servlet container such as Apache Tomcat. The project was forked from Hudson. CI - Aspire s approach Aspire follows an approach called Producteering http://www.aspiresys.com/aspire-producteering TM to build products better, faster and innovate continuously. CI is one of the elements of Producteering that helps the team to excel on the engineering side. Producteering TM approach has a set of principles and practices, driven by the right people and supported by the right platforms. Aspire uses CI for the projects effectively. We also integrate automated code review, test cases and deployment along with CI. We ensure that every deliverable to the customer is processed through CI. Aspire uses the following tools to perform Continuous Integration: Jenkins - Using as CI Tool and integration platform for all other tools for code review, unit test etc., Jenkins also provides plugins to deploy the build to different servers. Sonar JUnits - Sonar is the automated code review tool which has built-in PMD and FindBugs tools integrated. Sonar generates an extensive code review report and dashboard of information about code quality and test coverage. - Creates unit tests using JUnits and automate it along with build process to ensure the functional coverage. The diagram below represents the process of Aspire s approach to CI using the tools mentioned above and our Technical Health Index process. Build Review CI THI Unit Testing

Conclusion From a technical perspective, CI helps teams work more efficiently. These teams can be cross-functional and develop software that works together. They can be geographically distributed, because the constant integration work will ensure that you don't get deviating codes. People can work on a large team, because the different components of a complex system will more assuredly work together. It solves many of the early pitfalls that these non-traditional agile teams might have experienced without CI. From a business perspective, CI offers better business results by allowing teams to have their cake and eat it too. That is, they can bring products to market faster, by finding issues early rather than at a later stage when they are large and more difficult to fix. They can also respond better to requirements that are introduced while the product is being developed. This creates a better product for the customer, which is the real promise of agility. About Author Sajeev Sreekantan is part of Java delivery unit. He has over 10 years of experience in IT industry and has performed various roles that cover complete software development life-cycle, and has also been consultant on Java/J2EE solutions to multinational companies. He is highly passionate about technologies and tools. About Aspire Aspire Systems is a global technology services firm serving as a trusted technology partner for our customers. We work with some of the world's most innovative enterprises and independent software vendors, helping them leverage technology and outsourcing in our specific areas of expertise. Our services include Product Engineering, Enterprise Transformation, Independent Testing Services and IT Infrastructure Support services Our core philosophy of "Attention. Always." communicates our belief in lavishing care and attention on our customers and employees. USA Aspire Systems, Inc. 1200 Harger Road Suite 602,Oak Brook, IL - 60523, USA Tel: +1-630-368-0970, +1-630-368-0973 Fax: +1-408-904-4591 E-mail: info@aspiresys.com ------------------------------ INDIA Aspire Systems (India) Pvt. Ltd. 1/D-1, SIPCOT IT PARK Siruseri, Chennai - 603 103 Tamil Nadu, India Tel: +91-44-6740 4000 Fax: +91-44-6740 4234 E-mail: info-india@aspiresys.com ------------------------------ UK Aspire Systems 1, Lyric Square, Hammersmith London - W6 0NB, UK Tel: +44 203 170 6115 E-mail: info@aspiresys.com