eric-maynard opened a new pull request, #1456:
URL: https://github.com/apache/polaris/pull/1456
For rest catalogs, `TableOperations.refresh()` can result in an expensive
trip to object storage. Despite this, the method is called quite frequently and
is currently called after every commit when we construct a BaseTable to return
back to a client that requested a commit.
In some cases, the same TableOperations is used for one commit and then is
immediately used for another. We can see this in some tests, such as Iceberg's
`CatalogTests.testUpdateTableSchemaThenRevert`:
```
table.updateSchema().addColumn("col1", StringType.get()).addColumn("col2",
StringType.get()).addColumn("col3", StringType.get()).commit();
table.updateSchema().deleteColumn("col1").deleteColumn("col2").deleteColumn("col3").commit();
```
This PR proposes that the TableOperations can update its `currentMetadata`
metadata on commit so that future calls to `doRefresh` might be able to skip a
trip to object storage.
<hr>
This is an alternate implementation to #1378 that does not rely on reflection
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]