fix: lower Refresh All Orgs concurrency and improve OPFS worker error… - #1984
Open
paustint wants to merge 1 commit into
Open
fix: lower Refresh All Orgs concurrency and improve OPFS worker error…#1984paustint wants to merge 1 commit into
paustint wants to merge 1 commit into
Conversation
… detail Yesterday's Refresh All Orgs release put one production org-groups page through 130+ concurrent health checks in a single burst; ~28% failed fast with a 400 that never reached Salesforce. Dropping the fan-out from 4 to 2 gives the org-resolution path more headroom per request. Also caught while triaging: the Data History OPFS worker's crash handler logged "unknown" whenever `ErrorEvent.message` came back blank. It now captures filename/line/col and the underlying Error's name/message/stack when the browser provides one, so the next crash is diagnosable instead of opaque.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR reduces the “Refresh All Orgs” fan-out to avoid bursty concurrent Salesforce health checks, and improves OPFS Data History worker crash diagnostics by capturing richer error context (filename/line/col and underlying error details) when ErrorEvent.message is blank.
Changes:
- Lowered Refresh All Orgs concurrency from 4 to 2 to reduce request bursts and associated fast-fail errors.
- Enhanced OPFS worker
onerrorlogging and error construction to include more actionable crash details.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| libs/shared/ui-data-history/src/lib/file-store/opfs-file-store.ts | Improves worker crash logging and error messages by capturing additional error context. |
| libs/features/org-groups/src/lib/RefreshAllOrgsButton.tsx | Reduces health-check concurrency to mitigate request bursts during “Refresh All Orgs”. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+164
to
+166
| const summary = errorDetails.errorMessage || errorDetails.message || errorDetails.errorName || 'unknown'; | ||
| const location = errorDetails.filename ? ` (${errorDetails.filename}:${errorDetails.lineno}:${errorDetails.colno})` : ''; | ||
| const error = new Error(`Data history storage worker error: ${summary}${location}`); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
… detail
Yesterday's Refresh All Orgs release put one production org-groups page through 130+ concurrent health checks in a single burst; ~28% failed fast with a 400 that never reached Salesforce. Dropping the fan-out from 4 to 2 gives the org-resolution path more headroom per request.
Also caught while triaging: the Data History OPFS worker's crash handler logged "unknown" whenever
ErrorEvent.messagecame back blank. It now captures filename/line/col and the underlying Error's name/message/stack when the browser provides one, so the next crash is diagnosable instead of opaque.