Skip to content

RESTTableOperations refresh does not enforce Table UUID check #14337

@limatakamaidotcom-github

Description

Apache Iceberg version

1.10.0 (latest release)

Query engine

Spark

Please describe the bug 🐞

HiveTableOperations (BaseMetastoreTableOperations) does enforce Table UUID check when refreshing TableMetadata

https://github.com/apache/iceberg/blob/main/core/src/main/java/org/apache/iceberg/BaseMetastoreTableOperations.java#L205

However, RESTTableOperations does not enforce Table UUID check when refreshing TableMetadata

https://github.com/apache/iceberg/blob/main/core/src/main/java/org/apache/iceberg/rest/RESTTableOperations.java#L172

A table can be dropped and recreated under the same name (but under a new UUID) on the RESTCatalog server side, clients shall receive exceptions in such case instead of silently accepting new TableMetadata corresponding to the new UUID.

Willingness to contribute

  • I can contribute a fix for this bug independently
  • I would be willing to contribute a fix for this bug with guidance from the Iceberg community
  • I cannot contribute a fix for this bug at this time

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions