All Content
Timespan
explore our new search
Essential PowerAutomate Tips to Prevent SharePoint Online Crashes
Image Source: Shutterstock.com
SharePoint Online
Oct 19, 2022 7:50 PM

Essential PowerAutomate Tips to Prevent SharePoint Online Crashes

by HubSite 365 about Microsoft

Software Development Redmond, Washington

Pro UserSharePoint OnlineM365 Hot News

Master Microsoft SharePoint Online without Crashing: Essential PowerAutomate Tips for Optimum Performance

Guidelines to prevent SharePoint from crashing using Power Automate

SharePoint Online is built with a throttling feature aimed at optimizing its performance and reliability. This throttling feature regulates the number of Application Programming Interface (API) calls or operations within a given time frame in a bid to prevent overuse of resources.

Consequently, when your application is throttled, SharePoint Online returns a HTTP status code 429 (indicating "Too many requests") or 503 ("Server Too Busy"), causing the requests to fail. When this occurs, a Retry-After header is included in its response signifying the duration the application should pause before making a fresh request or retrying.

Alongside the Retry-After header, SharePoint Online also provides IETF RateLimit headers under certain conditions to help applications manage rate limiting. It is strongly advised for applications to leverage on these headers in order to avoid being throttled, thereby ensuring better throughput.

Note: These headers are still in their beta phase and can be subject to change. The existing implementation is heavily reliant on draft-03 IETF specifications. However, should there be any changes when the specification finally comes through, the necessary adjustments will be made.

RateLimit headers are only returned when application permissions are used. An observed pattern with throttled applications involves the application moving at full speed, gets throttled, paused for a while then continues at full speed again until it's throttled. This isn't quite efficient and results in less throughput compared to utilizing RateLimit headers and avoiding getting throttled.

With RateLimit headers, though the application might slow down, it won't halt. Also, if a request is retried due to throttling, these retries count towards the allotted resource unit quota, thus reducing the successful requests for that specific resource unit quota.

Interestingly, an application realizes its highest throughput by maintaining its resource unit quota and avoiding throttling. As an instance, we can consider the request throughput for the RateLimit demo application. It is very clear that using RateLimit headers is more effective compared to not using them.

If one wishes to see RateLimit handling in live action, the demo application displays how to capture RateLimit headers for Microsoft Graph, SharePoint REST, and SharePoint CSOM calls, and how to manage them. This application launches 5 parallel threads that each starts releasing a Microsoft Graph, SharePoint REST and SharePoint CSOM swiftly.

Should the application use up to 80% of its resource unit quota, SharePoint will begin to release RateLimit headers. Once it's detected that there's only 10% resource units left, the application will slow down to avoid throttling. More insights on setting up and customizing the demo application are available in the documentation

For more information on throttling and best practices for SharePoint Online, click here.

Further Insight on SharePoint Online Throttling

Throttling is a crucial feature in SharePoint Online to ensure optimal utilization of resources and prevent system overload. This is particularly important in maintaining the quality of service to all users and avoiding unexpected crashes or errors.

While it may appear inconvenient at first, throttling, in fact, instills discipline in resource usage. Application developers can use this functionality to better manage their API calls or operations, ensure smooth execution, and enhance the overall user experience.

Read the full article Avoid Crashing SharePoint Online Using PowerAutomate: Essential Tips

SharePoint Online - Essential PowerAutomate Tips to Prevent SharePoint Online Crashes

Learn about Avoid Crashing SharePoint Online Using PowerAutomate: Essential Tips

Understanding the intricate functions of SharePoint Online can be a complex endeavor. One of them is how to avoid system crashes via efficient use of PowerAutomate. Recognizing the significance of this operation, a number of key principles and tips can be beneficial for preventing detrimental consequences to system performance and reliability.

Primarily, SharePoint leverages a feature known as 'throttling'. This mechanism administers the load of API calls or operations within a particular time window to prevent excessive resource usage. Under circumstances of throttling conditions, it may return HTTP status codes like 429 (indicating 'Too many requests') or 503 (demonstrating 'Server Too Busy') with failed requests. To guide the reattempt or reinvocation of a new request, a Retry-After header is incorporated within the response.

Complementing the Retry-After header for controlled requests, SharePoint also employs IETF RateLimit headers to assist applications in managing rate limitation under specified conditions. Taking advantage of such headers is a recommended practice to avoid facing throttling situations and guarantee improved throughput for applications.

Bear in mind, these headers are still in the beta phase and could be subject to modifications. Furthermore, RateLimit headers are exclusively returned when utilizing application permissions.

Throttling issues frequently arise in an inequitable pattern, wherein an application operates at full speed, subsequently facing throttling conditions leading to temporary halts, followed by ramping up only to be halted once again. This unpredictable halt-ramp cycle is highly inefficient, reducing application throughput contrary to the utilization of RateLimit headers.

Key to improvement is achieving a balance – maintaining the application’s resource unit quota, or put simply, avoiding throttling for optimal application throughput. A clear distinction can be seen in application request throughput when comparing the use of RateLimit headers versus without such a mechanism.

To further comprehend RateLimit handling, it may prove helpful to review the RateLimit demo application. This application initiates 5 parallel threads, each propelling Microsoft Graph, SharePoint REST, and SharePoint CSOM calls in a cycle. As the application reaches 80% of its resource unit quota, SharePoint begins to dispatch RateLimit headers. Thereby, enabling the application to monitor resource units and automatically slow down upon nearing depletion to prevent throttling.

To successfully customize and deploy the RateLimit demo application, comprehensive guidance is available in the GitHub documentation. By grasping these essentials, you can ensure stable and efficient functioning of SharePoint, resulting in better overall performance.

More links on about Avoid Crashing SharePoint Online Using PowerAutomate: Essential Tips

Avoid Crashing SharePoint Online Using PowerAutomate
Oct 31, 2022 — Throttling is a technique used by SharePoint Online to preserve the service's peak performance and dependability. To prevent resource misuse, ...
Solved: Power automate freezing/crashes when trying to add...
Jan 4, 2022 — I have created a flow to pull responses from sharepoint into a CSV table filtering out on the the specific responses I want to report on.
Solved: Simple "when modified" flow crashing
Apr 11, 2022 — Solved: Hello, I have created a really simple flow which worked for a long time and then suddenly crashed. 1.

Keywords

SharePoint Online, PowerAutomate, Avoid Crashing SharePoint, Essential SharePoint Tips, PowerAutomate Tips, SharePoint Online Usage, Improve SharePoint Performance, Maintain SharePoint Online, SharePoint PowerAutomate Integration, SharePoint Online Crash Solutions