You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// 1st call with regional auth set to trueawaitcca.AcquireTokenForClient(scopes).WithAzureRegion(true);// 2nd call to globalawaitcca.AcquireTokenForClient(scopes).WithAzureRegion(false);
Expected behavior
The 2nd call should go to global token endpoint.
Actual behavior
The 2nd call is going to regional token endpoint.
Possible Solution
This is happening because we are caching the network metadata with preferred network as the regional endpoint once the region is discovered for both the original authority and the authority created with the region.
Either cache the regional metadata separate, or cache it only for the regional authority.
The text was updated successfully, but these errors were encountered:
neha-bhargava
changed the title
[Bug] Once the region discovery is done calls with WithAzureRegion set to false also hit the regional token endpoint
[Bug] Once the region discovery is done calls with WithAzureRegion set to false should not hit the regional token endpoint
Dec 1, 2020
Marking it as P1 since the network metadata cache is a static cache and once the region is discovered we will be hitting the regional endpoint irrespective of the value for WithAzureRegion. This could cause problems if someone wants to fallback to global in case ests-r endpoint fails or if someone wants to rollout traffic to ests-r in phases.
Which Version of MSAL are you using ?
Latest
Repro
Expected behavior
The 2nd call should go to global token endpoint.
Actual behavior
The 2nd call is going to regional token endpoint.
Possible Solution
This is happening because we are caching the network metadata with preferred network as the regional endpoint once the region is discovered for both the original authority and the authority created with the region.
Either cache the regional metadata separate, or cache it only for the regional authority.
The text was updated successfully, but these errors were encountered: