Firstly, apologies for the delayed response.
Based on my understanding of your issue from the description, when using Azure App Service with 3 instances and configuring it with Azure Front Door, it is generally recommended to disable session affinity (ARR Affinity) on the App Service and enable session affinity on the Front Door instead. This approach helps ensure that the session is pinned to a specific backend pool rather than a specific instance of the App Service.
By default, Azure App Service uses ARR (Application Request Routing) Affinity, which ensures that subsequent requests from the same client are routed to the same instance. This is useful for stateful applications where maintaining session state is crucial.
Just to highlight, some key points to consider:
- Enable Session Affinity: If your application depends on session state and needs subsequent requests from the same client to be directed to the same instance, it's important to enable session affinity in both Azure App Service and Azure Front Door.
- Disable Session Affinity: If your application is stateless or utilizes a distributed caching mechanism to manage session state, you can opt to disable session affinity. This enables Azure Front Door to evenly distribute requests across your instances, potentially enhancing both load balancing and fault tolerance.
Ref: Traffic routing methods to origin
Kindly let us know if you still have any specific questions.
If the answer helped (pointed, you in the right direction) > please click Accept Answer to benefit the community find answers quickly to similar question.