In this blog, lets get to know about traffic manager, how does it work and to configure it also. And we will also see how to manage incoming traffic for optimal application performance, and how to distribute traffic to Azure or external service endpoints.
What is Traffic Manager ?
Azure Traffic Manager is a DNS-based traffic load balancer which has the following features :
- Allows you to distribute traffic to your public facing applications across the global Azure regions
- Provides your public endpoints with high availability and quick responsiveness
- Uses DNS to direct the client requests to the appropriate service endpoint based on a traffic-routing method
- Provides health monitoring for every endpoint
- Is resilient to failure, including the failure of an entire Azure region
Now, lets create Traffic Manager profile
Login to your Azure portal, find traffic Manager in the search bar. Click on the “Traffic Manager profile” service.
Now, fill in your Traffic manager name, resource group and preferred routing method.
Wait for your resource to get created, then click on your Traffic Manager profile and configure the endpoints. I am taking here webapps as the endpoints here [ one is in West-Europe region and the other one is in North-Europe ].
Now configure your webapps in the endpoints one by one and keep the weight number same so that traffic can be distributed equally in both the regions. Fill in the required details as given in the image below.
Once this is done, go to configuration section from the left menu and configure protocol, port and path settings to monitor the endpoints.
Ok, we will now check the status of our endpoints configured in Traffic Manager in the endpoints section.
As you can see in the image above, the monitor status of our endpoints is “online”, that means we are good to go . 😉
Now lets test our traffic manager through curl command on the terminal and check the results. It will distribute the traffic in between the two regions within 60 seconds.
At this time, our Traffic Manager is fully setup and our infrastructure is highly available and resilient. Keep learning, Keep Rocking 🙂