microsoft / PowerPlatform-DataverseServiceClient

Code Replica for Microsoft.PowerPlatform.Dataverse.Client and supporting nuget packages.
MIT License
283 stars 52 forks source link

RetrieveMultipleAsync and RetrieveMultiple suddenly slowed down #418

Closed sandeepadode closed 10 months ago

sandeepadode commented 11 months ago

``I have a console app code which is using fetchxml looking something like below and it was retrieving me 5000 records under 3 seconds. Now it takes close to 2 minutes to retrieve the same data. Nothing was changed in the dataverse and the data isn't being updated or touched at all. It worked perfectly(under 3 seconds) when i tried to execute it on my machine and then when one of my colleague tried to execute it on his machine it took 2 minutes on his machine. Then when i tried on my machine it started taking close to 2 minutes for me. At times i get the data under 3 seconds, but then it is very unstable. I have tried to use the RetrieveMultipleAsync and RetrieveMultiple methods and both are the same(unstable). Rest all the code runs quickly and it is at this line of code that it almost hangs and goes into some kind of queue and i don't see dataverse call in my diagnostic tool for a long time. As you can see I am not trying to get a lot of data. It just simple type data. Has anyone ever faced a similar situation and know why could this be happening? Fetch.txt

MattB-msft commented 10 months ago

@sandeepadode

Looking at your query, it could be a number of things, though it should not be inconsistent, if it slows down it should slow down for all requests (generally do to bad index's or other factors such as data volume)

This is something you would want to open a Support request with a request ID's of a slow request. That will help the team isolate the problem between networking and database access. As its specific to your environment, Its not something we could help you with here.