Skip to content

Feature #18173: Version API Improvements, Last x versions order by desc, versions from specific timeline, versions for specific metadata changes, sdk support and UI integration#26307

Open
harshach wants to merge 22 commits intomainfrom
18173
Open

Feature #18173: Version API Improvements, Last x versions order by desc, versions from specific timeline, versions for specific metadata changes, sdk support and UI integration#26307
harshach wants to merge 22 commits intomainfrom
18173

Conversation

@harshach
Copy link
Copy Markdown
Collaborator

@harshach harshach commented Mar 7, 2026

Describe your changes:

Fixes #18173

I worked on ... because ...

Type of change:

  • Bug fix
  • Improvement
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation

Checklist:

  • I have read the CONTRIBUTING document.
  • My PR title is Fixes <issue-number>: <short explanation>
  • 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.

Summary by Gitar

  • Version API enhancements:
    • Added pagination support for entity version history retrieval with RequestOptions
    • Implemented filtering for versions by timeline, metadata changes, and SDK entity support
  • Database schema updates:
    • Added schema migration scripts for MySQL and PostgreSQL v1.13.0
  • Backend improvements:
    • Enhanced VersionMixin with descending order and filtering capabilities
    • Extended EntityRepository and CollectionDAO with version query methods
    • Added EntityServiceBase with version history test coverage
  • Frontend UI integration:
    • Updated version history components across multiple entity types
    • Added PaginatedVersionHistory spec with 183 test cases
    • Enhanced EntityVersionPage with pagination and timeline filtering
  • Agent skills and documentation:
    • Added Playwright validation and test writing skill documentation

This will update automatically on new commits.

harshach added 2 commits March 6, 2026 14:36
…versions, specifict time, specific metadata changes
…sc, versions from specific timeline, versions for specific metadata changes, sdk support and UI integration
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 7, 2026

TypeScript types have been updated based on the JSON schema changes in the PR

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 7, 2026

The Python checkstyle failed.

Please run make py_format and py_format_check in the root of your repository and commit the changes to this PR.
You can also use pre-commit to automate the Python code formatting.

You can install the pre-commit hooks with make install_test precommit_install.

if (limit > 0) {
return repository.listVersionsWithOffset(id, limit, offset, fieldChanged).entityHistory();
}
if (fieldChanged != null && !fieldChanged.isEmpty()) {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Bug: offset ignored when limit=0 but fieldChanged is provided

In EntityResource.java:379-382, when limit is 0 (the default) but fieldChanged is non-null, the code calls listVersionsWithOffset(id, Integer.MAX_VALUE, 0, fieldChanged) — hardcoding offset to 0 and ignoring the caller-supplied offset parameter. This means pagination is silently broken for clients that provide fieldChanged without an explicit limit.

Suggested fix:

Pass the caller's offset instead of hardcoding 0:
return repository
    .listVersionsWithOffset(id, Integer.MAX_VALUE, offset, fieldChanged)
    .entityHistory();

Was this helpful? React with 👍 / 👎 | Reply gitar fix to apply this suggestion


EntityHistory entityHistory =
new EntityHistory().withEntityType(entityType).withVersions(versions).withPaging(paging);
return new EntityHistoryWithOffset(entityHistory, offset + limit);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Edge Case: nextOffset in EntityHistoryWithOffset not capped to total

At EntityRepository.java:1305 and :1353, EntityHistoryWithOffset is constructed with offset + limit as the next offset, but this value is never capped to total. If the last page returns fewer items, the next offset will exceed total, which may confuse clients that use the returned offset for further pagination (though the UI uses hasMoreVersions to gate this).

Was this helpful? React with 👍 / 👎 | Reply gitar fix to apply this suggestion

Comment thread ingestion/src/metadata/ingestion/ometa/mixins/version_mixin.py Outdated
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 7, 2026

🛡️ TRIVY SCAN RESULT 🛡️

Target: openmetadata-ingestion-base-slim:trivy (debian 12.13)

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: Java

Vulnerabilities (37)

Package Vulnerability ID Severity Installed Version Fixed Version
com.fasterxml.jackson.core:jackson-core CVE-2025-52999 🚨 HIGH 2.12.7 2.15.0
com.fasterxml.jackson.core:jackson-core GHSA-72hv-8253-57qq 🚨 HIGH 2.12.7 2.18.6, 2.21.1, 3.1.0
com.fasterxml.jackson.core:jackson-core CVE-2025-52999 🚨 HIGH 2.13.4 2.15.0
com.fasterxml.jackson.core:jackson-core GHSA-72hv-8253-57qq 🚨 HIGH 2.13.4 2.18.6, 2.21.1, 3.1.0
com.fasterxml.jackson.core:jackson-core GHSA-72hv-8253-57qq 🚨 HIGH 2.15.2 2.18.6, 2.21.1, 3.1.0
com.fasterxml.jackson.core:jackson-databind CVE-2022-42003 🚨 HIGH 2.12.7 2.12.7.1, 2.13.4.2
com.fasterxml.jackson.core:jackson-databind CVE-2022-42004 🚨 HIGH 2.12.7 2.12.7.1, 2.13.4
com.google.code.gson:gson CVE-2022-25647 🚨 HIGH 2.2.4 2.8.9
com.google.protobuf:protobuf-java CVE-2021-22569 🚨 HIGH 3.3.0 3.16.1, 3.18.2, 3.19.2
com.google.protobuf:protobuf-java CVE-2022-3509 🚨 HIGH 3.3.0 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2022-3510 🚨 HIGH 3.3.0 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2024-7254 🚨 HIGH 3.3.0 3.25.5, 4.27.5, 4.28.2
com.google.protobuf:protobuf-java CVE-2021-22569 🚨 HIGH 3.7.1 3.16.1, 3.18.2, 3.19.2
com.google.protobuf:protobuf-java CVE-2022-3509 🚨 HIGH 3.7.1 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2022-3510 🚨 HIGH 3.7.1 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2024-7254 🚨 HIGH 3.7.1 3.25.5, 4.27.5, 4.28.2
com.nimbusds:nimbus-jose-jwt CVE-2023-52428 🚨 HIGH 9.8.1 9.37.2
com.squareup.okhttp3:okhttp CVE-2021-0341 🚨 HIGH 3.12.12 4.9.2
commons-beanutils:commons-beanutils CVE-2025-48734 🚨 HIGH 1.9.4 1.11.0
commons-io:commons-io CVE-2024-47554 🚨 HIGH 2.8.0 2.14.0
dnsjava:dnsjava CVE-2024-25638 🚨 HIGH 2.1.7 3.6.0
io.airlift:aircompressor CVE-2025-67721 🚨 HIGH 0.27 2.0.3
io.netty:netty-codec-http2 CVE-2025-55163 🚨 HIGH 4.1.96.Final 4.2.4.Final, 4.1.124.Final
io.netty:netty-codec-http2 GHSA-xpw8-rcwv-8f8p 🚨 HIGH 4.1.96.Final 4.1.100.Final
io.netty:netty-handler CVE-2025-24970 🚨 HIGH 4.1.96.Final 4.1.118.Final
net.minidev:json-smart CVE-2021-31684 🚨 HIGH 1.3.2 1.3.3, 2.4.4
net.minidev:json-smart CVE-2023-1370 🚨 HIGH 1.3.2 2.4.9
org.apache.avro:avro CVE-2024-47561 🔥 CRITICAL 1.7.7 1.11.4
org.apache.avro:avro CVE-2023-39410 🚨 HIGH 1.7.7 1.11.3
org.apache.derby:derby CVE-2022-46337 🔥 CRITICAL 10.14.2.0 10.14.3, 10.15.2.1, 10.16.1.2, 10.17.1.0
org.apache.ivy:ivy CVE-2022-46751 🚨 HIGH 2.5.1 2.5.2
org.apache.mesos:mesos CVE-2018-1330 🚨 HIGH 1.4.3 1.6.0
org.apache.thrift:libthrift CVE-2019-0205 🚨 HIGH 0.12.0 0.13.0
org.apache.thrift:libthrift CVE-2020-13949 🚨 HIGH 0.12.0 0.14.0
org.apache.zookeeper:zookeeper CVE-2023-44981 🔥 CRITICAL 3.6.3 3.7.2, 3.8.3, 3.9.1
org.eclipse.jetty:jetty-server CVE-2024-13009 🚨 HIGH 9.4.56.v20240826 9.4.57.v20241219
org.lz4:lz4-java CVE-2025-12183 🚨 HIGH 1.8.0 1.8.1

🛡️ TRIVY SCAN RESULT 🛡️

Target: Node.js

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: Python

Vulnerabilities (9)

Package Vulnerability ID Severity Installed Version Fixed Version
apache-airflow CVE-2025-68438 🚨 HIGH 3.1.5 3.1.6
apache-airflow CVE-2025-68675 🚨 HIGH 3.1.5 3.1.6, 2.11.1
cryptography CVE-2026-26007 🚨 HIGH 42.0.8 46.0.5
jaraco.context CVE-2026-23949 🚨 HIGH 6.0.1 6.1.0
starlette CVE-2025-62727 🚨 HIGH 0.48.0 0.49.1
urllib3 CVE-2025-66418 🚨 HIGH 1.26.20 2.6.0
urllib3 CVE-2025-66471 🚨 HIGH 1.26.20 2.6.0
urllib3 CVE-2026-21441 🚨 HIGH 1.26.20 2.6.3
wheel CVE-2026-24049 🚨 HIGH 0.45.1 0.46.2

🛡️ TRIVY SCAN RESULT 🛡️

Target: /etc/ssl/private/ssl-cert-snakeoil.key

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/extended_sample_data.yaml

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/lineage.yaml

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/sample_data.json

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/sample_data.yaml

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/sample_data_aut.yaml

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/sample_usage.json

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/sample_usage.yaml

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /ingestion/pipelines/sample_usage_aut.yaml

No Vulnerabilities Found

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 7, 2026

🛡️ TRIVY SCAN RESULT 🛡️

Target: openmetadata-ingestion:trivy (debian 12.12)

Vulnerabilities (4)

Package Vulnerability ID Severity Installed Version Fixed Version
libpam-modules CVE-2025-6020 🚨 HIGH 1.5.2-6+deb12u1 1.5.2-6+deb12u2
libpam-modules-bin CVE-2025-6020 🚨 HIGH 1.5.2-6+deb12u1 1.5.2-6+deb12u2
libpam-runtime CVE-2025-6020 🚨 HIGH 1.5.2-6+deb12u1 1.5.2-6+deb12u2
libpam0g CVE-2025-6020 🚨 HIGH 1.5.2-6+deb12u1 1.5.2-6+deb12u2

🛡️ TRIVY SCAN RESULT 🛡️

Target: Java

Vulnerabilities (38)

Package Vulnerability ID Severity Installed Version Fixed Version
com.fasterxml.jackson.core:jackson-core CVE-2025-52999 🚨 HIGH 2.12.7 2.15.0
com.fasterxml.jackson.core:jackson-core GHSA-72hv-8253-57qq 🚨 HIGH 2.12.7 2.18.6, 2.21.1, 3.1.0
com.fasterxml.jackson.core:jackson-core CVE-2025-52999 🚨 HIGH 2.13.4 2.15.0
com.fasterxml.jackson.core:jackson-core GHSA-72hv-8253-57qq 🚨 HIGH 2.13.4 2.18.6, 2.21.1, 3.1.0
com.fasterxml.jackson.core:jackson-core GHSA-72hv-8253-57qq 🚨 HIGH 2.15.2 2.18.6, 2.21.1, 3.1.0
com.fasterxml.jackson.core:jackson-core GHSA-72hv-8253-57qq 🚨 HIGH 2.16.1 2.18.6, 2.21.1, 3.1.0
com.fasterxml.jackson.core:jackson-databind CVE-2022-42003 🚨 HIGH 2.12.7 2.12.7.1, 2.13.4.2
com.fasterxml.jackson.core:jackson-databind CVE-2022-42004 🚨 HIGH 2.12.7 2.12.7.1, 2.13.4
com.google.code.gson:gson CVE-2022-25647 🚨 HIGH 2.2.4 2.8.9
com.google.protobuf:protobuf-java CVE-2021-22569 🚨 HIGH 3.3.0 3.16.1, 3.18.2, 3.19.2
com.google.protobuf:protobuf-java CVE-2022-3509 🚨 HIGH 3.3.0 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2022-3510 🚨 HIGH 3.3.0 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2024-7254 🚨 HIGH 3.3.0 3.25.5, 4.27.5, 4.28.2
com.google.protobuf:protobuf-java CVE-2021-22569 🚨 HIGH 3.7.1 3.16.1, 3.18.2, 3.19.2
com.google.protobuf:protobuf-java CVE-2022-3509 🚨 HIGH 3.7.1 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2022-3510 🚨 HIGH 3.7.1 3.16.3, 3.19.6, 3.20.3, 3.21.7
com.google.protobuf:protobuf-java CVE-2024-7254 🚨 HIGH 3.7.1 3.25.5, 4.27.5, 4.28.2
com.nimbusds:nimbus-jose-jwt CVE-2023-52428 🚨 HIGH 9.8.1 9.37.2
com.squareup.okhttp3:okhttp CVE-2021-0341 🚨 HIGH 3.12.12 4.9.2
commons-beanutils:commons-beanutils CVE-2025-48734 🚨 HIGH 1.9.4 1.11.0
commons-io:commons-io CVE-2024-47554 🚨 HIGH 2.8.0 2.14.0
dnsjava:dnsjava CVE-2024-25638 🚨 HIGH 2.1.7 3.6.0
io.airlift:aircompressor CVE-2025-67721 🚨 HIGH 0.27 2.0.3
io.netty:netty-codec-http2 CVE-2025-55163 🚨 HIGH 4.1.96.Final 4.2.4.Final, 4.1.124.Final
io.netty:netty-codec-http2 GHSA-xpw8-rcwv-8f8p 🚨 HIGH 4.1.96.Final 4.1.100.Final
io.netty:netty-handler CVE-2025-24970 🚨 HIGH 4.1.96.Final 4.1.118.Final
net.minidev:json-smart CVE-2021-31684 🚨 HIGH 1.3.2 1.3.3, 2.4.4
net.minidev:json-smart CVE-2023-1370 🚨 HIGH 1.3.2 2.4.9
org.apache.avro:avro CVE-2024-47561 🔥 CRITICAL 1.7.7 1.11.4
org.apache.avro:avro CVE-2023-39410 🚨 HIGH 1.7.7 1.11.3
org.apache.derby:derby CVE-2022-46337 🔥 CRITICAL 10.14.2.0 10.14.3, 10.15.2.1, 10.16.1.2, 10.17.1.0
org.apache.ivy:ivy CVE-2022-46751 🚨 HIGH 2.5.1 2.5.2
org.apache.mesos:mesos CVE-2018-1330 🚨 HIGH 1.4.3 1.6.0
org.apache.thrift:libthrift CVE-2019-0205 🚨 HIGH 0.12.0 0.13.0
org.apache.thrift:libthrift CVE-2020-13949 🚨 HIGH 0.12.0 0.14.0
org.apache.zookeeper:zookeeper CVE-2023-44981 🔥 CRITICAL 3.6.3 3.7.2, 3.8.3, 3.9.1
org.eclipse.jetty:jetty-server CVE-2024-13009 🚨 HIGH 9.4.56.v20240826 9.4.57.v20241219
org.lz4:lz4-java CVE-2025-12183 🚨 HIGH 1.8.0 1.8.1

🛡️ TRIVY SCAN RESULT 🛡️

Target: Node.js

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: Python

Vulnerabilities (22)

Package Vulnerability ID Severity Installed Version Fixed Version
Authlib CVE-2026-28802 🚨 HIGH 1.6.6 1.6.7
Werkzeug CVE-2024-34069 🚨 HIGH 2.2.3 3.0.3
aiohttp CVE-2025-69223 🚨 HIGH 3.12.12 3.13.3
aiohttp CVE-2025-69223 🚨 HIGH 3.13.2 3.13.3
apache-airflow CVE-2025-68438 🚨 HIGH 3.1.5 3.1.6
apache-airflow CVE-2025-68675 🚨 HIGH 3.1.5 3.1.6, 2.11.1
azure-core CVE-2026-21226 🚨 HIGH 1.37.0 1.38.0
cryptography CVE-2026-26007 🚨 HIGH 42.0.8 46.0.5
google-cloud-aiplatform CVE-2026-2472 🚨 HIGH 1.130.0 1.131.0
google-cloud-aiplatform CVE-2026-2473 🚨 HIGH 1.130.0 1.133.0
jaraco.context CVE-2026-23949 🚨 HIGH 5.3.0 6.1.0
jaraco.context CVE-2026-23949 🚨 HIGH 6.0.1 6.1.0
protobuf CVE-2026-0994 🚨 HIGH 4.25.8 6.33.5, 5.29.6
pyasn1 CVE-2026-23490 🚨 HIGH 0.6.1 0.6.2
python-multipart CVE-2026-24486 🚨 HIGH 0.0.20 0.0.22
ray CVE-2025-62593 🔥 CRITICAL 2.47.1 2.52.0
starlette CVE-2025-62727 🚨 HIGH 0.48.0 0.49.1
urllib3 CVE-2025-66418 🚨 HIGH 1.26.20 2.6.0
urllib3 CVE-2025-66471 🚨 HIGH 1.26.20 2.6.0
urllib3 CVE-2026-21441 🚨 HIGH 1.26.20 2.6.3
wheel CVE-2026-24049 🚨 HIGH 0.45.1 0.46.2
wheel CVE-2026-24049 🚨 HIGH 0.45.1 0.46.2

🛡️ TRIVY SCAN RESULT 🛡️

Target: usr/bin/docker

Vulnerabilities (3)

Package Vulnerability ID Severity Installed Version Fixed Version
stdlib CVE-2025-68121 🔥 CRITICAL v1.25.5 1.24.13, 1.25.7, 1.26.0-rc.3
stdlib CVE-2025-61726 🚨 HIGH v1.25.5 1.24.12, 1.25.6
stdlib CVE-2025-61728 🚨 HIGH v1.25.5 1.24.12, 1.25.6

🛡️ TRIVY SCAN RESULT 🛡️

Target: /etc/ssl/private/ssl-cert-snakeoil.key

No Vulnerabilities Found

🛡️ TRIVY SCAN RESULT 🛡️

Target: /home/airflow/openmetadata-airflow-apis/openmetadata_managed_apis.egg-info/PKG-INFO

No Vulnerabilities Found

harshach and others added 4 commits March 9, 2026 18:03
Resolved conflicts:
- SQL migrations: combined entity_extension versionNum/changedFieldKeys columns (branch) with MCP tables, Iceberg migration, entity_usage index, and glossary term relation settings (main)
- EntityRepository.java: kept buildVersionExtensionRecord approach with phase("batchDbWrites") wrapper
- UI files (TabFilters, EntityVersionTimeLine): accepted main's changes
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

❌ Playwright Lint Check Failed — ESLint + Prettier + Organise Imports

The following files have style issues that need to be fixed:
playwright/e2e/VersionPages/PaginatedVersionHistory.spec.ts

Fix locally (fast — only for changed files in the branch):

make ui-checkstyle-playwright-changed

Or to fix all playwright files:

make ui-checkstyle-playwright

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

❌ Lint Check Failed — ESLint + Prettier + Organise Imports (src)

The following files have style issues that need to be fixed:
src/components/APIEndpoint/APIEndpointVersion/APIEndpointVersion.interface.ts src/components/APIEndpoint/APIEndpointVersion/APIEndpointVersion.tsx src/components/Chart/ChartVersion/ChartVersion.component.tsx src/components/Container/ContainerVersion/ContainerVersion.component.tsx src/components/Container/ContainerVersion/ContainerVersion.interface.ts src/components/Dashboard/DashboardVersion/DashboardVersion.component.tsx src/components/Dashboard/DashboardVersion/DashboardVersion.interface.ts src/components/Dashboard/DataModel/DataModelVersion/DataModelVersion.component.tsx src/components/Dashboard/DataModel/DataModelVersion/DataModelVersion.interface.ts src/components/Database/ColumnDetailPanel/ColumnDetailPanel.component.tsx src/components/Database/ColumnDetailPanel/ColumnDetailPanel.test.tsx src/components/Database/ColumnDetailPanel/KeyProfileMetrics/KeyProfileMetrics.component.tsx src/components/Database/StoredProcedureVersion/StoredProcedureVersion.component.tsx src/components/Database/StoredProcedureVersion/StoredProcedureVersion.interface.ts src/components/Database/TableVersion/TableVersion.component.tsx src/components/Database/TableVersion/TableVersion.interface.ts src/components/DriveService/Directory/DirectoryVersion/DirectoryVersion.interface.ts src/components/DriveService/Directory/DirectoryVersion/DirectoryVersion.tsx src/components/DriveService/File/FileVersion/FileVersion.interface.ts src/components/DriveService/File/FileVersion/FileVersion.tsx src/components/DriveService/Spreadsheet/SpreadsheetVersion/SpreadsheetVersion.interface.ts src/components/DriveService/Spreadsheet/SpreadsheetVersion/SpreadsheetVersion.tsx src/components/DriveService/Worksheet/WorksheetVersion/WorksheetVersion.interface.ts src/components/DriveService/Worksheet/WorksheetVersion/WorksheetVersion.tsx src/components/Entity/EntityVersionTimeLine/EntityVersionTimeline.interface.ts src/components/Metric/MetricVersion/MetricVersion.interface.ts src/components/Metric/MetricVersion/MetricVersion.tsx src/components/MlModel/MlModelVersion/MlModelVersion.component.tsx src/components/MlModel/MlModelVersion/MlModelVersion.interface.tsx src/components/Pipeline/PipelineVersion/PipelineVersion.component.tsx src/components/Pipeline/PipelineVersion/PipelineVersion.interface.ts src/components/SearchIndexVersion/SearchIndexVersion.interface.ts src/components/SearchIndexVersion/SearchIndexVersion.tsx src/components/Settings/Services/Ingestion/IngestionListTable/IngestionListTable.test.tsx src/components/Settings/Services/Ingestion/IngestionListTable/IngestionListTable.tsx src/components/Settings/Services/Ingestion/IngestionRecentRun/IngestionRecentRuns.component.tsx src/components/Topic/TopicVersion/TopicVersion.component.tsx src/components/Topic/TopicVersion/TopicVersion.interface.ts src/pages/EntityVersionPage/EntityVersionPage.component.tsx src/rest/SearchIndexAPI.ts src/rest/apiCollectionsAPI.ts src/rest/apiEndpointsAPI.ts src/rest/chartsAPI.ts src/rest/dashboardAPI.ts src/rest/dataModelsAPI.ts src/rest/dataProductAPI.ts src/rest/databaseAPI.ts src/rest/domainAPI.ts src/rest/driveAPI.ts src/rest/glossaryAPI.ts src/rest/metricsAPI.ts src/rest/mlModelAPI.ts src/rest/pipelineAPI.ts src/rest/serviceAPI.ts src/rest/storageAPI.ts src/rest/storedProceduresAPI.ts src/rest/tableAPI.ts src/rest/tagAPI.ts src/rest/testAPI.ts src/rest/topicsAPI.ts src/utils/CommonUtils.tsx

Fix locally (fast — only for changed files in the branch):

make ui-checkstyle-src-changed

Or to fix all files:

make ui-checkstyle-src

@gitar-bot
Copy link
Copy Markdown

gitar-bot bot commented Apr 8, 2026

Code Review ✅ Approved 21 resolved / 21 findings

Version API improvements now support fetching last x versions in descending order, versions from specific timelines, versions for specific metadata changes, with SDK support and UI integration. All 20 identified issues were resolved during review.

✅ 21 resolved
Bug: Stale closure in fetchMoreVersions reads outdated versionList

📄 openmetadata-ui/src/main/resources/ui/src/pages/EntityVersionPage/EntityVersionPage.component.tsx:493 📄 openmetadata-ui/src/main/resources/ui/src/pages/EntityVersionPage/EntityVersionPage.component.tsx:513 📄 openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/EntityRepository.java:1305 📄 openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/EntityRepository.java:1353
In fetchMoreVersions, line 513 reads versionList.versions?.length to compute totalLoaded, but versionList is captured from the closure at the time the callback was created — not the updated state after setVersionList on line 499. This means totalLoaded will always be one page behind, causing hasMoreVersions to be incorrectly computed. On the second "load more" click, currentOffset (line 493) also uses the stale versionList from the closure rather than the functional updater pattern.

The currentOffset on line 493 has the same issue — it reads from the stale closure, not the latest state.

Bug: fieldChangeListContains uses substring match, causing false positives

📄 openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/EntityRepository.java:1371 📄 openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/CollectionDAO.java:1433 📄 openmetadata-service/src/main/java/org/openmetadata/service/resources/EntityResource.java:379
In EntityRepository.java:1371, fc.getName().contains(fieldName) uses substring matching. This means searching for field "tag" will also match "tags", and "column" will match "columns". The DB query (LIKE CONCAT('%', :fieldName, '%') on changeDescriptionDoc) has the same substring-matching behavior, so both the Java-side latest-version check and the SQL filter will produce false positive matches.

For consistency and correctness, the Java check should use .equals() or .startsWith() depending on the intended semantics (e.g., columns.tags should match fieldChanged=tags). The SQL LIKE pattern similarly needs adjustment.

Quality: Python SDK get_entity_history_by_timeline return type is wrong

📄 ingestion/src/metadata/ingestion/ometa/mixins/version_mixin.py:144
In version_mixin.py:144, get_entity_history_by_timeline declares its return type as Response (from requests.models), but self.client.get() returns a parsed dict/JSON object, not a raw Response. The return type annotation should reflect the actual return value.

Bug: MySQL migration lacks IF NOT EXISTS for ADD COLUMN

📄 bootstrap/sql/migrations/native/1.13.0/mysql/schemaChanges.sql:34 📄 bootstrap/sql/migrations/native/1.13.0/postgres/schemaChanges.sql:36
The PostgreSQL migration uses ADD COLUMN IF NOT EXISTS changeDescriptionDoc making it idempotent, but the MySQL migration uses bare ADD COLUMN changeDescriptionDoc which will fail if the migration is re-run or the column already exists. This is inconsistent between the two database backends.

Security: LIKE wildcard injection in fieldChanged filter allows data leak

📄 openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/CollectionDAO.java:1433 📄 openmetadata-service/src/main/java/org/openmetadata/service/jdbi3/CollectionDAO.java:1446 📄 openmetadata-service/src/main/java/org/openmetadata/service/resources/EntityResource.java:379
The fieldChanged query parameter is passed unsanitized into SQL LIKE clauses (CONCAT('%', :fieldName, '%')) in getExtensionsWithFieldChanged and getExtensionCountWithFieldChanged. JDBI's @Bind prevents structural SQL injection but does NOT escape LIKE wildcards (%, _). A caller passing fieldChanged=% would match all records regardless of actual field changes, bypassing the intended filtering. While not a full SQL injection, it allows information disclosure (seeing version counts/data that should be filtered out).

...and 16 more resolved from earlier reviews

Options

Display: compact → Showing less information.

Comment with these commands to change:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Enhances OpenMetadata’s version/history APIs to support pagination and filtering (including “field changed” filters and timeline-based history), and propagates those capabilities through backend resources, SDK, ingestion, and UI.

Changes:

  • Add limit/offset pagination and fieldChanged filtering to entity /versions endpoints, plus paging support in EntityHistory.
  • Persist/index version metadata (versionNum, changedFieldKeys) via DB migrations to enable efficient filtered lookups.
  • Add SDK + ingestion client support and UI integration hooks for loading additional version-history pages.

Reviewed changes

Copilot reviewed 208 out of 209 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
scripts/datamodel_generation.py Post-processes generated Pydantic models to fix paging import resolution issues.
openmetadata-ui/src/main/resources/ui/src/utils/CommonUtils.tsx Minor JSX formatting adjustments.
openmetadata-ui/src/main/resources/ui/src/rest/topicsAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/testAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/tagAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/tableAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/storedProceduresAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/storageAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/serviceAPI.ts Adds optional limit/offset/fieldChanged query params to service versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/SearchIndexAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/pipelineAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/mlModelAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/metricsAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/glossaryAPI.ts Adds optional limit/offset/fieldChanged query params to glossary/glossaryTerm versions API calls.
openmetadata-ui/src/main/resources/ui/src/rest/driveAPI.ts Adds optional limit/offset/fieldChanged query params to Drive asset versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/domainAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/dataProductAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/dataModelsAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/databaseAPI.ts Adds optional limit/offset/fieldChanged query params to database/databaseSchema versions API calls.
openmetadata-ui/src/main/resources/ui/src/rest/dashboardAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/chartsAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/apiEndpointsAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/rest/apiCollectionsAPI.ts Adds optional limit/offset/fieldChanged query params to versions API call.
openmetadata-ui/src/main/resources/ui/src/generated/type/entityHistory.ts Adds paging to EntityHistory and defines Paging interface for UI typing.
openmetadata-ui/src/main/resources/ui/src/components/Topic/TopicVersion/TopicVersion.interface.ts Adds pagination props (onLoadMore, hasMore, isLoadingMore) for version timeline.
openmetadata-ui/src/main/resources/ui/src/components/Topic/TopicVersion/TopicVersion.component.tsx Wires pagination props into EntityVersionTimeLine for Topic versions.
openmetadata-ui/src/main/resources/ui/src/components/Settings/Services/Ingestion/IngestionRecentRun/IngestionRecentRuns.component.tsx Minor JSX formatting adjustments.
openmetadata-ui/src/main/resources/ui/src/components/Settings/Services/Ingestion/IngestionListTable/IngestionListTable.tsx Minor JSX formatting adjustments.
openmetadata-ui/src/main/resources/ui/src/components/Settings/Services/Ingestion/IngestionListTable/IngestionListTable.test.tsx Minor JSX formatting adjustments.
openmetadata-ui/src/main/resources/ui/src/components/SearchIndexVersion/SearchIndexVersion.tsx Wires pagination props into EntityVersionTimeLine for SearchIndex versions.
openmetadata-ui/src/main/resources/ui/src/components/SearchIndexVersion/SearchIndexVersion.interface.ts Adds pagination props for SearchIndex version view.
openmetadata-ui/src/main/resources/ui/src/components/Pipeline/PipelineVersion/PipelineVersion.interface.ts Adds pagination props for Pipeline version view.
openmetadata-ui/src/main/resources/ui/src/components/Pipeline/PipelineVersion/PipelineVersion.component.tsx Wires pagination props into EntityVersionTimeLine for Pipeline versions.
openmetadata-ui/src/main/resources/ui/src/components/MlModel/MlModelVersion/MlModelVersion.interface.tsx Adds pagination props for ML Model version view.
openmetadata-ui/src/main/resources/ui/src/components/MlModel/MlModelVersion/MlModelVersion.component.tsx Wires pagination props into EntityVersionTimeLine for ML Model versions.
openmetadata-ui/src/main/resources/ui/src/components/Metric/MetricVersion/MetricVersion.tsx Wires pagination props into EntityVersionTimeLine for Metric versions.
openmetadata-ui/src/main/resources/ui/src/components/Metric/MetricVersion/MetricVersion.interface.ts Adds pagination props for Metric version view.
openmetadata-ui/src/main/resources/ui/src/components/Entity/EntityVersionTimeLine/EntityVersionTimeline.interface.ts Extends timeline props with pagination hooks.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/Worksheet/WorksheetVersion/WorksheetVersion.tsx Wires pagination props into EntityVersionTimeLine for Worksheet versions.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/Worksheet/WorksheetVersion/WorksheetVersion.interface.ts Adds pagination props for Worksheet version view.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/Spreadsheet/SpreadsheetVersion/SpreadsheetVersion.tsx Wires pagination props into EntityVersionTimeLine for Spreadsheet versions.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/Spreadsheet/SpreadsheetVersion/SpreadsheetVersion.interface.ts Adds pagination props for Spreadsheet version view.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/File/FileVersion/FileVersion.tsx Wires pagination props into EntityVersionTimeLine for File versions.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/File/FileVersion/FileVersion.interface.ts Adds pagination props for File version view.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/Directory/DirectoryVersion/DirectoryVersion.tsx Wires pagination props into EntityVersionTimeLine for Directory versions.
openmetadata-ui/src/main/resources/ui/src/components/DriveService/Directory/DirectoryVersion/DirectoryVersion.interface.ts Adds pagination props for Directory version view.
openmetadata-ui/src/main/resources/ui/src/components/Database/TableVersion/TableVersion.interface.ts Adds pagination props for Table version view.
openmetadata-ui/src/main/resources/ui/src/components/Database/TableVersion/TableVersion.component.tsx Wires pagination props into EntityVersionTimeLine for Table versions.
openmetadata-ui/src/main/resources/ui/src/components/Database/StoredProcedureVersion/StoredProcedureVersion.interface.ts Adds pagination props for StoredProcedure version view.
openmetadata-ui/src/main/resources/ui/src/components/Database/StoredProcedureVersion/StoredProcedureVersion.component.tsx Wires pagination props into EntityVersionTimeLine for StoredProcedure versions.
openmetadata-ui/src/main/resources/ui/src/components/Database/ColumnDetailPanel/KeyProfileMetrics/KeyProfileMetrics.component.tsx Minor JSX formatting adjustments.
openmetadata-ui/src/main/resources/ui/src/components/Database/ColumnDetailPanel/ColumnDetailPanel.test.tsx Minor JSX formatting adjustments.
openmetadata-ui/src/main/resources/ui/src/components/Database/ColumnDetailPanel/ColumnDetailPanel.component.tsx Minor JSX formatting adjustments.
openmetadata-ui/src/main/resources/ui/src/components/Dashboard/DataModel/DataModelVersion/DataModelVersion.interface.ts Adds pagination props for Dashboard DataModel version view.
openmetadata-ui/src/main/resources/ui/src/components/Dashboard/DataModel/DataModelVersion/DataModelVersion.component.tsx Wires pagination props into EntityVersionTimeLine for DataModel versions.
openmetadata-ui/src/main/resources/ui/src/components/Dashboard/DashboardVersion/DashboardVersion.interface.ts Adds pagination props for Dashboard version view.
openmetadata-ui/src/main/resources/ui/src/components/Dashboard/DashboardVersion/DashboardVersion.component.tsx Wires pagination props into EntityVersionTimeLine for Dashboard versions.
openmetadata-ui/src/main/resources/ui/src/components/Container/ContainerVersion/ContainerVersion.interface.ts Adds pagination props for Container version view.
openmetadata-ui/src/main/resources/ui/src/components/Container/ContainerVersion/ContainerVersion.component.tsx Wires pagination props into EntityVersionTimeLine for Container versions.
openmetadata-ui/src/main/resources/ui/src/components/Chart/ChartVersion/ChartVersion.component.tsx Adds and wires pagination props for Chart version view.
openmetadata-ui/src/main/resources/ui/src/components/APIEndpoint/APIEndpointVersion/APIEndpointVersion.tsx Wires pagination props into EntityVersionTimeLine for APIEndpoint versions.
openmetadata-ui/src/main/resources/ui/src/components/APIEndpoint/APIEndpointVersion/APIEndpointVersion.interface.ts Adds pagination props for APIEndpoint version view.
openmetadata-spec/src/main/resources/json/schema/type/entityHistory.json Extends EntityHistory schema to include paging.
openmetadata-service/src/test/java/org/openmetadata/service/util/VersionFieldChangeUtilTest.java Unit tests for exact field-change matching behavior.
openmetadata-service/src/test/java/org/openmetadata/service/migration/utils/MigrationSqlStatementHashTest.java Adds migration SQL parsing assertions for uniqueness and info_schema avoidance.
openmetadata-service/src/main/java/org/openmetadata/service/util/VersionFieldChangeUtil.java Adds utility to extract/match changed field keys and serialize them.
openmetadata-service/src/main/java/org/openmetadata/service/resources/types/TypeResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/topics/TopicResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/teams/UserResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/teams/TeamResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/teams/RoleResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/teams/PersonaResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/tags/TagResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/tags/ClassificationResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/storages/ContainerResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/storage/StorageServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/security/SecurityServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/searchIndexes/SearchServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/pipeline/PipelineServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/mlmodel/MlModelServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/metadata/MetadataServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/messaging/MessagingServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/llm/LLMServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/ingestionpipelines/IngestionPipelineResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/drive/DriveServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/database/DatabaseServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/dashboard/DashboardServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/services/apiservices/APIServiceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/searchindex/SearchIndexResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/query/QueryResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/policies/PolicyResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/pipelines/PipelineResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/mlmodels/MlModelResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/metrics/MetricResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/learning/LearningResourceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/kpi/KpiResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/governance/WorkflowDefinitionResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/glossary/GlossaryTermResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/glossary/GlossaryResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/events/subscription/EventSubscriptionResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/events/NotificationTemplateResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/EntityResource.java Implements paginated/filtered listVersionsInternal routing to repository.
openmetadata-service/src/main/java/org/openmetadata/service/resources/drives/WorksheetResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/drives/SpreadsheetResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/drives/FileResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/drives/DirectoryResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/dqtests/TestSuiteResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/dqtests/TestDefinitionResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/dqtests/TestCaseResource.java Adds limit/offset/fieldChanged support with custom auth context for versions.
openmetadata-service/src/main/java/org/openmetadata/service/resources/domains/DomainResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/domains/DataProductResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/docstore/DocStoreResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/datamodels/DashboardDataModelResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/datainsight/DataInsightChartResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/databases/TableResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/databases/StoredProcedureResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/databases/DatabaseSchemaResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/databases/DatabaseResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/data/DataContractResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/dashboards/DashboardResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/charts/ChartResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/bots/BotResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/automations/WorkflowResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/apps/AppResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/apps/AppMarketPlaceResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/apis/APIEndpointResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/apis/APICollectionResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/analytics/WebAnalyticEventResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/ai/PromptTemplateResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/ai/LLMModelResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/ai/AIGovernancePolicyResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-service/src/main/java/org/openmetadata/service/resources/ai/AIApplicationResource.java Adds limit/offset/fieldChanged query params to versions endpoint.
openmetadata-sdk/src/test/java/org/openmetadata/sdk/services/EntityServiceBaseTest.java Adds SDK test coverage for timeline history retrieval and query param wiring.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/services/EntityServiceBase.java Adds paginated getVersionList overloads and timeline getEntityHistory with response parsing.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Users.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Topics.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Teams.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Tables.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Roles.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Pipelines.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Domains.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/DatabaseSchemas.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-sdk/src/main/java/org/openmetadata/sdk/fluent/Databases.java Adds fluent overloads for paginated versions and timeline history.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/WorksheetResourceIT.java Enables paginated + fieldChanged version-history assertions for Worksheet.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/UserResourceIT.java Enables paginated + fieldChanged version-history assertions for User.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/TopicResourceIT.java Enables paginated + fieldChanged version-history assertions for Topic.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/TestSuiteResourceIT.java Enables paginated + fieldChanged version-history assertions for TestSuite.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/TestDefinitionResourceIT.java Enables paginated + fieldChanged version-history assertions for TestDefinition.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/TestCaseResourceIT.java Enables paginated + fieldChanged version-history assertions for TestCase.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/TeamResourceIT.java Enables paginated + fieldChanged version-history assertions for Team.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/TagResourceIT.java Enables paginated + fieldChanged version-history assertions for Tag.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/TableResourceIT.java Adds paginated/fieldChanged history coverage, including exact field-path behavior.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/StoredProcedureResourceIT.java Enables paginated + fieldChanged version-history assertions for StoredProcedure.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/StorageServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for StorageService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/SearchServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for SearchService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/SearchIndexResourceIT.java Enables paginated + fieldChanged version-history assertions for SearchIndex.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/RoleResourceIT.java Enables paginated + fieldChanged version-history assertions for Role.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/QueryResourceIT.java Enables paginated + fieldChanged version-history assertions for Query.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/PolicyResourceIT.java Enables paginated + fieldChanged version-history assertions for Policy.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/PipelineServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for PipelineService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/PipelineResourceIT.java Enables paginated + fieldChanged version-history assertions for Pipeline.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/PersonaResourceIT.java Enables paginated + fieldChanged version-history assertions for Persona.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/NotificationTemplateResourceIT.java Enables paginated + fieldChanged version-history assertions for NotificationTemplate.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/MlModelServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for MlModelService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/MlModelResourceIT.java Enables paginated + fieldChanged version-history assertions for MlModel.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/MetricResourceIT.java Enables paginated + fieldChanged version-history assertions for Metric.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/MetadataServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for MetadataService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/MessagingServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for MessagingService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/LLMServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for LLMService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/LLMModelResourceIT.java Enables paginated + fieldChanged version-history assertions for LLMModel.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/LearningResourceIT.java Adjusts resource path and enables paginated + fieldChanged version-history assertions.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/KpiResourceIT.java Enables paginated + fieldChanged version-history assertions for KPI.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/IngestionPipelineResourceIT.java Enables paginated + fieldChanged version-history assertions for IngestionPipeline.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/GlossaryTermResourceIT.java Enables paginated + fieldChanged version-history assertions for GlossaryTerm.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/GlossaryResourceIT.java Enables paginated + fieldChanged version-history assertions for Glossary.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/EventSubscriptionResourceIT.java Enables paginated + fieldChanged version-history assertions for EventSubscription.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DriveServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for DriveService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DomainResourceIT.java Enables paginated + fieldChanged version-history assertions for Domain.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DataProductResourceIT.java Enables paginated + fieldChanged version-history assertions for DataProduct.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DataInsightChartResourceIT.java Enables paginated + fieldChanged version-history assertions for DataInsightChart.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DataContractResourceIT.java Enables paginated + fieldChanged version-history assertions for DataContract.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DatabaseServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for DatabaseService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DatabaseSchemaResourceIT.java Enables paginated + fieldChanged version-history assertions for DatabaseSchema.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DatabaseResourceIT.java Enables paginated + fieldChanged version-history assertions for Database.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DashboardServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for DashboardService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DashboardResourceIT.java Enables paginated + fieldChanged version-history assertions for Dashboard.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/DashboardDataModelResourceIT.java Enables paginated + fieldChanged version-history assertions for DashboardDataModel.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/ContainerResourceIT.java Enables paginated + fieldChanged version-history assertions for Container.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/ClassificationResourceIT.java Enables paginated + fieldChanged version-history assertions for Classification.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/ChartResourceIT.java Enables paginated + fieldChanged version-history assertions for Chart.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/BotResourceIT.java Enables paginated + fieldChanged version-history assertions for Bot.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/APIServiceResourceIT.java Enables paginated + fieldChanged version-history assertions for APIService.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/APIEndpointResourceIT.java Enables paginated + fieldChanged version-history assertions for APIEndpoint.
openmetadata-integration-tests/src/test/java/org/openmetadata/it/tests/APICollectionResourceIT.java Enables paginated + fieldChanged version-history assertions for APICollection.
ingestion/src/metadata/sdk/entities/base.py Adds pagination/filter params to get_versions and introduces timeline history helper.
ingestion/src/metadata/ingestion/ometa/mixins/version_mixin.py Adds query-param support for versions listing and implements timeline history endpoint call.
bootstrap/sql/migrations/native/1.13.0/postgres/schemaChanges.sql Adds indexed version metadata columns (versionNum, changedFieldKeys) to Postgres.
bootstrap/sql/migrations/native/1.13.0/postgres/postDataMigrationSQLScript.sql Backfills versionNum and changedFieldKeys in Postgres from stored JSON.
bootstrap/sql/migrations/native/1.13.0/mysql/schemaChanges.sql Adds version metadata columns and indexes to MySQL.
bootstrap/sql/migrations/native/1.13.0/mysql/postDataMigrationSQLScript.sql Backfills versionNum and changedFieldKeys in MySQL from stored JSON.
.agents/skills/writing-playwright-tests/SKILL.md Adds agent skill documentation for writing Playwright tests.
.agents/skills/playwright/SKILL.md Adds/updates Playwright test generator skill documentation.
.agents/skills/playwright-validation/SKILL.md Adds agent skill documentation for Playwright validation workflow.

Comment on lines +386 to 395
if (!nullOrEmpty(fieldChanged)) {
int effectiveLimit = limit > 0 ? limit : DEFAULT_FIELD_CHANGED_VERSION_LIMIT;
return repository
.listVersionsWithOffset(id, effectiveLimit, offset, fieldChanged)
.entityHistory();
}
if (limit > 0) {
return repository.listVersionsWithOffset(id, limit, offset, null).entityHistory();
}
return repository.listVersions(id);
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

offset is accepted as a query param by many resources, but if limit is left at the default (0) and fieldChanged is not set, this code ignores offset and returns the full version history via repository.listVersions(id). Consider either (a) rejecting offset>0 when limit<=0 with a 400, or (b) treating offset>0 as opting into paginated mode by applying a default limit (similar to the fieldChanged branch), so offset is never silently ignored.

Copilot uses AI. Check for mistakes.
Comment on lines +68 to +89
# datamodel-code-generator emits a module alias for paging.json that pydantic
# later fails to resolve while importing the generated model during pytest
# plugin bootstrap. Import the concrete type directly instead.
DIRECT_IMPORT_FIXES = {
f"{ingestion_path}src/metadata/generated/schema/type/entityHistory.py": [
(
"from . import changeSummaryMap, paging",
"from . import changeSummaryMap\nfrom .paging import Paging",
),
("from . import paging as paging_module", "from .paging import Paging"),
("Optional[paging.Paging]", "Optional[Paging]"),
("Optional[paging_module.Paging]", "Optional[Paging]"),
],
}

for file_path, replacements in DIRECT_IMPORT_FIXES.items():
with open(file_path, "r", encoding=UTF_8) as file_:
content = file_.read()
for old_value, new_value in replacements:
content = content.replace(old_value, new_value)
with open(file_path, "w", encoding=UTF_8) as file_:
file_.write(content)
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This post-generation patching runs unconditionally and will raise FileNotFoundError if the expected generated file path changes (or generation fails before producing it). It also silently succeeds even if none of the target strings are found, which can mask future generator changes and reintroduce the import-resolution failure. Consider guarding with os.path.exists(...) and asserting that each replacement actually applied (or at least that the final file contains the expected from .paging import Paging).

Copilot uses AI. Check for mistakes.
Comment on lines +16 to +22
import org.flywaydb.core.api.configuration.ClassicConfiguration;
import org.flywaydb.core.api.configuration.Configuration;
import org.flywaydb.core.internal.parser.Parser;
import org.flywaydb.core.internal.parser.ParsingContext;
import org.flywaydb.core.internal.resource.filesystem.FileSystemResource;
import org.flywaydb.core.internal.sqlscript.SqlStatementIterator;
import org.flywaydb.database.mysql.MySQLParser;
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test relies on Flyway org.flywaydb.core.internal.* classes (e.g., Parser, ParsingContext, FileSystemResource), which are not part of Flyway's public API and can change without notice on Flyway upgrades. If possible, prefer public Flyway APIs for parsing SQL (or treat this as a lightweight string-based assertion) to reduce maintenance risk.

Copilot uses AI. Check for mistakes.
Comment on lines +166 to +174
public static org.openmetadata.schema.utils.ResultList getEntityHistory(
long startTs, long endTs) {
return getClient().tables().getEntityHistory(startTs, endTs);
}

public static org.openmetadata.schema.utils.ResultList getEntityHistory(
long startTs, long endTs, int limit, String before, String after) {
return getClient().tables().getEntityHistory(startTs, endTs, limit, before, after);
}
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These new fluent methods return a raw ResultList (no generic type), which drops compile-time type safety and typically introduces unchecked warnings. Consider returning ResultList<Table> (and similarly for other entity fluent wrappers) so consumers get the correct typed data list without casts.

Copilot uses AI. Check for mistakes.
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Apr 8, 2026

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

🔴 Playwright Results — 1 failure(s), 28 flaky

✅ 3591 passed · ❌ 1 failed · 🟡 28 flaky · ⏭️ 207 skipped

Shard Passed Failed Flaky Skipped
🟡 Shard 1 455 0 2 2
🟡 Shard 2 638 0 4 32
🟡 Shard 3 642 0 9 26
🟡 Shard 4 619 0 5 47
🟡 Shard 5 612 0 2 67
🔴 Shard 6 625 1 6 33

Genuine Failures (failed on all attempts)

VersionPages/PaginatedVersionHistory.spec.ts › should load more versions on scroll via infinite scroll (shard 6)
Error: �[2mexpect(�[22m�[31mlocator�[39m�[2m).�[22mtoBeVisible�[2m(�[22m�[2m)�[22m failed

Locator: locator('[data-testid^="version-selector-v"]').nth(1)
Expected: visible
Timeout: 15000ms
Error: element(s) not found

Call log:
�[2m  - Expect "toBeVisible" with timeout 15000ms�[22m
�[2m  - waiting for locator('[data-testid^="version-selector-v"]').nth(1)�[22m

🟡 28 flaky test(s) (passed on retry)
  • Features/DataAssetRulesDisabled.spec.ts › Verify the File entity item action after rules disabled (shard 1, 1 retry)
  • Pages/UserCreationWithPersona.spec.ts › Create user with persona and verify on profile (shard 1, 1 retry)
  • Features/BulkEditEntity.spec.ts › Glossary (shard 2, 1 retry)
  • Features/DataQuality/ColumnLevelTests.spec.ts › Column Values Sum To Be Between (shard 2, 1 retry)
  • Features/DomainTierCertificationVoting.spec.ts › DataProduct - Certification assign, update, and remove (shard 2, 1 retry)
  • Features/ExploreQuickFilters.spec.ts › search dropdown should work properly for quick filters (shard 2, 1 retry)
  • Features/Glossary/MUIGlossaryMutualExclusivity.spec.ts › MUI-ME-R02: Children of non-ME parent should render Checkboxes (shard 3, 1 retry)
  • Features/Glossary/MUIGlossaryMutualExclusivity.spec.ts › MUI-ME-S02: Can select multiple children under non-ME parent (shard 3, 1 retry)
  • Features/Permissions/GlossaryPermissions.spec.ts › Team-based permissions work correctly (shard 3, 1 retry)
  • Features/TableSorting.spec.ts › Database Schema Tables tab should have sorting on name column (shard 3, 1 retry)
  • Features/TableSorting.spec.ts › Data Models Table should have sorting on name column (shard 3, 1 retry)
  • Features/TestSuiteMultiPipeline.spec.ts › TestSuite multi pipeline support (shard 3, 1 retry)
  • Features/UserProfileOnlineStatus.spec.ts › Should not show online status for inactive users (shard 3, 1 retry)
  • Flow/ExploreDiscovery.spec.ts › Should display deleted assets when showDeleted is checked and deleted is not present in queryFilter (shard 3, 1 retry)
  • Flow/PersonaDeletionUserProfile.spec.ts › User profile loads correctly before and after persona deletion (shard 3, 1 retry)
  • Pages/Customproperties-part2.spec.ts › entityReferenceList shows item count, scrollable list, no expand toggle (shard 4, 1 retry)
  • Pages/DataContracts.spec.ts › Create Data Contract and validate for SearchIndex (shard 4, 1 retry)
  • Pages/DataContractsSemanticRules.spec.ts › Validate Owner Rule Is_Set (shard 4, 1 retry)
  • Pages/Entity.spec.ts › Announcement create, edit & delete (shard 4, 1 retry)
  • Pages/Entity.spec.ts › Glossary Term Add, Update and Remove (shard 4, 1 retry)
  • Pages/ExploreTree.spec.ts › Verify Database and Database Schema available in explore tree (shard 5, 1 retry)
  • Pages/Glossary.spec.ts › Add and Remove Assets (shard 5, 1 retry)
  • Pages/Lineage/DataAssetLineage.spec.ts › verify create lineage for entity - Search Index (shard 6, 1 retry)
  • Pages/Lineage/LineageFilters.spec.ts › Verify lineage schema filter selection (shard 6, 1 retry)
  • Pages/ProfilerConfigurationPage.spec.ts › Non admin user (shard 6, 1 retry)
  • Pages/ServiceEntity.spec.ts › Update displayName (shard 6, 1 retry)
  • Pages/UserDetails.spec.ts › Admin user can edit teams from the user profile (shard 6, 1 retry)
  • Pages/Users.spec.ts › Permissions for table details page for Data Consumer (shard 6, 1 retry)

📦 Download artifacts

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

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.

Version api - new requirements

3 participants