Repository navigation
Fixes #36018: gate Profiler Settings Save when the stored config fetch fails - #36034
Merged
ShaileshParmar11 merged 2 commits intoOct 23, 2026
Conversation
Contributor
|
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
Contributor
|
ShaileshParmar11
approved these changes
Oct 23, 2026
ShaileshParmar11
left a comment
Contributor
There was a problem hiding this comment.
Verified the bug on main and the fix: a failed config load now hides the defaults-filled form, disables Save, and offers Retry, so no defaults-only PUT can overwrite the stored profiler config. UI checks green.
ShaileshParmar11
added this pull request to the merge queue
Oct 23, 2026
ShaileshParmar11
deleted the
detail/bug-fix/fixes-36018-gate-profiler-settings-save-when-the-s-6ae217
branch
October 23, 2026 08:52
3 tasks done
ShaileshParmar11
added a commit
that referenced
this pull request
Oct 23, 2026
…h fails (#36034) (#36091) Backport to 2.0. A failed config load left the drawer filled with defaults and Save enabled; the PUT replaces the stored config whole, so one save wiped the table's profile query, column lists, partitioning and sample settings. Show the error with a Try Again action instead of the form and disable Save until the config loads.
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 bug report: View on Detail
Describe your changes:
Fixes #36018
I worked on
ProfilerSettingsModalbecause, when the initialgetTableProfilerConfigGET failed (transient network error, 5xx, timeout), the modal only showed an error toast, left the form filled withDEFAULT_VALUES, and left Save enabled. Saving then PUT a defaults-onlyTableProfilerConfig, and the backend stores that config as a whole-row replacement (REPLACE INTO/ON CONFLICT DO UPDATE SET json = EXCLUDED.json) — soprofileQuery,includeColumns,excludeColumns,partitioningand any non-default sample settings were silently and permanently wiped. The bug has been present since the modal was introduced (455c2d0).Type of change:
High-level design:
N/A — small change.
The fix tracks the fetch failure in a new
isFetchFailedstate (set in the load effect's catch branch, cleared on success) plus aretryCountstate in the effect's dependency array. WhileisFetchFailed:SomethingWentWrongPlaceholder(with a Retry button that re-runs the load by bumpingretryCount) — so the user is not invited to "save" defaults.isDisabled={isFetchFailed}(defence-in-depth; the hidden form can't submit either).Gating is on the fetch failure, not on
storedConfig === undefined, so the legitimate first-time-config case (fetch succeeds with no stored config) still renders the form and enables Save. The error placeholder + retry mirrors the siblingTestSummarycomponent's load-error pattern in the same Profiler area.Tests:
Use cases covered
Unit tests
ProfilerSettingsModal.test.tsx(4 new tests in awhen the stored config fetch failsdescribe block: blocks-save-and-offers-retry, no-PUT-on-attempted-save, retry-reloads-and-re-enables-save, save-enabled-on-success).Database/Profiler(25 suites / 403 tests) andTableProfiler(11 suites / 151 tests) suites.Backend integration tests
DEFAULT_VALUESpayload is never sent from a failed-fetch state.Ingestion integration tests
Playwright (UI) tests
toBeDisabled(), Retry reloads real config, noputTableProfileConfigcall on failed fetch).Manual testing performed
profileQuery,excludeColumns, andincludeColumnswere all wiped to null and the sample overwritten — proving whole-row replacement with no merge, which is why the client-side gate is the necessary guard.apiSignInposts to/api/v1/auth/login(a 2.0.0 endpoint), while the only published Docker server image (1.8.0) does not expose it (returns 500/404) and a1.12.0-SNAPSHOTimage is not published. The component-level Jest tests cover the same browser-visible behavior.UI screen recording:
Not applicable — standalone bug fix. No new UI surface; the change replaces a form with an existing error-placeholder component under an already-failed load.
Checklist:
Fixes <issue-number>: <short explanation>Fixes #<issue-number>above.REVIEW.md(pr-checklistskill) and fixed every 🔴 finding.docs/decisions/record.Automatic Fixes PRs can be configured here.


Confidence Score: 5/5
The PR appears safe to merge, with no actionable issues found.Summary
Prevents a failed Profiler Settings load from exposing a defaults-filled form that could overwrite saved settings.
No new actionable issues were found. No previous review threads were supplied.
Reviews (2) · Last reviewed commit: "refactor(ui): drop the shadowed form par..." · Reviewed by Greptile