Jeremy Punsalan

Senior Software Engineer

Software Engineering Manager

Freelancer

Jeremy Punsalan

Senior Software Engineer

Software Engineering Manager

Freelancer

Blog Post

The Three Golden Rules of Deployment

March 13, 2021 Design Tips
golden rules

In the company that I am working for, during the training I was introduced to this "three golden rules" that every software engineers should follow when deploying new features into Production.

Following on this article that I read regarding GCash using Alibaba Cloud Solutions to address rapid growth of demands of their customer base (see article here), I figured they might have these sets of rules to follow when deploying to Production.
Anyway, during my training, there are 3 golden rules that were taught to us that all engineers should follow. And these are Monitoring, Revert, and Grayscaling.

These 3 concepts are not new to Software Engineering. I bet that even before, we are already using these processes. But this is something that needs to be pushed together in order to have a safer and smarter deployment.

Application Monitoring

cloudmonitor

During our pre-cloud Software Development era, when we need to monitor our web application, we are heavily reliant on Ops team to provide us the insights of the application health and if there are issues need to investigate, we need them to dump us with lots and lots of logs.
With the rise of DevOps and Cloud Services, we can now create our monitoring pages based on our service needs. With the help of Cloud Services like AWS’s CloudWatch, Alibaba’s CloudMonitor or even GCP’s Cloud Monitoring, creating monitor dashboards even as Software Engineer will be as easy. Since these are mostly still based on application logs, the dashboard can be customized based on the application logic.

Thus said, in every new feature added to the application, there should be a monitoring dashboard created before deployment.

Application Revert (AKA Rollback)

This concept is as old as the first legacy application. All software development life cycle includes rollback (or revert) plan. This includes any instruction on what to rollback (db scripts to run, configs to rollback or even application itself to rollback to previous version).

Due to the rapid application development supported by Cloud Infrastructure, we can always rollback any application or services that we deployed as quick as possible. Today the Platform-As-A-Service (PaaS) can help on rollback procedure by providing previous versions of the application and it can automatically revert the deployment.

Application Grayscaling

Grayscale strategy — or also known as canary deployment — is one of version update strategy where we control the traffic flow to the new version of the application changes. This means that a small percentage of users will have the new experience based on parameters such as customer mobile no, or geographical parameters such as location. 

Moreover, grayscale deployment can be associated with rolling deployment, where the small percentage of traffic will roll into bigger one based on the deployment plan. In this way, if there are errors or issues on the new version, only small percentage will be affected and the rollback can be initiated right away. Then the team can increase the traffic once verified.

Why these three are important on Application Deployment?

Application deployment failure can happen in a given point of time in our lives. To lessen the impact of affected services to the customers or end users, we want to utilize these strategies in order for our application to be highly available — which is one of the key criteria of a scalable application.

Thank you for visiting my site! If you have questions, you may email me at jeremy@punsalan.net.

Write a comment