What Is Zero Downtime Deployment?

Jun 21, 2022
-minute read

Introduction

Companies that are able to have 100% uptime tend to have a leg up over the competition. They therefore can’t risk having any downtime, as this period offline can be harmful to their revenue, customer loyalty, and ultimately their bottom line.

 

Concern regarding downtime is one of the major reasons that companies may be hesitant about implementing changes to their applications and services, including minor updates. Should you keep a current/old version so that users won’t lose access, or should you launch the new version but risk pushing users away to the competition while you make updates?

 

This is where zero downtime deployment comes in. Companies can launch new versions of their applications and services without needing to have any downtime during the process.

What Is Zero Downtime Deployment?

Whether you’re migrating your ecosystem to a new infrastructure and need to bring your entire database over (this would be zero downtime migration – more on that later), or launching a new version of your application, zero downtime deployment (ZDD) lets you complete the process from start to finish without any downtime that would otherwise impact your users’ experience and thus your revenue.

 

Zero Downtime Deployment: The Basics

There are numerous ways for IT teams to facilitate deployments of applications, and ZDD is just one of them.

 

One of the main characteristics of ZDD is that it’s done in such a way that the user is not aware of any downtime taking place while you deploy the new version of the application on your network. This means that the web server doesn’t release the altered code or the changes until the entire deployment is complete.

 

And as this is a task that companies have to do more often than most users realize, continuously running successful ZDD is an essential part of maintaining company reputation with customers. This is because customers expect companies to be up and running 24 hours a day, seven days a week, 365 days a year. At the same time, they expect applications to work efficiently without any bugs. This is why ZDD is so important.

 

The Difference Between Zero Downtime Deployment and Zero Downtime Migration

In addition to ZDD, there’s also zero downtime migration (ZDM). Although the two work similarly, ZDD refers primarily to zero downtime for new applications and/or services, while ZDM refers to zero downtime for migrating from one ecosystem to another.

 

For instance, when a company wants to migrate from its legacy/on-premise infrastructure to a cloud or hybrid infrastructure, this can be a big overhaul that makes C-level leaders hesitant about making the leap. However, ZDM can allow the company to transition without preventing its users from interacting with its services during the process.

 

Examples of Zero Downtime Deployment

Any industry that operates in the digital space would benefit from ZDD. After all, how frustrating is it when you try to access an app you use regularly, only to find that the app or website is “conducting maintenance”. Now what? You may go to the competition.

 

But there are certain industries that rely on this version of deployment more so than others, such as banks, ecommerce (especially during the holiday season), communication, fintech, and security companies. Some examples of ZDD in these contexts are:

 

  • A bank needs to update its website but needs to make sure users can still log in to their accounts during this process. If they can’t, they may choose another bank.

  • A retail website needs to update its payments page, but Black Friday is around the corner and the company cannot risk any downtime. If it does, its users may shop elsewhere.

  • A video call company requires automatic software updates, but the updates can’t impact the millions of calls their users need to have. These services need updates frequently, and users who have to spend time doing updates might go to another platform.

  • A ride-sharing app requires an update, but if there is downtime, users may book a ride with another service because they can’t wait for the updates to complete.

 

So what does ZDD actually look like from the front end? Well, not much – and that’s the point. From the user’s point of view, successful ZDD means they’ll barely notice that something is happening, until maybe they’re on the next screen and they’ll think, “Hey, this looks different than I remember!” Or, maybe the app was a little slow for a few moments. Whatever the case, it won’t be very apparent.

The Benefits of Zero Downtime Deployment

While some of the benefits of ZDD are clear, there are also less obvious advantages that are important to recognize. These benefits include:

 

Immediate action: If you recognize problems with your current application or service, ZDD allows you to take immediate action to address it, without the burden of creating a whole new version every time there’s a minor bug.

 

No time wasted: Any time an application gets a bug that slows it down, or the application is simply in need of improvement, a deployment might need to happen to fix that version of the application. Some companies may put these fixes on the backburner because they know that the deployment can only upset customers further. But with ZDD, you can make any updates whenever you need to, all while keeping a loyal customer base.

 

Peace of mind and automation: ZDD can be automated, which means it can do its job of running in the background while you focus on other tasks, saving you even more time and resources.

 

The Downside of Zero Downtime Deployment

All this considered, there are some downsides to ZDD, though they are generally few and far between. The main catch is that because there is no downtime, two flows of code need to be running simultaneously: the one that’s keeping the current version of the app running in the meantime, and the new one that you’re working on to deploy.

 

These two versions need to be able to function at the same time, because if you remove a line of code from one side, it will impact the other side and can result in errors, which may require fixing and thus lead to the downtime you’re trying to avoid. This means that you’ll have to run many small deployments at once so they carry over without having a big, noticeable impact for your users.

 

 

The good news? Because ZDD requires you to do a little bit at once, this can actually help you accomplish big items on your to-do list, even though this may happen in various stages. Now, you don’t have to worry about having so many tasks or processes in the pipeline, as you can initiate a deployment even when small changes or updates need to be made to your applications.

 

This also means you can easily notice any problems and fix them quickly, versus doing a massive deployment that shuts down the app and may take longer to complete because it’s a much more complex process.

How to Achieve Zero Downtime Deployment

Though the approach to ZDD might vary depending on your infrastructure or what you’re attempting to deploy, the technique used for ZDD is generally the same across the board, This technique boils down to what’s called a “blue-green deployment.”

 

What is Blue-green Deployment?

Blue-green deployment involves gradually migrating traffic from the current version of the application to the newer version (which should be very similar to the current version – remember, you’re only making small changes to code at once). These two versions need to be running at the same time, essentially in parallel.

 

If you want to get a vision of what this looks like when you break it down step-by-step, it goes something like this:

 

Step 1: Create the new version of your application that you want to deploy.

Step 2: Deploy the new version of your application or service simultaneously with the current version.

Step 3: Gradually migrate traffic and/or your database/users to the new version of the application.

Step 4: When the new version is up and running/fully deployed, you can shut down the first version of your application or service, as long as any traffic to that version is being directed to the new one. 

 

Zero Downtime Deployment Best Practices

Blue-green deployment is one of the best ways to accomplish ZDD. And although this technique may be straightforward, there are some best practices for ZDD in general that are important to consider:

 

  • Always test for changes as you conduct your deployment. This helps move along the process and prevent any problems from arising when the new version is finally deployed.

  • Ensure there’s a strong communication channel during deployment to avoid any roadblocks due to communication breakdowns.

  • Document any code changes, renames, or bug fixes to keep track and make it easy to go back to any steps or versions if needed.

The Bottom Line

ZDD is the best way to keep your applications up to date while ensuring your users don’t lose access to those applications in the meantime. If that were to happen, it could be a real issue for your company’s revenue, consumer loyalty, and competitive advantage. Meanwhile, when it comes to ZDM, Ping has helped many organizations migrate resources, especially when migrating to the cloud. This has become even easier with our new orchestration service, PingOne DaVinci.

 

And although it may take some time to implement ZDD to the point where it’s automated, you’ll be glad you did when it’s all said and done.

 

Share this Article:
Related Resources

Start Today

See how Ping can help you deliver secure employee, partner, and customer experiences in a rapidly evolving digital world.