question

user2021 avatar image
0 Votes"
user2021 asked user2021 commented

How to avoid overloading when retrieving Users and Groups from Azure AD?

Hello All-

We have a .NET Application and we retrieve data (Users and Groups) from Azure AD. We have 500+ Users and Groups registered in Azure AD, but when we display that to our application, it causes timeout and error. Are there any suggestions or best practices to solve the overloading issues? Thanks!

azure-active-directory
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

JamesTran-MSFT avatar image
0 Votes"
JamesTran-MSFT answered user2021 commented

@tobias2021
Thank you for your post!

For handling throttling, you should be able to reference our - Microsoft Graph throttling guidance documentation for more info.


The following are best practices for handling throttling:

  • Reduce the number of operations per request.

  • Reduce the frequency of calls.

  • Avoid immediate retries, because all requests accrue against your usage limits.

Identity and access service limits


If you have any other questions, please let me know.
Thank you for your time and patience throughout this issue.


Please remember to "Accept Answer" if any answer/reply helped, so that others in the community facing similar issues can easily find the solution.

· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@JamesTran-MSFT

Thank you for answering.

Throttling may help us in handling requests but I have more questions with regards to overloading.

My .NET application mimics the Azure Portal, then I have also registered an application with 500+ Users and Groups in Azure AD. I would like to edit the registered application in my .NET app but when I'm doing so, it returns timeout/error just like I said. I think it's because when my .NET app is trying to retrieve the details of my app reg from Azure AD. Specifically, because it has 500+ Users and Groups so it overloads. Is there a way to solve this problem?

Let me know if you have concerns or questions regarding this. Thank you!

0 Votes 0 ·

@tobias2021
Thank you for the quick follow up and details!

  • Can you share what specific calls is your .NET app making? Is it GraphAPI calls for users/groups or REST API?

  • When editing the registered application in your .NET app, does the timeout occur after or during? What changes are you trying to make?


When it comes to timeout issues, this could also be related to throttling since the most common scenarios are:

  • A large number of requests across all applications in a tenant.

  • A large number of requests from a particular application across all tenants.


Any additional information would be greatly appreciated!

If you have any other questions, please let me know.
Thank you for your time and patience throughout this issue.

0 Votes 0 ·

@JamesTran-MSFT

  • For our calls, we used Graph API calls. We used query parameter $filter as well.

  • The timeout occurs after I clicked the "Edit" button in my app. I can't edit any details (e.g. Users and Groups) to my registered app since it will reach it's timeout and will eventually return an error 4300.

I am checking the throttling management and will try to apply it to my application.

Let me know if you have more questions regarding this. Thank you!

0 Votes 0 ·