Skip to content

Backport #32350 to 2.0: emit ChangeEvents for bulk entity updates - #32535

Merged
manerow merged 2 commits into
2.0from
backport/32350-2.0
Sep 3, 2026
Merged

manerow merged 2 commits into
2.0from
backport/32350-2.0

Conversation

@manerow

@manerow manerow commented Sep 3, 2026 •

Copy link
Copy Markdown
Contributor

Describe your changes:

Backport of #32350 (Fixes #32092) to 2.0.

PUT /v1/{collection}/bulk persisted entity updates and version history but wrote no change_event
row, so Get Schema Changes alerts never fired on metadata ingestion, and no ingestion-driven update
was auditable. EntityUpdater.updateWithDeferredStore() (the bulk path) ran updateInternal() without
the captureIncrementalFromCurrentChange() step its three sibling entry points run, leaving
incrementalChangeDescription null, which incrementalFieldsChanged() reads as "nothing changed".
Every bulk update was therefore classified ENTITY_NO_CHANGE and dropped by
buildChangeEventJsonForBulkOperation.

Full analysis, blast radius and manual-test tables are in #32350.

This did not reach 2.0 automatically: #32350 merged without the To release label, and the
cherry-pick workflow only fires on the pull_request_target: closed event, which has passed.

Type of change:

  • Bug fix

High-level design:

Straight git cherry-pick -x a3e5f5f4b030c818f8a52b0bb99eab46a94d13e3. It applies cleanly on 2.0
with no conflicts and no adaptation: the added/removed lines are byte-identical to the main commit,
and BulkChangeEventIT.java is byte-identical to the file on main. openmetadata-integration-tests
already carries the BulkApi helper the test needs, unchanged from main.

The companion 1.13 backport is #32536.

Tests:

Backend integration tests

  • BulkChangeEventIT (6 cases), brought over unchanged.

Ingestion integration tests

  • Not applicable (no ingestion changes).

Playwright (UI) tests

  • Not applicable (no UI changes).

Manual testing performed

Built and ran locally on this branch, all 11 modules from source in-reactor so the test exercises
this code and not a cached artifact:

mvn -pl openmetadata-integration-tests -am package -Dtest=BulkChangeEventIT
-> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0

spotless:check on openmetadata-service and openmetadata-integration-tests is green.

The behavioural numbers (bulk 0 -> 1 events, alert totalEventsCount 1 -> 2) and the reverted-fix
control run are in #32350; the production code here is byte-identical to it.

Notes for reviewers

Carried over from #32350 and still applicable on 2.0:

  • Expect more change_event rows. This restores pre-1.13 volume for ingestion updates, bounded by
    the existing DataRetention app. Customers who created alerts while the bug was live have not seen
    this traffic before. Worth a release note.
  • Bulk-PUT of a soft-deleted entity now emits an event, consistent with the single-PUT path.
  • The recursive delete/restore cascade still emits one event, not N. Deliberate, documented in
    persistBulkUpdaters(), and shares updateWithDeferredStore() with this fix.

Checklist:

  • I have read the CONTRIBUTING document.
  • For JSON Schema changes: not applicable, no schema changes.
  • For UI changes: not applicable, no UI changes.
  • I have added a test that covers the exact scenario we are fixing.

On skip-pr-checks: a PR whose base is not the default branch cannot create GitHub's native closingIssuesReferences link, so the metadata gate has no way to see the linked issue and can never be satisfied here. The issue is #32092, already closed by #32350.

* Fixes #32092: emit ChangeEvents for bulk entity updates

* refactor: single-source EntityUpdater change-type classification

* test: cover ChangeEvent emission on the bulk entity update path

(cherry picked from commit a3e5f5f)
@manerow
manerow requested a review from a team as a code owner September 3, 2026 08:14
@manerow manerow added safe to test Add this label to run secure Github workflows on PRs backend skip-pr-checks Bypass PR metadata validation check labels Sep 3, 2026
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

❌ PR checklist incomplete

This PR cannot be merged until the following are addressed on its linked issue:

  • No GitHub issue is linked. Link an issue in the Development section of the PR (or add Fixes #12345 to the description). For a same-org cross-repo issue, add Fixes open-metadata/<repo>#123 to the description.

The fields live on the linked issue in the Shipping project (open the issue → right sidebar → Projects). After you set them, re-run this check (or push a commit) — issue/project changes do not re-trigger it automatically.

Maintainers can bypass this check by adding the skip-pr-checks label.

@manerow manerow added safe to test Add this label to run secure Github workflows on PRs and removed safe to test Add this label to run secure Github workflows on PRs skip-pr-checks Bypass PR metadata validation check labels Sep 3, 2026
@manerow manerow self-assigned this Sep 3, 2026
@github-actions

github-actions Bot commented Sep 3, 2026 •

Copy link
Copy Markdown
Contributor

✅ Playwright Results — workflow succeeded

Validated commit 90d15d612bba468946de10df63158cd9895b6530 in Playwright run 33754719283, attempt 1.

✅ 555 passed · ❌ 0 failed · 🟡 0 flaky · ⏭️ 0 skipped · 🧰 0 lifecycle flaky

Performance

Blocking targets: ✅ met · Optimization targets: 🟡 in progress

Shard-job maxima below are not the full workflow wall time; the linked run includes build, fixture, planning, and reporting.

🕒 Full workflow signal wall (to summary) 55m 23s

⏱️ Max setup 3m 0s · max shard execution 17m 49s · max shard-job elapsed before upload 22m 22s · reporting 4s

🌐 208.47 requests/attempt · 2.82 app boots/UI scenario · 5.71% common-shard skew

Optimization targets still in progress:

  • Browser traffic was 208.47 requests per attempt (convergence target: fewer than 200).
  • Application boot ratio was 2.82 per UI scenario (1626 boots / 576 scenarios; convergence target: at most 1).
Shard Passed Failed Flaky Skipped Lifecycle failed Lifecycle flaky
✅ Shard chromium-01 140 0 0 0 0 0
✅ Shard chromium-02 124 0 0 0 0 0
✅ Shard chromium-03 135 0 0 0 0 0
✅ Shard data-asset-rules-01 63 0 0 0 0 0
✅ Shard domain-isolation-01 16 0 0 0 0 0
✅ Shard global-state-01 34 0 0 0 0 0
✅ Shard ingestion-01 1 0 0 0 0 0
✅ Shard reindex-01 2 0 0 0 0 0
✅ Shard search-01 11 0 0 0 0 0
✅ Shard search-rbac-01 29 0 0 0 0 0

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

yan-3005 added a commit that referenced this pull request Sep 3, 2026
Parallel incident tests must not share global search results, and the lineage mock must preserve table indexing policy across the JVM.

Refs #32535
@gitar-bot

gitar-bot Bot commented Sep 3, 2026

Copy link
Copy Markdown
Code Review ✅ Approved

Backport of #32350 to 2.0: restores ChangeEvent emission for bulk entity updates via PUT /v1/{collection}/bulk, fixing a bug where metadata ingestion changes were not auditable and alerts never fired. Straight cherry-pick that applies cleanly with no conflicts; BulkChangeEventIT passes all 6 cases. No issues found.

Options

Display: compact → Showing less information.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Powered by Gitar — free for open source

@manerow
manerow merged commit 4c3e3b1 into 2.0 Sep 3, 2026
102 of 104 checks passed
@manerow
manerow deleted the backport/32350-2.0 branch September 3, 2026 13:43

This branch was previously deployed

1 inactive deployment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend safe to test Add this label to run secure Github workflows on PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants