What You Can Expect From Canary Deployment
A canary deployment is a method of rolling out a new feature to an early adopter group of users. A subset of customers will be asked to pilot the new features before they are made available to the general public.
You may choose individuals at random or pick a specific group, and if anything goes wrong, you can undo the decision. As long as everything is running well, you may add more users to the system while keeping an eye on the logs, errors, and general health of the software.
The history of the name and its origin
Canaries are very sensitive to gas and show visible distress when exposed to it. As an early warning system for potentially deadly chemicals like carbon monoxide (CO) and methane (CH4), canary birds were formerly used by coal miners in Australia, the United Kingdom, the United States, and Canada. The miners used canaries to forewarn them of danger before they saw it coming. This post is part of a series we’ve been writing on deploying software.
Instead of releasing canaries, they are deployed.
By splitting the stable and development branches, a canary release allows you to test an early version of the whole programme. The difference between stable and unstable releases of open-source software is often indicated by whether the version number is odd or even.
Companies often provide “canary” versions of their products for “early adopters” to download and try out. Firefox nightly builds and betas were made available by Mozilla, while Google included a “canary” channel into Chrome’s development process.
Canary deployments include the simultaneous installation of an update in a system and the separation of users into two groups. While a small percentage of users have upgraded to the canary build, the vast majority are still operating on the prior version. After the canary version has been tested, you can either revert to the previous version or migrate all users to the canary version.
How Canary Deployments Work
Here’s a rundown of what to expect during a canary rollout:
- In the beginning, all of the users’ attention is focused on the current version.
- The term “canary” refers to the practise of deploying a new version of software to a small subset of users before making the change available to the rest of the population.
- While the great majority of users will not be impacted by any of the tests that may be run on the newly released version (such as smoke tests), it is possible that some may.
- The current canary or the presently processed subset of traffic are both determined by an automated procedure.
Canary traffic (say, 5% of all traffic) is first directed to the new version, and if it works as expected, a larger proportion of live traffic will be sent to the new version, and so on for increasing percentages of canary traffic.
Conclusion
The service will be rolled back to the prior version if the newly released one proves to be troublesome. Most people using the service won’t even notice the difference. The canary version was deleted, and now everything is back to normal.