You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@gravitino.apache.org by "bharos (via GitHub)" <gi...@apache.org> on 2026/06/03 22:55:33 UTC

[PR] [#7833] fix(iceberg): Populate audit info for tables loaded from Iceberg catalog [gravitino]

bharos opened a new pull request, #11415:
URL: https://github.com/apache/gravitino/pull/11415

   ### What changes were proposed in this pull request?
   
   Populate `AuditInfo` (creator and create time) when loading Iceberg tables via
   `IcebergTable.fromIcebergTable()`, instead of hardcoding `AuditInfo.EMPTY`.
   
   - Extract the `owner` table property as the `creator`
   - Use `lastUpdatedMillis` from Iceberg `TableMetadata` as the `createTime`
   
   ### Why are the changes needed?
   
   When tables are created or updated outside the Gravitino Web UI (e.g., via
   Iceberg REST Catalog, Spark, or other Iceberg clients), the "Created by" /
   "Updated by" user and timestamp fields are not populated in Gravitino's metadata
   UI. This is because `IcebergTable.fromIcebergTable()` discards the available
   audit information by using `AuditInfo.EMPTY`.
   
   Fix: #7833
   
   ### Does this PR introduce _any_ user-facing change?
   
   Yes. Tables loaded from Iceberg catalogs will now show the creator (from the
   `owner` table property) and creation timestamp in the Gravitino Web UI and API
   responses, where previously these fields were empty.
   
   ### How was this patch tested?
   
   Added two unit tests in `TestIcebergTable`:
   - `testFromIcebergTablePopulatesAuditInfoWithOwner` — verifies creator and
     createTime are populated when the `owner` property is set
   - `testFromIcebergTableWithoutOwnerProperty` — verifies no regression when
     `owner` is absent (creator is null, createTime is still set)
   
   All existing `TestIcebergTable` tests continue to pass.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@gravitino.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#7833] fix(iceberg): Populate audit info for tables loaded from Iceberg catalog [gravitino]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #11415:
URL: https://github.com/apache/gravitino/pull/11415#issuecomment-4617740497

   <!-- coverage-report -->
   ### Code Coverage Report
   |Overall Project|66.76% **`+0.02%`**|:green_circle:|
   |:-|:-|:-:|
   |Files changed|90.11%|:green_circle:|
   <br>
   
   |Module|Coverage||
   |:-|:-|:-:|
   |aliyun|1.72%|:red_circle:|
   |api|46.82%|:green_circle:|
   |authorization-common|85.96%|:green_circle:|
   |aws|3.66%|:red_circle:|
   |azure|2.47%|:red_circle:|
   |catalog-common|10.04%|:red_circle:|
   |catalog-fileset|80.33%|:green_circle:|
   |catalog-glue|66.08%|:green_circle:|
   |catalog-hive|79.33%|:green_circle:|
   |catalog-jdbc-clickhouse|80.02%|:green_circle:|
   |catalog-jdbc-common|45.31%|:green_circle:|
   |catalog-jdbc-doris|80.28%|:green_circle:|
   |catalog-jdbc-hologres|54.03%|:green_circle:|
   |catalog-jdbc-mysql|79.23%|:green_circle:|
   |catalog-jdbc-oceanbase|78.38%|:green_circle:|
   |catalog-jdbc-postgresql|82.29%|:green_circle:|
   |catalog-jdbc-starrocks|78.51%|:green_circle:|
   |catalog-kafka|77.01%|:green_circle:|
   |catalog-lakehouse-generic|44.89%|:green_circle:|
   |catalog-lakehouse-hudi|79.1%|:green_circle:|
   |catalog-lakehouse-iceberg|85.73% **`+0.33%`**|:green_circle:|
   |catalog-lakehouse-paimon|79.29%|:green_circle:|
   |catalog-model|77.72%|:green_circle:|
   |cli|44.51%|:green_circle:|
   |client-java|77.91%|:green_circle:|
   |common|49.99%|:green_circle:|
   |core|82.48%|:green_circle:|
   |filesystem-hadoop3|76.97%|:green_circle:|
   |flink|0.0%|:red_circle:|
   |flink-common|41.2%|:green_circle:|
   |flink-runtime|0.0%|:red_circle:|
   |gcp|14.12%|:red_circle:|
   |hadoop-common|10.39%|:red_circle:|
   |hive-metastore-common|53.26%|:green_circle:|
   |iceberg-common|56.54%|:green_circle:|
   |iceberg-rest-server|72.76%|:green_circle:|
   |idp-basic|85.99%|:green_circle:|
   |integration-test-common|0.0%|:red_circle:|
   |jobs|66.17%|:green_circle:|
   |lance-common|20.83%|:red_circle:|
   |lance-rest-server|60.27%|:green_circle:|
   |lineage|53.02%|:green_circle:|
   |optimizer|82.95%|:green_circle:|
   |optimizer-api|21.95%|:red_circle:|
   |server|85.73%|:green_circle:|
   |server-common|73.13%|:green_circle:|
   |spark|32.79%|:red_circle:|
   |spark-common|37.99%|:red_circle:|
   |trino-connector|39.44%|:red_circle:|
   
   <details>
   <summary>Files</summary>
   
   |Module|File|Coverage||
   |:-|:-|:-|:-:|
   |catalog-lakehouse-iceberg|[IcebergTable.java](https://github.com/bharos/gravitino/blob/3956982947ed0a7daa484a5e4a2a38d2bd899bb8/catalogs/catalog-lakehouse-iceberg/src/main/java/org/apache/gravitino/catalog/lakehouse/iceberg/IcebergTable.java)|90.11%|:green_circle:|
   
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@gravitino.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#7833] fix(iceberg): Populate audit info for tables loaded from Iceberg catalog [gravitino]

Posted by "roryqi (via GitHub)" <gi...@apache.org>.
roryqi commented on PR #11415:
URL: https://github.com/apache/gravitino/pull/11415#issuecomment-4677768192

   O


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@gravitino.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [#7833] fix(iceberg): Populate audit info for tables loaded from Iceberg catalog [gravitino]

Posted by "mchades (via GitHub)" <gi...@apache.org>.
mchades commented on PR #11415:
URL: https://github.com/apache/gravitino/pull/11415#issuecomment-4669761274

   hi @bharos , is this PR ready for review?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@gravitino.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org