How To: Rolling Deployments with ElectricFlow
Jun. 14, 2017 02:30 PM
The full post can be found on the Electric Cloud blog.
ElectricFlow was designed to enable teams to streamline and to simplify their DevOps processes – from the most mundane automation workflows to the most complex and large-scale scenarios. As part of that, we’ve set to revolutionize one of the most nail-biting parts of software releases: deployments. Aiming to make this process as boring, repeatable and push-button as possible, ElectricFlow boasts the industry’s most robust deployment automation feature set, providing several out-of-the-box ways to deploy applications that are designed to take the stress, guess work, and complex, one-off, scripting out of the equation.
These include deployment options such as Smart Deploy, staging artifacts, and automatic error handling or process branching, as well as advanced deployment strategies and deployment policies such as rolling deployments, blue/green, canary, and dark launch. In the coming blog posts in this series, I’d like to describe some of the use cases for these deployment strategies, as well as step-by-step tutorials – which you can implement for your own deployments using our free community edition!
Why do we need advanced deployment strategies?
In most deployment scenarios applications are deployed by default to all the resources in the environment at once, and process steps are run sequentially. ElectricFlow allows you to customize how an application is deployed in various ways, for example:
- When modeling a process, you can define the error handling method for a process step or use automated rollback.
- Before deploying an application, you can stage artifacts to ensure that all the artifacts are available at runtime, reducing the deployment time.
- At runtime, you can deploy everything (full run), deploy only changed objects (Smart Deploy), or specific objects (partial run), and/or Snapshots.
In some use cases, you may prefer to deploy the application in batches, instead of deploying to all machines in the environment at once. Why? because a phased approach is often safer – to minimize possible service interruptions, or to test out new capabilities only on a sub-set of users.
As you get closer to Production environments and live user interaction and data, reducing risk and downtime when releasing newer versions becomes more critical. This is especially true with applications that service traffic 24/7 – where you can not afford (or even are legally prohibited) to take the application down for a longer ‘maintenance window’, or risk losing transactions from 27/4 customer traffic. In some cases, the applications are the backbone of the business – such as with online retail or banking/investment sites – and any downtime on the Production website can adversely affect the business.
This is when you’d consider phased deployments and advanced deployment strategies – such as Rolling Deployments, Blue/Green deployments, and more. ElectricFlow can greatly simplify those for you, enabling even small teams to deploy like the Etsy and Netflix of the world, with just a few clicks. ElectricFlow allows you to model these various deployment strategies and ‘practicing; them throughout the pipeline- from the lower environments all the way through to Production, making this process routine and safe. In short: making even the most complex deployments scenarios boring :)
To demonstrate how to use these deployment strategies in ElectricFlow, let’s start by jumping in to what’s considered the most difficult deployment pattern: Rolling deployments. Once you see how easy ElectricFlow makes this, the others will be a snap!
Continue reading for a step-by-step tutorial for rolling deployments with ElectricFlow!