Zero downtime deployment¶
Zero downtime deployment is a deployment strategy aimed at updating software or services without causing service interruptions or unavailability for end-users.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md]
Blue/Green Deployment¶
Blue/Green Deployment is one of the most common methods used to achieve zero downtime.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md] This approach is characterized by its relative simplicity and stability, ensuring that multiple versions of the application do not need to coexist on the traffic line for an extended period.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md]
Characteristics¶
- Traffic switching: The core mechanism involves running two identical environments (the "Blue" and the "Green"). Initially, all traffic is routed to the active version (e.g., v1). Once the new version (v2) is fully ready, the traffic is switched from the old version to the new one.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md]
- Instantaneous switch: The transition is effectively instantaneous, preventing users from experiencing errors or timeouts during the update process.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md]
- Rollback capability: Because the old environment remains intact during the switch, rolling back is as simple as switching the traffic back, which facilitates rapid recovery if issues are detected.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md]
Resource Considerations¶
A primary disadvantage of the Blue/Green strategy is the requirement for system resources. Since both the old and new versions run simultaneously during the update process, the system must handle double the resource load (e.g., CPU, memory) for a short period.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md] While this resource intensity is a trade-off, the strategy is often considered worth the cost for the stability and time savings it provides, provided resources are not critically constrained.^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md]
Related Concepts¶
- Kubernetes
- [[Deployment]]
- [[Continuous Delivery]]
Sources¶
^[400-devops-06-kubernetes-k8s-ithelp-day14-readme.md]