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
This is a copy of a troubleshooting article on Supabase's docs site. It may be missing some details from the original. View the original article.
If you are observing a RateLimitError: "Rate limit exceeded for trace ..." error when invoking Edge Functions, it typically indicates that a single function execution is triggering too many downstream calls simultaneously.
Why Does This Happen?
This often occurs in "fan-out" scenarios, such as a cron-driven function that calls other functions in a loop.
All downstream supabase.functions.invoke() calls initiated from the same parent execution share a single Trace ID. These calls draw from a specific per-trace safety budget rather than the total project-level capacity. If the volume of calls is too high, the budget is exhausted and subsequent calls are throttled.
How to Resolve This Issue:
Pace Invocations: Introduce a delay between invoke() calls (e.g., hundreds of milliseconds) in the producer function to stay within the trace budget.
Batch Payloads: Restructure the downstream function to accept an array of data, allowing a single invocation to process multiple records instead of triggering individual calls for each.
Consolidate Logic: Refactor the logic into a shared library or move it directly into the calling function to eliminate the need for cross-function network calls.
You can monitor these errors by visiting the logs explorer to identify which executions are exceeding their trace budget.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
This is a copy of a troubleshooting article on Supabase's docs site. It may be missing some details from the original. View the original article.
If you are observing a
RateLimitError: "Rate limit exceeded for trace ..."error when invoking Edge Functions, it typically indicates that a single function execution is triggering too many downstream calls simultaneously.Why Does This Happen?
supabase.functions.invoke()calls initiated from the same parent execution share a single Trace ID. These calls draw from a specific per-trace safety budget rather than the total project-level capacity. If the volume of calls is too high, the budget is exhausted and subsequent calls are throttled.How to Resolve This Issue:
invoke()calls (e.g., hundreds of milliseconds) in the producer function to stay within the trace budget.You can monitor these errors by visiting the logs explorer to identify which executions are exceeding their trace budget.
Beta Was this translation helpful? Give feedback.
All reactions