YSQL online DDL rollback safety after committed ALTER TABLE in YugabyteDB 2.x
0 reputation · 21 Aug 2023, 12:42 UTC
Goal
Determine whether a committed YSQL ALTER TABLE can be safely rolled back in YugabyteDB 2.x after the distributed master catalog and tablet leaders adopt the new catalog version.
Constraints and uncertainty
Online DDL is applied incrementally across tablets rather than as a single-node atomic commit, so clients attached to different nodes can temporarily observe different schema states. Forward-only migration guidance implies that rollback after a committed DDL is not guaranteed once catalog updates propagate. Safety may depend on the ALTER operation, cluster health, tablet leader placement, and concurrent writes, and the exact boundary is version-sensitive.
Confirm the exact boundary in the release notes for the target release before relying on any rollback behavior.
Is rollback supported for a committed ALTER TABLE after catalog version propagation? Which ALTER types, if any, permit automatic reversion without manual catalog repair? What compatibility boundary separates safe forward-only changes from changes requiring manual intervention?