Book Image

Learning Continuous Integration with Jenkins - Second Edition

By : Nikhil Pathania
Book Image

Learning Continuous Integration with Jenkins - Second Edition

By: Nikhil Pathania

Overview of this book

In past few years, agile software development has seen tremendous growth. There is a huge demand for software delivery solutions that are fast yet flexible to numerous amendments. As a result, Continuous Integration (CI) and Continuous Delivery (CD) methodologies are gaining popularity. This book starts off by explaining the concepts of CI and its significance in the Agile. Next, you'll learn how to configure and set up Jenkins in many different ways. The book exploits the concept of "pipeline as code" and various other features introduced in the Jenkins 2.x release to their full potential. We also talk in detail about the new Jenkins Blue Ocean interface and the features that help to quickly and easily create a CI pipeline. Then we dive into the various features offered by Jenkins one by one, exploiting them for CI and CD. Jenkins' core functionality and flexibility allows it to fit in a variety of environments and can help streamline the development process for all stakeholders. Next, you'll be introduced to CD and will learn how to achieve it using Jenkins. Through this book's wealth of best practices and real-world tips, you'll discover how easy it is to implement CI and CD using Jenkins.
Table of Contents (18 chapters)
Title Page
Credits
About the Author
About the Reviewer
www.PacktPub.com
Customer Feedback
Preface
Index

Agile to the rescue


The name Agile rightly suggests quick and easy. Agile is a collection of methods where software is developed through collaboration among self-organized teams. The principles behind agile are incremental, quick, flexible software development, and it promotes adaptive planning.

The Agile software development process is an alternative to the traditional software development processes discussed earlier.

The twelve agile principles

The following are the twelve principles of the agile model:

  • Customer satisfaction through early and continuous delivery of useful software.
  • Welcome changing requirements, even late in development.
  • Working software is frequently delivered (in weeks, rather than months).
  • Close daily cooperation between businesses, people, and developers.
  • Projects are built around motivated individuals, who should be trusted.
  • Face-to-face conversation is the best form of communication (co-location).
  • Working software is the principal measure of progress.
  • Sustainable development—able to maintain a constant pace.
  • Continuous attention to technical excellence and good design.
  • Simplicity—the art of maximizing the amount of work not done—is essential.
  • Self-organizing teams.
  • Regular adaptation to changing circumstances.

Note

To know more about the Agile principles visit the link: http://www.agilemanifesto.org.

The twelve principles of Agile software development indicate the expectations of the current software industry and its advantages over the Waterfall model.

How does the Agile software development process work?

In the Agile software development process, the whole software application is split into multiple features or modules. These features are delivered in iterations. Each iteration lasts for three weeks, and involves cross-functional teams that work simultaneously in various areas, such as planning, requirement analysis, designing, coding, unit testing, and acceptance testing.

As a result, no person sits idle at any given point in time. This is quite different from the Waterfall model wherein while the development team is busy developing the software, the testing team, the production team, and everyone else is idle or underutilized. The following diagram illustrates the Agile model of software development:

Agile methodology

From the preceding diagram, we can see that there is no time spent on requirement analysis or design. Instead, a very high-level plan is prepared, just enough to outline the scope of the project.

The team then goes through a series of iterations. Iteration can be classified as time frames, each lasting for a month or even a week in some mature projects. In this duration, a project team develops and tests features. The goal is to develop, test, and release a feature in a single iteration. At the end of the iteration, the feature goes for a demo. If the clients like it, then the feature goes live. But, if it gets rejected, the feature is taken as a backlog, re-prioritized, and again worked upon in the consecutive iteration.

There is also a possibility of parallel development and testing. In a single iteration, one can develop and test more than one feature in parallel.

Advantages of Agile software development process

Let us see some of the advantages of the Agile software development process:

  • Functionality can be developed and demonstrated rapidly: In an agile process, the software project is divided by features, and each feature is called as a backlog. The idea is to develop either a single or a set of features right from its conceptualization till its deployment, in a week or a month. This puts at least a feature or two on the customer's plate, which they can then start using.
  • Resource requirement is less: In Agile, there are no separate development and testing teams. Neither is there a build or release team, or a deployment team. In Agile, a single project team contains around eight members. Each member of the team is capable of doing everything.
  • Promotes teamwork and cross-training: Since there is a small team of about eight members, the team members switch their roles in turns and learn from each other's experience.
  • Suitable for projects where requirements frequently change: In an Agile model of software development, the complete software is divided into features, and each feature is developed and delivered in a short time span. Hence, changing the feature, or even completely discarding it, doesn't affect the whole project.
  • Minimalistic documentation: This methodology focuses primarily on delivering working software quickly, rather than creating huge documents. Documentation exists, but it's limited to the overall functionality.
  • Little or no planning required: Since features are developed one after the other in a short period, there is no need for extensive planning.
  • Parallel development: Iteration consists of one or more features developed in sequence, or even in parallel.