0

I am using a function app (new to me as well as the ServiceClient) to import data into D365 Online from a simple sharepoint excel file. The idea is that this function app will allow multiple creations.

I am using DI and trying to increase the throughput of insertions into dynamics by using parallel.froeachasync or task.whenall.

I am receiving in some instance - AADSTS50196: The server terminated an operation because it encountered a client request loop error:

One or more errors occurred. (Your app has been throttled by AAD due to too many requests. To avoid this, cache your tokens see https://aka.ms/msal-net-throttling.)'

enter image description here

Microsoft.PowerPlatform.Dataverse.Client.Utils.DataverseConnectionException: 'One or more errors occurred. (Your app has been throttled by AAD due to too many requests. To avoid this, cache your tokens see https://aka.ms/msal-net-throttling.)'

Any help would be great.

Added singleton and that haas helped but throughput falls even using ParallelForEach or task.whenall.

I would like to keep the high throughput but still maintain data integrity?

TheNerdyNerd
  • 237
  • 2
  • 9
  • Figured it out - you should not use OAuth as the credential but use ClientSecret to have this work. If you need help on setting that up let me know. – TheNerdyNerd May 15 '23 at 10:01

0 Answers0