Skip to content

Fixes 32030: port ingestion usage regression fixes to 2.0 - #37492

Merged
IceS2 merged 2 commits into
2.0from
fix/2.0-ingestion-usage-regressions
Nov 10, 2026
Merged

IceS2 merged 2 commits into
2.0from
fix/2.0-ingestion-usage-regressions

Conversation

@IceS2

@IceS2 IceS2 commented Nov 10, 2026

Copy link
Copy Markdown
Collaborator

Describe your changes:

Fixes #32030

Ports the focused ingestion fixes from main to 2.0: look up queries by service.hash, retry lookup after a concurrent create, and align the usage and DQ regression tests with existing branch behavior.

  • Postgres usage checks verify that a recreated table receives the original query and daily usage under its new ID.
  • Sample usage owns its catalog and query log and asserts counts under qualified table names.
  • DQ result matching compares declared parameters while retaining runtime parameters.
  • Query regression tests cover existing queries, creation, concurrent creation, error propagation, and shared SQL on two tables.

Source changes: #32031, the Postgres test from #33568, the DQ assertions from #33750, and the sample-usage test from #37097 / #37381. The broader resolver and caching refactors are excluded.

Type of change:

  • Bug fix

High-level design:

One production module changes query lookup identity to match the server. The remaining changes port regression tests and test fixtures; there are no schema, configuration, or workflow changes.

Validation:

Python 3.11, generated models from this 2.0 checkout, and the edited source installed in editable mode.

  • 36 unit tests passed: tests/unit/ometa/test_query_mixin.py, tests/unit/bulksink/test_metadata_usage.py, and tests/unit/topology/database/test_life_cycle_query_mixin.py.
  • 15 integration tests passed: all tests in tests/integration/postgres/test_usage.py, tests/integration/usage/test_sample_usage.py, tests/integration/sdk/test_dq_as_code_integration.py, tests/integration/lineage/test_query_lineage_rebuild.py, plus TestOMetaTableAPI::test_same_query_on_second_table_attaches_usage.
  • Integration environment: isolated Docker stack with published server 2.0.7, MySQL metadata storage, Elasticsearch 9.3.0, and PostgreSQL testcontainers for source data. This validates the Python port against a published 2.0 server; the current release-branch server build and other matrix combinations remain for CI.
  • The service-qualified lookup and concurrent-create unit regressions both fail with the original implementation; all five query-mixin unit tests pass with the fix.
  • Ruff lint/format, git diff --check, and commit hooks passed.

No UI recording is applicable.

Backend and UI checks are not applicable. The complete Python/database matrix remains for CI.

Checklist:

  • Existing issue linked; no new issue created.
  • Regression tests included.
  • No schema or UI changes.
  • Final diff reviewed against REVIEW.md: independent read-only review of e45f722c6bb; no concrete defects found.
  • No new architectural decision.

@IceS2
IceS2 requested a review from a team as a code owner November 10, 2026 18:19
@IceS2
IceS2 requested review from mohittilala and removed request for a team November 10, 2026 18:19
@github-actions

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.

@gitar-bot

gitar-bot Bot commented Nov 10, 2026

Copy link
Copy Markdown
Code Review ✅ Approved

🔴 High risk · Changing service-qualified query lookup and 409 recovery affects persisted query/usage associations; a wrong match could misattribute usage to a table.

Ports focused ingestion fixes to 2.0 that look up queries by service.hash and retry lookup after a concurrent create, with aligned usage and DQ regression tests. No issues found.

Verification

Rules No rules evaluated

Functional validation Not enabled

Set up

Auto-approval Not enabled

Set up

For more verification details, comment gitar display:verbose.

Options

Display: compact → Showing compact verification results.

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

@IceS2
IceS2 enabled auto-merge (squash) November 10, 2026 20:17
@IceS2
IceS2 merged commit 9941f32 into 2.0 Nov 10, 2026
69 of 71 checks passed
@IceS2
IceS2 deleted the fix/2.0-ingestion-usage-regressions branch November 10, 2026 20:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants