I wanted to share an experience I had when using the Microsoft Azure Traffic Manager with 2 Microsoft Azure Web Sites.  If you are not clear on what the Traffic Manager does, read my other post here.  Simply, it is a way to balance load across multiple identical instances of an application so that requests can continue to be responded to when there is a performance issue or downtime incident on 1 or more of the web sites.  Kind of like the behaviour you would experience in a web farm, but better, IMO.

As shown in Figure 1, I have created a Traffic Manager and added 2 Microsoft Azure Web Sites (MAWS) to it.

Figure 1, A Microsoft Azure Traffic Manager with two Microsoft Azure Web Sites

I can also do an NSLOOKUP command for the traffic manager as illustrated in Figure 2.

Figure 2, doing an NSLOOKUP on the traffic manager

What I see in Figure 2 is the results of the NSLOOKUP for the traffic manager, plus one of the MAWS linked to it.  Why do I see only one?  If you look on the CONFIGURE page for the traffic manager, as shown in Figure 3, you will see that IISLOGS is the first MAWS in the FAILOVER PRIORITY LIST.  What I have found is that in a scenario where the LOAD BALANCING METHOD is FAILOVER, that this is the location where requests are sent to.  Don’t confuse this with a ROUND ROBIN or PERFORMACE configuration.  This is the FAILOVER solution.

Figure 3, Traffic Manager FAILOVER PRIORITY LIST for Microsoft Azure Web Sites

If you change the FAILOVER PRIORITY LIST order as shown in Figure 4, then perform a NSLOOKUP again, as shown in Figure 5, you will notice the change in the link between the traffic manager and the MAWS.

Figure 4, change FAILOVER PRIORITY LIST for a traffic manager

Figure 5, different MAWS linked to traffic manager

To test, I access the traffic manager URL and am redirected to the RASKULLS MAWS as expected.  Next I shutdown that MAWS using the Windows Azure PowerShell command STOP-AZUREWEBSITE as shown in Figure 6 and the Microsoft Azure Console in Figure 7.

Figure 6, stop a Microsoft Azure Web Site using Windows Azure PowerShell

NOTE: Prior to shutting down the RASKULLS MAWS, if I turn off IISLOGS, I would not expect any impact.  

When I access the traffic manager URL again I am indeed redirected to that IISLOGS website.  This is exactly the way I would expect the FAILOVER configuration to work.

Figure 7, a stopped Microsoft Azure Web Site on the Traffic Manager page