[IMP] Add savepoint and rollback if upgrade failed