Do you lead a technology team? Have you been asked to produce more features in less time? Is your team expected to deliver more functionality to business users at lower cost levels?
Hi, I’m Peter Nichol, Data Science CIO.
What is CI/CD?
Today, I’m going to share some insights on how to do precisely that. The concept is called CI/CD, or continuous integration and either continuous delivery or continuous deployment. There are three steps in this model: continuous integration, continuous delivery, and continuous deployment.
Continuous integration means that multiple developers can work in an environment simultaneously. Continuous delivery means that when a piece of functionality has been coded, it automatically goes into a registry and is tested immediately, without any extra intervention. Finally, continuous deployment means that releases automatically go into production once they pass a predefined testing threshold.
The intent of designing a CI/CD pipeline is to automate the application-software delivery process to get functionality out quicker, more effectively, and at lower costs. Although there are many reasons to begin a CI/CD initiative, let’s look at the main reasons for driving a CI/CD orchestration and automation business case.
To recap:
- Continuous integration = multiple developers working together
- Continuous delivery = changes automatically uploaded and tested
- Continuous deployment = automatic deployment once code passes testing
How does a CI/CD pipeline benefit business users?
There are a lot of benefits to building a continuous-delivery pipeline.
The first and most apparent benefit is automation. By automating and streamlining your pipeline, you save costs and free up resources to do higher-value work.
The second is continuous testing. Instead of engaging in testing and starting that process, much of the CI/CD environment testing is automated. It happens automatically without human intervention.
The third is accelerated and consistent delivery. It’s essential to make sure that deployments are moving to production as fast as reasonably possible. We have to be careful to remove roadblocks that others might have added. For example, we need to remove extra approvals or any dependencies or hindrances that would prevent functionality from reaching end users once it’s been validated to be working effectively. Once code has passed our defined threshold, we want that functionality immediately available for our user base. This is what’s meant by a continuous CI/CD pipeline. We often hear that almost every environment has a pipeline, and they are fully automated. I don’t believe it. Start asking questions of your engineering teams, and you’ll realize that more of your release—not less—is manually orchestrated.
How does continuous integration work?
One of the most important concepts involved in designing effective CI/CD pipelines is continuous integration.
The idea around continuous integration is to ensure you’re able to release functionality constantly. Continuous-integration environments are designed to support multiple developers working on the same code base at the same time.
This means developers continually update code, merge different code branches, and consolidate and tweak their code. This way, they ensure that all that functionality works at the same time. This process, while tedious, decreases integration testing at the end of the process—in effect, shortening the lifecycle to move code into production (build, test, deploy).
Huge benefits result when this process works seamlessly. The testing process is accelerated, and the time saved ultimately speeds up the overall deployment process. If things are working, that’s great. We quickly move that functionality into production. However, if things aren’t working or appear broken, we’re going to remediate that functionality and codebase immediately. The benefit here is we’re not having a QA test when we know things don’t work. We’re saving end-to-end time in our pipeline.
With continuous delivery, we’re trying to get functionality tested as quickly as possible. We’re not waiting for QA or testing to pick up where developers left off. Instead, the process flows continuously.
Here’s specifically where the work gets done:
- Continuous integration: build, test, merge
- Continuous delivery: auto release to repository
- Continuous deployment: auto deploy to production
What’s the bottom line?
As with continuous-delivery the concept of continuous-deployment, is to get as much functionality live as possible once it’s working. Continuous delivery automatically moves code into a repository and continuous deployment moves it into a production region—a region available to users to consume. That might not be your final destination. It might be a staging location or an interim environment. But it’s trying to get that functionality out as quickly as possible.
There are tons of CI/CD products to explore—from Jenkins to Travis CI. Here are some of the big hitters.
- CircleCI: rapid software publishing, runs using containers or virtual machines, easy debugging, very customizable.
- TeamCity: JetBrain’s build-management and continuous-integration server, runs in Java, integrates with Visual Studio and IDEs
- Bamboo: a continuous-integration server, automates software releases, runs batches of tests in parallel, quick feedback, creates images and pushes it into a registry
- Codeship: hosted platform, multiple deployments, easy select AWS instances, size, CPUs, and memory
- Wercker: docker based, microservices, GIT integrations, GitHub, GitLab
As you consider leveraging CI/CD pipelines in your environment, remember, don’t get bogged down in the details. The entire purpose of automating your development pipeline is to get functionality out to your end-users faster, more efficiently, and at a lower cost.
If you found this article helpful, that’s great! Also, check out my books, Think Lead Disrupt and Leading with Value. They were published in early 2021 and are available on Amazon and at http://www.datsciencecio.com/shop for author-signed copies!
Hi, I’m Peter Nichol, Data Science CIO. Have a great day!