azureazure-traffic-managerblue-green-deployment

Azure Traffic Manager and blue/green deployments


I found this blog post by Microsoft: https://azure.microsoft.com/en-us/blog/blue-green-deployments-using-azure-traffic-manager/

And am finding statements in that post contradict the Azure Traffic Manager Docs. Specifically, as suggested in the blog post, I am looking at using weighted routing and the blog post suggests that I can send 100% of traffic to one endpoint or the other (and by corollary, 0% of traffic to the other pod). But the docs say that the weight must be between 1 and 1000, and terraform plan confirms that weight values must be between 1 and 1000, so how do I get 100% of traffic going to the green pod and 0% going to the blue pod?

I get that 1/1000 is 0.1% of traffic, but that is still more than the desired 0%.


Solution

  • To stop all traffic why don't you just disable the endpoint. It is also offered as the solution in the post you mention:

    In this example we set the first endpoint Blue.contoso.com with a weight of 1,000 and the second endpoint Green.contoso.com with a weight of 1. This ensures that most of the traffic goes to Blue environment and only minimal traffic is routed to the Green environment. If you want to completely stop traffic to the Green environment you can disable the green.contoso.com endpoint. This is the initial state of the Blue-Green deployment.