Repository navigation
Conversation
…schemas Tables keep databaseSchema and database refs, and schemas keep their database ref, in their stored JSON. Reads trusted those copies whenever they had an id, so after a parent's displayName changed, GET, list and a full search reindex (which reads through setFieldsInBulk) kept returning the old name. Re-read the refs by id on read: a cached lookup on the single-entity path, one batched reference query per page on the bulk path. Fixes open-metadata#38939
✅ PR checks passedThe linked issue has a description and all required Shipping project fields set. Thanks! |
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues were identified for the parent-reference refresh change.
No open issues 🎉
What changed in this PR
Fixes #38939 by resolving current parent references when tables and database schemas are read, preventing stale parent labels from returning to search after a full reindex.
Changes:
- Adds shared helpers for single-reference and batched parent-reference refreshes.
- Refreshes table database/schema references and schema database references without changing storage or API contracts.
- Adds integration coverage for updated parent display names in GET and list responses.
Placement: Covers backend reads used by API clients and search reindexing. End-to-end reindex performance and Collate behavior were not independently verified.
Trade-off: weighed by the author, holds because bulk refreshes use distinct parent IDs in two batched lookups per table page rather than per-table queries or cascading child-row rewrites. Throughput remains unbenchmarked.
Recommendation: Approve; no blocking issues were identified in the supplied review.
| File | Description |
|---|---|
| openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/TableRepository.java | Refreshes database and schema references on single and bulk reads. |
| openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/EntityRepository.java | Adds reusable single and batched reference-refresh helpers. |
| openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/DatabaseSchemaRepository.java | Refreshes the database reference on single-schema reads. |
| openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DatabaseHierarchyIT.java | Tests current parent display names in GET and list responses. |
Review effort: Balanced
currentReference threw EntityNotFoundException for a missing parent, so a table or schema whose parent row was gone could no longer be read. Fall back to the stored copy, as the bulk path already does, and record the read-time resolution rule as a decision.
|
@dk-teknologisk-rfma thanks, the fix works. I verified it on a local server (MySQL 8.4 + Elasticsearch 9.3) on one database:
Cost, measured on the same data, warm cache, fixed vs unfixed (median / p95):
Request 1: apply the rule to every entity with the same pattern, in this PR. The ADR states the rule generally, but these entities still return a stale parent copy:
Rather than patching each repository by hand, could each repository declare the parent references it keeps in stored JSON (for example a Request 2: run a scale benchmark, before and after. Please run Also needed before merge: issue #38939 has to be added to the Shipping project for |
Tables and schemas were not the only entities returning a renamed parent's old displayName. File (directory, service on list and reindex), Query (service), DataContract (entity, testSuite), ontology definitions and OntologyChangeSet (ontology) and AIFrameworkControl (framework) all keep a copy of their parent reference in stored JSON and returned it as stored. Each repository now declares those references in getStoredParentReferences(). EntityRepository refreshes them after setFields on the single-entity path (entity cache) and at the start of the default setFieldsInBulk (one reference-only query per parent type per page). Table and DatabaseSchema move onto the same declaration. refreshStoredReferences groups ids by the type each reference names, so a field that points at several entity types costs one query per type. StoredParentReferenceIT renames each parent and checks GET and list for every declared entity; it fails on the code before this PR.
|
@dk-teknologisk-rfma I pushed 85e6151 on top of your two commits, so the fix covers every entity that keeps a parent reference in its stored JSON, not only tables and schemas.
This replaces the two requests in my previous comment, so there is nothing left for you to do there. |
|
I benchmarked this against main to check the read-path cost. Table and schema reads are fine. Data contract reads get slower when the contract's table is wide.
Setup: MySQL 8.4 and Elasticsearch 9.3 running locally. Synthetic data: 300 schemas, 6,000 tables with 10 columns each, and 50 tables with 1,200 columns each (about 585 KB of stored JSON per table), each of those with a data contract. Both builds ran on the same database, port and JVM settings, taking turns over 5 runs each, with the cache warm. The data contract slowdown showed up in every run. Per-run medians for the single GET were 2.3–3.2 ms on main and 3.6–4.9 ms on the PR. For the list they were 4.2–5.0 ms on main and 6.9–7.6 ms on the PR.
The absolute numbers are small at this size, but they grow with the number of columns. Ask: resolve the contract's |
- A data contract's entity (usually a table) is read with the reference-only query on the single-entity path: rebuilding the reference from the entity cache deserialized the whole table JSON on every GET. - A contract's testSuite is no longer declared: the contract owns its suite. This also restores the plain testSuite comparison in the updater. - The schema list no longer runs a second database query: every stored row already goes through batchFetchDatabases. - The table list takes databaseSchema from the schemas fetchAndSetDefaultFields already loaded, so only the database reference needs a query. - StoredParentReferenceCoverageTest fails when a repository with stored parent references overrides setFieldsInBulk without being listed with its test. - The decision record lists the covered entities and the stored references not declared yet.
| AIFrameworkControl (`framework`). A new entity that keeps a parent reference in stored JSON | ||
| declares it instead of cascading on write. A contract's `testSuite` is not declared: the contract owns | ||
| its suite rather than living under it. The rule covers the entities listed here; stored references | ||
| not declared yet include `TestSuite.basicEntityReference`, `AuditReport.framework`, |
There was a problem hiding this comment.
Since each repository has to opt in, a new entity that keeps a parent ref in its stored JSON and forgets to declare it gets stale parent names silently. This list already has four of them. StoredParentReferenceCoverageTest only looks at repositories that already declare something. Could we add a test that, for every entity type, finds the single EntityReference fields that survive storage (storage strips only the known list plus getFieldsStrippedFromStorageJson()) and fails unless each one is declared in getStoredParentReferences() or on a skip list with a reason (e.g. the contract's testSuite)? It stays explicit, but forgetting one fails CI. Fine as a follow-up if you prefer.
There was a problem hiding this comment.
Done in this PR (c3802c9): StoredReferenceDeclarationTest walks every concrete repository, finds the single EntityReference fields its entity keeps in stored JSON (after FIELDS_STORED_AS_RELATIONSHIPS and getFieldsStrippedFromStorageJson()), and fails unless each is declared in getStoredParentReferences() or listed with a reason. 64 are listed today, grouped as: re-read by their own repository (verified), actors, configuration links, deprecated single domain, owned or point-in-time (incl. the contract's testSuite), and two parents not declared yet (ContextFileContent.contextFile, PromptTemplate.parentTemplate). A second test fails if a listed field stops being stored or gets declared, so the list can't go stale.
| overrides the bulk method keeps its references current on that path, and | ||
| `StoredParentReferenceCoverageTest` lists each such repository with the test that covers it. | ||
|
|
||
| ## Consequences |
There was a problem hiding this comment.
nit: a couple of side effects worth listing here:
storeEntityHistorystores the refreshedoriginal, so a previous version now shows the parent's label at update time rather than the stale copy (arguably better, but a change).- Reads that don't go through
setFieldsInternal/setFieldsInBulkstill return the stored copy:/versions/{v}, rawdao.find*reads, and search-backed lists until propagation or a reindex.
There was a problem hiding this comment.
Added to the record's consequences in c3802c9: version history now holds the refreshed parent labels, and /versions/{v}, raw dao.find* reads and search-backed lists (until propagation or a reindex) still return the stored copy.
| if (storedReference != null && storedReference.getId() != null) { | ||
| try { | ||
| current = | ||
| Entity.getEntityReferenceById(storedReference.getType(), storedReference.getId(), ALL); |
There was a problem hiding this comment.
nit: with ALL, a child under a soft-deleted parent now returns deleted: true on that ref. That's consistent with cascade soft-delete, but API clients will see it, so maybe mention it in the ADR.
There was a problem hiding this comment.
Added to the record in c3802c9: with Include.ALL, a child under a soft-deleted parent returns deleted: true on that reference. StoredParentReferenceIT#softDeletedParentIsReportedOnTheChildReference now covers it (fails on main).
| try { | ||
| current = | ||
| Entity.getEntityReferenceById(storedReference.getType(), storedReference.getId(), ALL); | ||
| } catch (EntityNotFoundException e) { |
There was a problem hiding this comment.
nit: when the parent was hard-deleted, this throws on every read of the orphaned child. As far as I can see the not-found cache is only populated for NON_DELETED lookups, so each read goes to the DB. It only affects orphans, so not a blocker, but worth knowing.
There was a problem hiding this comment.
Right, it only affects orphans, so I left the behaviour and wrote it down in the record (c3802c9): the orphan keeps its stored copy and each read looks the parent up again, since the not-found cache only covers NON_DELETED.
| final Map<UUID, EntityReference> currentById = new HashMap<>(); | ||
| parentIdsByType.forEach( | ||
| (type, ids) -> | ||
| Entity.getEntityReferencesByIds(type, List.copyOf(ids), ALL) |
There was a problem hiding this comment.
nit: this assumes every stored type has a repository. Today it holds because the declared types are validated on write, but if a pseudo-type ever ends up here (like the tableColumn refs that broke list endpoints before), the whole page fails. Skipping types where !Entity.hasEntityRepository(type) would keep it safe.
There was a problem hiding this comment.
Done in c3802c9: a reference whose type has no repository (!Entity.hasEntityRepository(type)) is not resolvable, so it keeps its stored copy on both paths instead of failing the read or the page.
|
|
||
| table.withDatabaseSchema(schemaRef).withDatabase(databaseRef).withService(serviceRef); | ||
| table | ||
| .withDatabaseSchema(schema.getEntityReference()) |
There was a problem hiding this comment.
nit: this refreshes databaseSchema only for rows that go through the missing-defaults path. That's every row today because service is always stripped, but if a stored row ever had all defaults, its schema ref would go stale again without anyone noticing. A short comment (or an assertion in the test) tying the two together would help.
There was a problem hiding this comment.
Added a comment in c3802c9 tying it to service being stripped (so hasDefaultFields is false for every stored row), and StoredParentReferenceCoverageTest names this path for TableRepository with DatabaseHierarchyIT as its test.
|
|
||
| @Test | ||
| void dataContractShowsRenamedEntity(TestNamespace ns) { | ||
| // The contract's testSuite is declared too, but renaming a suite writes a string into the |
There was a problem hiding this comment.
nit: this comment still says the contract's testSuite is declared, but it was dropped in 829638b.
| @Test | ||
| void dataContractUpdateWithoutChangesKeepsItsVersion(TestNamespace ns) { | ||
| // Reads return the suite's current reference while prepare() rebuilds it from id, FQN and type, | ||
| // so an unchanged PUT must compare the suite by identity, not record it as changed. |
There was a problem hiding this comment.
nit: same here. The suite isn't declared any more, so this test now also passes on main and doesn't guard anything this PR changes. Update the comment, or drop the test?
There was a problem hiding this comment.
Agreed, it no longer guarded anything this PR changes, so I dropped it (and its test-case helper) in c3802c9.
| private static final String AI_GOVERNANCE_FRAMEWORKS = "/v1/aiGovernanceFrameworks"; | ||
|
|
||
| @Test | ||
| void fileShowsRenamedDirectoryAndService(TestNamespace ns) { |
There was a problem hiding this comment.
nit: a few cases aren't covered yet. A reindex of a table under a renamed schema/database (the bug in the issue, currently only checked manually), a PATCH on a child after its parent is renamed (should be a no-op diff, no version bump), and a soft-deleted parent at IT level. Even one reindex assertion would be useful.
There was a problem hiding this comment.
Added all three in c3802c9: tableSearchDocShowsRenamedParentsAfterReindex (deletes the table's doc, reindexes it through /v1/search/reindexEntities, asserts the renamed database and schema in the doc), tableUpdateWithoutChangesAfterParentRenameKeepsItsVersion, and softDeletedParentIsReportedOnTheChildReference. On main's production code the reindex and soft-delete tests fail along with the existing per-entity ones (9 of 10); on this branch all 9 StoredParentReferenceIT tests pass.
- StoredReferenceDeclarationTest finds, for every repository, the single EntityReference fields its entity keeps in stored JSON and fails unless each is declared in getStoredParentReferences() or listed with its reason. The 64 listed today are grouped: re-read by their own repository, actors, configuration links, deprecated single domains, owned or point-in-time references, and two parents not declared yet. - A stored reference whose type has no repository keeps its stored copy instead of failing the read. - StoredParentReferenceIT covers the reindexed search doc of a table under renamed parents, an unchanged update after a parent rename and a soft-deleted parent; the no-op contract PUT test no longer guarded this change and is dropped. - The decision record lists the side effects: deleted on references under a soft-deleted parent, refreshed labels in version history, orphan lookups, and the reads that still return the stored copy.
Code Review ✅ Approved 🟡 Medium risk 3 closed / 3 findingsRefreshing stored parent references across GET, list, and reindex paths changes returned metadata, so clients may see updated labels and deleted status. Stored parent references on tables, schemas, files, queries, data contracts, ontology definitions and AI framework controls are now re-read by id on every read, so GET, list and full reindex return current parent names instead of stale copies. Review found no open issues. Resolved this session: single-entity reads no longer throw when a stored parent is missing, the read-time resolution rule is now recorded in docs/decisions, and the schema list/reindex path refreshes the stored database reference. ✅ 3 closed✅ Bug: Single-entity read throws when stored parent is missing
✅ Quality: Read-time parent-ref resolution rule is not recorded in docs/decisions
✅ Bug: Schema list/reindex path never refreshes the stored database ref
VerificationRules No rules evaluated Functional validation Not enabledAuto-approval Not enabledFor more verification details, comment OptionsDisplay: compact → Showing compact verification results. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source |
|
🤖 Backport to |
|
🤖 Backport to |
|
🤖 Backport to |
|
🤖 Backport to |
#38950) (#39624) * Fixes 38939: Resolve stored parent references on read for tables and schemas Tables keep databaseSchema and database refs, and schemas keep their database ref, in their stored JSON. Reads trusted those copies whenever they had an id, so after a parent's displayName changed, GET, list and a full search reindex (which reads through setFieldsInBulk) kept returning the old name. Re-read the refs by id on read: a cached lookup on the single-entity path, one batched reference query per page on the bulk path. Fixes #38939 * Keep a stored parent reference when the parent is gone currentReference threw EntityNotFoundException for a missing parent, so a table or schema whose parent row was gone could no longer be read. Fall back to the stored copy, as the bulk path already does, and record the read-time resolution rule as a decision. * Refresh every stored parent reference on read Tables and schemas were not the only entities returning a renamed parent's old displayName. File (directory, service on list and reindex), Query (service), DataContract (entity, testSuite), ontology definitions and OntologyChangeSet (ontology) and AIFrameworkControl (framework) all keep a copy of their parent reference in stored JSON and returned it as stored. Each repository now declares those references in getStoredParentReferences(). EntityRepository refreshes them after setFields on the single-entity path (entity cache) and at the start of the default setFieldsInBulk (one reference-only query per parent type per page). Table and DatabaseSchema move onto the same declaration. refreshStoredReferences groups ids by the type each reference names, so a field that points at several entity types costs one query per type. StoredParentReferenceIT renames each parent and checks GET and list for every declared entity; it fails on the code before this PR. * Leave the test suite rename out of the shared-server data contract test Renaming a contract's test suite writes a string into the embedded testSuites change description of its test cases, which the shared data insights index maps as boolean (#38799), so DataInsightAiAssetCoverageIT rejected the record. The test keeps checking the contract's entity. * Compare a data contract's test suite by identity Reads now return the suite's current reference, while prepare() rebuilds updated.testSuite from its id, FQN and type, so the full-object comparison recorded a testSuite change on an unchanged PUT and bumped the version. Compare it with entityReferenceMatch, as qualityExpectations already is. StoredParentReferenceIT gains a no-op PUT test (0.1 -> 0.2 before this change) and now cleans up its drive and database services, ontologies and AI framework fixtures. * Read large parents by reference row and drop redundant list queries - A data contract's entity (usually a table) is read with the reference-only query on the single-entity path: rebuilding the reference from the entity cache deserialized the whole table JSON on every GET. - A contract's testSuite is no longer declared: the contract owns its suite. This also restores the plain testSuite comparison in the updater. - The schema list no longer runs a second database query: every stored row already goes through batchFetchDatabases. - The table list takes databaseSchema from the schemas fetchAndSetDefaultFields already loaded, so only the database reference needs a query. - StoredParentReferenceCoverageTest fails when a repository with stored parent references overrides setFieldsInBulk without being listed with its test. - The decision record lists the covered entities and the stored references not declared yet. * Require every stored reference to be declared or listed with a reason - StoredReferenceDeclarationTest finds, for every repository, the single EntityReference fields its entity keeps in stored JSON and fails unless each is declared in getStoredParentReferences() or listed with its reason. The 64 listed today are grouped: re-read by their own repository, actors, configuration links, deprecated single domains, owned or point-in-time references, and two parents not declared yet. - A stored reference whose type has no repository keeps its stored copy instead of failing the read. - StoredParentReferenceIT covers the reindexed search doc of a table under renamed parents, an unchanged update after a parent rename and a soft-deleted parent; the no-op contract PUT test no longer guarded this change and is dropped. - The decision record lists the side effects: deleted on references under a soft-deleted parent, refreshed labels in version history, orphan lookups, and the reads that still return the stored copy. --------- (cherry picked from commit c76ee35) Co-authored-by: Rolf Malthe Andersen <[email protected]> Co-authored-by: Ram Narayan Balaji <[email protected]> Co-authored-by: Ram Narayan Balaji <[email protected]>

Describe your changes:
Fixes #38939
Entities that keep a copy of their parent's reference in their own JSON now return the parent's current name,
displayNameand description, because that copy is never refreshed when the parent changes. This started with tables and database schemas (#38939) and now covers every entity with the same pattern.Root cause.
TableRepository.getFieldsStrippedFromStorageJson()strips onlyservice, sotable_entity.jsonkeeps the fulldatabaseSchemaanddatabasereferences.DatabaseSchemaRepositorylikewise keepsdatabase. Both read paths trust those copies whenever they carry an id:TableRepository.setDefaultFields(the "table JSON already stores database ref" fast path) returns early onhasId(...), and the bulkfetchAndSetDefaultFieldskeepstable.getDatabaseSchema()/table.getDatabase()as they are.DatabaseSchemaRepository.setDefaultFieldsonly callsgetContainerwhen the database id is missing.When the database's
displayNamechanges, nothing rewrites the children's rows. Search propagation (getSearchPropagationDescriptors(),FIELD_DISPLAY_NAMEasNESTED_FIELD) patches the child documents at that moment, so search looks right. But a full reindex reads entities throughPaginatedEntitiesSource.readNextKeyset→listAfterKeyset→setFieldsInBulk, which returns the stale stored copies, and the index goes back to the old name. In Explore → Browse Estate (grouped bydatabase.displayName) the renamed database then shows up twice.Fix. Re-read the stored parent references on read, by id:
EntityRepository.currentReference(ref): single-entity path, viaEntity.getEntityReferenceById(served fromCACHE_WITH_ID, which is evicted on the parent's update).EntityRepository.refreshStoredReferences(entities, parentType, getter, setter): bulk path. OnefindReferencesByIdsquery per parent type per page (distinct ids, reference columns only, no JSON deserialisation). A parent that can't be found keeps its stored copy.TableRepository.setFields/setFieldsInBulkrefreshdatabaseSchemaanddatabase.DatabaseSchemaRepository.setFieldsrefreshesdatabase; its bulk path already re-resolvesdatabasefrom relationships.GET, list and the reindex all return the current labels, so a reindex no longer brings the old name back. Rows that are already stale are corrected on read, so no migration or reindex is needed.
Extended to every entity with a stored parent reference (85e6151). The same stale copy was returned by:
directory,servicesetFieldsInBulknever callssetFields)serviceentity(any entity type),testSuiteontologyontologyframeworkEach repository now declares those references in
getStoredParentReferences().EntityRepositoryrefreshes them aftersetFieldson the single-entity path and at the start of the defaultsetFieldsInBulk; Table, DatabaseSchema and Query, which override the bulk method, callrefreshStoredParentReferences(Query throughsuper). Table and DatabaseSchema moved onto the same declaration.refreshStoredReferencesnow groups ids by the type each stored reference names, so a field that can point at several entity types (a data contract'sentity) costs one query per type.Type of change:
High-level design:
Alternatives considered
displayName/description changes (cascade on write). The read path stays free, but a rename of a database with N schemas and M tables becomes an O(N+M) JSON rewrite inside the PATCH (or a background job with its own failure handling). It also misses the rows that are already stale today, so it would need a migration as well. There is no existing rename-cascade for display names to hook into, and it would have to be repeated for every parent type. Rejected: more code and a slow, fragile write path for an edit users expect to be instant.database/databaseSchemafrom storage JSON (asservicealready is) and always resolve throughentity_relationship. That reverses the deliberate fast path (getContainerper table on GET, relationship joins in bulk), and it needs a migration to clean existing rows. Rejected: it costs more per read than (3) and changes the storage format.IN (…)primary-key lookups per page, for tables, over the distinct parent ids (usually 1–2 rows), with no full-entity deserialisation. That is a small constant per page and never per entity. Measured below: no reindex regression, and zero extra SQL on GET.Scope. Every entity that keeps a parent reference in stored JSON and returned it as stored: Table, DatabaseSchema, File, Query, DataContract, ontology definitions, OntologyChangeSet and AIFrameworkControl. A new entity with a stored parent reference declares it in
getStoredParentReferences(). StoredProcedure re-resolves its schema on read, so it also gets the schema's freshdatabase.ADR:2026-11-27-stored-parent-references-are-resolved-on-read(v2) records the rule.Compatibility. No schema, API or storage change.
Tests:
Use cases covered
After a database's
displayNamechanges,GET /v1/tables/{id}returns the newdatabase.displayName.After a schema's
displayNamechanges,GET /v1/tables/{id}returns the newdatabaseSchema.displayName.GET /v1/databaseSchemas/{id}returns the database's newdisplayName.GET /v1/tables?databaseSchema=…(thesetFieldsInBulkpath that the search reindex also reads through) returns the new database and schema display names, and so doesGET /v1/databaseSchemas?database=….After a drive service and directory are renamed, a file's
serviceanddirectoryare current on GET, list and infile_search_indexafter a full reindex.After a database service, table, ontology or AI governance framework is renamed, the query's
service, the data contract'sentity, the ontology concept's and change set'sontology, and the AI control'sframeworkare current on GET and list.Unit tests
EntityRepositoryCurrentReferenceTest: found parent, missing parent keeps its stored copy, a field pointing at two entity types is refreshed with one query per type, and references without an id or type are left alone.Tests run: 5, Failures: 0, Errors: 0.Backend integration tests
DatabaseHierarchyIT#childrenShowRenamedParentDisplayNames(openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DatabaseHierarchyIT.java).StoredParentReferenceIT(one test per entity: File, Query, DataContract, OntologyConcept, OntologyChangeSet, AIFrameworkControl). On the code before this PR all 6 fail; with it, all 6 pass (mysql-elasticsearch,parallellane):mysql-elasticsearch,parallellane):TableResourceIT363,DatabaseSchemaResourceIT234,FileResourceIT222,QueryResourceIT235,DataContractResourceIT444,OntologyConceptResourceIT209,OntologyChangeSetIT12,AIFrameworkControlResourceIT2,DatabaseHierarchyIT2:Tests run: 1723, Failures: 0, Errors: 0, Skipped: 139.postgres-opensearch(parallellane), includingStoredParentReferenceIT6/6:Tests run: 1729, Failures: 0, Errors: 0, Skipped: 139,BUILD SUCCESS.Scale and cost, measured on the same data with the code before this PR and with it:
ReindexBenchmarkIT(10k tables × 5 columns,scale-itprofile), average of 2 measured reindexes, two runs eachGET /tables/{fqn}(warm cache)GET /queries/{fqn}The reindex numbers vary more between two runs of the same code than between the two versions. GET runs the same SQL (parents come from the entity cache); a list page adds one reference-only
IN (…)query per parent type.Fails on
main(before the fix):Passes with the fix:
Run with the planner's focused command (
mysql-elasticsearch,parallellane):mvn -B verify -pl :openmetadata-integration-tests -am -Dspring-boot.repackage.skip=true -Pmysql-elasticsearch -DintegrationTests.lane=parallel -Dit.test=DatabaseHierarchyIT …Also run locally with the fix, as regressions on the changed read paths:
mysql-elasticsearch,parallellane):TableResourceIT,DatabaseSchemaResourceIT,DatabaseResourceIT,DatabaseHierarchyIT, givingTests run: 823, Failures: 0, Errors: 0, Skipped: 39,BUILD SUCCESS.openmetadata-service:N1QueryFixValidationTest,EntityRelationshipPerformanceTest,InheritTagsTest,EntityRepositoryBulkFieldsTest,EntityRepositoryInheritanceParentTest,SearchIndexFactoryTest, givingTests run: 325, Failures: 0, Errors: 0.mvn spotless:check -pl openmetadata-service,openmetadata-integration-testspasses.Not run locally: the full IT suite that the planner selects for an
EntityRepositorychange (it runs in the merge queue), and the nightlyReindexBenchmarkIT/ reindex UIITs.Ingestion integration tests
Playwright (UI) tests
Manual testing performed
Local server (MySQL 8.4, Elasticsearch 9.3), one database with 100 schemas plus a file, query, data contract, ontology concept and AI control. Every parent was renamed on the code before this PR, then the same database was read by that code and by this branch:
databasedirectory,serviceserviceentityontologyframeworktable_search_indexdatabase,file_search_indexdirectory/serviceRows written by the old code read correctly on this branch, so no migration is needed.
UI screen recording:
Not applicable: backend-only bug fix.
Checklist:
I have read CONTRIBUTING.md (the pre-review gate) and the contributor docs.
My PR title is
Fixes <issue-number>: <short explanation>My PR is linked to a GitHub issue via
Fixes #<issue-number>above.I have commented on my code, particularly in hard-to-understand areas.
For JSON Schema changes: I updated the migration scripts or explained why it is not needed. (No schema change.)
For a UI feature or feature task: as part of PR creation, I ran the PR build in Docker with sample data and embedded a verified GitHub-hosted recording plus build/health evidence above (or explained why this requirement is not applicable).
I have added tests (unit / integration / Playwright as applicable) and listed them above.
Self-review: I reviewed the final diff against
REVIEW.md(thepr-checklistskill runs it) and fixed every 🔴 finding, or answered it on the line below.Decision check: if this PR decides something the next contributor could undo — a schema field, REST path or format another component or repo must agree with, a new default or limit, an ordering that must hold, or a rule stated only in this description — it adds a record under
docs/decisions/(see itsREADME.md). This description is gone fromgit logafter the squash-merge.I have added a test that covers the exact scenario we are fixing. For complex issues, comment the issue number in the test for future reference.