Files
impala/tests
Andrew Sherman 29586d6631 IMPALA-11482: Alter Table Execute Rollback for Iceberg tables.
Iceberg table modifications cause new table snapshots to be created;
these snapshots represent an earlier version of the table. The Iceberg
API provides a way to rollback the table to a previous snapshot.

This change adds the ability to execute a rollback on Iceberg tables
using the following statements:

- ALTER TABLE <tbl> EXECUTE ROLLBACK(<snapshot id>)
- ALTER TABLE <tbl> EXECUTE ROLLBACK('<timestamp>')

The latter form of the command rolls back to the most recent snapshot
that has a creation timestamp that is older than the specified
timestamp.

Note that when a table is rolled back to a snapshot, a new snapshot is
created with the same snapshot id, but with a new creation timestamp.

Testing:
 - Added analysis unit tests.
 - Added e2e tests.
 - Converted test_time_travel to use get_snapshots() from iceberg_util.
 - Add a utility class to allow pytests to create tables with various
   iceberg catalogs.

Change-Id: Ic74913d3b81103949ffb5eef7cc936303494f8b9
Reviewed-on: http://gerrit.cloudera.org:8080/19002
Reviewed-by: Impala Public Jenkins <impala-public-jenkins@cloudera.com>
Tested-by: Impala Public Jenkins <impala-public-jenkins@cloudera.com>
2023-03-09 22:00:08 +00:00
..
2017-08-31 01:40:47 +00:00