Node.js › Cloud & DevOps
What is a blue-green deployment, and how does it minimize downtime and risk when deploying a new version of a Node.js application?
AdvancedAnswer
Blue-green deployment maintains two identical environments -- the new version is deployed and tested against 'green' while 'blue' serves all live traffic, and once verified, traffic is switched instantly, with blue kept running briefly as an instant rollback target.
aws elbv2 modify-listener \
--listener-arn $LISTENER_ARN \
--default-actions Type=forward,TargetGroupArn=$GREEN_TARGET_GROUP_ARNReal-world example A payments API deploys an update to a parallel green environment, smoke-tests it while blue serves real traffic, and switches the load balancer to green only after verification passes.