AI / Apache Paimon Interview questions
What happens when you roll back a Paimon table to an earlier tag?
Rolling back moves a table's current state back to exactly what a given tag (or snapshot) captured, discarding everything that happened afterward as the table's "current" view. Because the tag already protected that point-in-time's manifests and data files from expiration, the rollback can complete purely as a metadata operation — no data needs to be rewritten or recopied.
CALL sys.rollback_to( `table` => 'my_db.my_table', tag => 'my-tag' );
After rollback, any snapshots created after the rollback point are no longer part of the table's active history going forward, though depending on retention configuration their underlying files may or may not be immediately reclaimed. This is the mechanism behind recovering from a bad batch write or an erroneous streaming job run: roll back to the last known-good tag rather than trying to hand-craft a fix.
More Related questions...