From 216916ba418e99b6f8f6994148723e249eb1b589 Mon Sep 17 00:00:00 2001 From: Oliver Tan Date: Tue, 16 Aug 2022 09:38:29 +1000 Subject: [PATCH 1/9] go.mod: upgrade twpayne/go-geom This fixes ARM specific bugs. Release note (bug fix): Intersection spatial operations would previously potentially return incorrect results on ARM. This is now resolved. Release justification: bug fix for existing functionality --- DEPS.bzl | 172 ++++++++++++++---------------- build/bazelutil/distdir_files.bzl | 55 +++++----- go.mod | 24 ++--- go.sum | 72 +++++++++---- vendor | 2 +- 5 files changed, 171 insertions(+), 154 deletions(-) diff --git a/DEPS.bzl b/DEPS.bzl index 2755edbd3552..c85294c00664 100644 --- a/DEPS.bzl +++ b/DEPS.bzl @@ -1074,24 +1074,14 @@ def go_deps(): "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/com_github_cenkalti_backoff-v2.2.1+incompatible.zip", ], ) - go_repository( - name = "com_github_cenkalti_backoff_v3", - build_file_proto_mode = "disable_global", - importpath = "github.com/cenkalti/backoff/v3", - sha256 = "c69bf77e7b43cb3935d763c24af3810d9869a664bbcd26ffad9d3dc1bf602006", - strip_prefix = "github.com/cenkalti/backoff/v3@v3.0.0", - urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/v3/com_github_cenkalti_backoff_v3-v3.0.0.zip", - ], - ) go_repository( name = "com_github_cenkalti_backoff_v4", build_file_proto_mode = "disable_global", importpath = "github.com/cenkalti/backoff/v4", - sha256 = "079f531ecefaf6e9b9dd6600218979d83d9e64d0677553184ba412f10c88f820", - strip_prefix = "github.com/cenkalti/backoff/v4@v4.1.2", + sha256 = "73ff572a901c0307aa1c16db43812da7ca2555aa403cfdd9d3a239ecbdad2274", + strip_prefix = "github.com/cenkalti/backoff/v4@v4.1.3", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/v4/com_github_cenkalti_backoff_v4-v4.1.2.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/v4/com_github_cenkalti_backoff_v4-v4.1.3.zip", ], ) go_repository( @@ -1148,10 +1138,10 @@ def go_deps(): name = "com_github_checkpoint_restore_go_criu_v5", build_file_proto_mode = "disable_global", importpath = "github.com/checkpoint-restore/go-criu/v5", - sha256 = "2c0588503e6b07e6fc339e79f0f2b97986af506fbc6da14fd2c41d4d2a4ec2d3", - strip_prefix = "github.com/checkpoint-restore/go-criu/v5@v5.0.0", + sha256 = "fab492b56bf2e39a16b060456bdf74931ad2290dc33db3ba8d01807febd29ebd", + strip_prefix = "github.com/checkpoint-restore/go-criu/v5@v5.3.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/checkpoint-restore/go-criu/v5/com_github_checkpoint_restore_go_criu_v5-v5.0.0.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/checkpoint-restore/go-criu/v5/com_github_checkpoint_restore_go_criu_v5-v5.3.0.zip", ], ) go_repository( @@ -1188,10 +1178,10 @@ def go_deps(): name = "com_github_cilium_ebpf", build_file_proto_mode = "disable_global", importpath = "github.com/cilium/ebpf", - sha256 = "1f1d549887e91674a2286e0050ccf2c337617c1b031d79a38855951f87ef24d1", - strip_prefix = "github.com/cilium/ebpf@v0.6.2", + sha256 = "8591e96d9be4780ce83da65ee7a346ccaa93901a160cc8afb47386fe341b1ddb", + strip_prefix = "github.com/cilium/ebpf@v0.7.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cilium/ebpf/com_github_cilium_ebpf-v0.6.2.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cilium/ebpf/com_github_cilium_ebpf-v0.7.0.zip", ], ) go_repository( @@ -1571,10 +1561,10 @@ def go_deps(): name = "com_github_containerd_console", build_file_proto_mode = "disable_global", importpath = "github.com/containerd/console", - sha256 = "53af3db950dc4c31bbf3aade4b15750996c31efb34157c643232c8fcc0d1939c", - strip_prefix = "github.com/containerd/console@v1.0.2", + sha256 = "b7fdc4f70431cae45c8b89cbc604e993c0b9d7575e689ae8ee817630daaef3c4", + strip_prefix = "github.com/containerd/console@v1.0.3", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/console/com_github_containerd_console-v1.0.2.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/console/com_github_containerd_console-v1.0.3.zip", ], ) go_repository( @@ -1591,10 +1581,10 @@ def go_deps(): name = "com_github_containerd_continuity", build_file_proto_mode = "disable_global", importpath = "github.com/containerd/continuity", - sha256 = "668ac17fa51edffaf270edfe35dd4c973c737f297b96391086a5809a8e736351", - strip_prefix = "github.com/containerd/continuity@v0.2.2", + sha256 = "16fc80789184fad70748b4972aa2630c95f56d8eb46b530c2a69fe43c1d6e64b", + strip_prefix = "github.com/containerd/continuity@v0.3.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/continuity/com_github_containerd_continuity-v0.2.2.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/continuity/com_github_containerd_continuity-v0.3.0.zip", ], ) go_repository( @@ -1871,10 +1861,10 @@ def go_deps(): name = "com_github_cyphar_filepath_securejoin", build_file_proto_mode = "disable_global", importpath = "github.com/cyphar/filepath-securejoin", - sha256 = "d022873dbb9e8d3b7a43c9dedbea54dfc9a6c15f9632ba522a1257e8b948c100", - strip_prefix = "github.com/cyphar/filepath-securejoin@v0.2.2", + sha256 = "1e38690899f84b347ddc67cb8c6395812aea795e735b2208d680163278a3e3ba", + strip_prefix = "github.com/cyphar/filepath-securejoin@v0.2.3", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cyphar/filepath-securejoin/com_github_cyphar_filepath_securejoin-v0.2.2.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cyphar/filepath-securejoin/com_github_cyphar_filepath_securejoin-v0.2.3.zip", ], ) go_repository( @@ -1931,10 +1921,10 @@ def go_deps(): name = "com_github_data_dog_go_sqlmock", build_file_proto_mode = "disable_global", importpath = "github.com/DATA-DOG/go-sqlmock", - sha256 = "fe11397cc3551d3d4b015f2759862ce980d9930b3d807f8375a89b5180ae9f8e", - strip_prefix = "github.com/DATA-DOG/go-sqlmock@v1.4.1", + sha256 = "25720bfcbd739305238408ab54263224b69ff6934923dfd9caed76d3871d0151", + strip_prefix = "github.com/DATA-DOG/go-sqlmock@v1.5.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/DATA-DOG/go-sqlmock/com_github_data_dog_go_sqlmock-v1.4.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/DATA-DOG/go-sqlmock/com_github_data_dog_go_sqlmock-v1.5.0.zip", ], ) go_repository( @@ -2171,10 +2161,10 @@ def go_deps(): name = "com_github_docker_cli", build_file_proto_mode = "disable_global", importpath = "github.com/docker/cli", - sha256 = "7ecb380dfa0ef8d8f3cfada0136ecd00c115e005048bd5a8ee99f029aabe7df3", - strip_prefix = "github.com/docker/cli@v20.10.11+incompatible", + sha256 = "595cf0e156e2d8afa7e736cbbed7f307685d103fc6109ea75f9ca6ebcafb767d", + strip_prefix = "github.com/docker/cli@v20.10.17+incompatible", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/docker/cli/com_github_docker_cli-v20.10.11+incompatible.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/docker/cli/com_github_docker_cli-v20.10.17+incompatible.zip", ], ) go_repository( @@ -3292,10 +3282,10 @@ def go_deps(): name = "com_github_godbus_dbus_v5", build_file_proto_mode = "disable_global", importpath = "github.com/godbus/dbus/v5", - sha256 = "23a23f08bea48e6e49a46a4015b64adbb1692dc6ddf0d83c2f0c2027cb8e31c8", - strip_prefix = "github.com/godbus/dbus/v5@v5.0.4", + sha256 = "0097f9b4608dc4bf5ca63cd3a9f3334e5cff6be2cab6170cdef075ef97075d89", + strip_prefix = "github.com/godbus/dbus/v5@v5.0.6", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/godbus/dbus/v5/com_github_godbus_dbus_v5-v5.0.4.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/godbus/dbus/v5/com_github_godbus_dbus_v5-v5.0.6.zip", ], ) go_repository( @@ -4205,10 +4195,10 @@ def go_deps(): name = "com_github_imdario_mergo", build_file_proto_mode = "disable_global", importpath = "github.com/imdario/mergo", - sha256 = "a89fac0be93400703776d7dc164433c2f1ecd7f1fe9dc0308584daf609545c7e", - strip_prefix = "github.com/imdario/mergo@v0.3.12", + sha256 = "04f72d0e4695b4a004846a5d4f60d2dc381bacb032ebb8d58905e6eb00d121d2", + strip_prefix = "github.com/imdario/mergo@v0.3.13", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/imdario/mergo/com_github_imdario_mergo-v0.3.12.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/imdario/mergo/com_github_imdario_mergo-v0.3.13.zip", ], ) go_repository( @@ -5643,10 +5633,10 @@ def go_deps(): name = "com_github_microsoft_go_winio", build_file_proto_mode = "disable_global", importpath = "github.com/Microsoft/go-winio", - sha256 = "eab2669b05741bdf1c81eb1cc4176dfd91b8431bf4f9fe4ca4c93f89f99f2ecb", - strip_prefix = "github.com/Microsoft/go-winio@v0.5.1", + sha256 = "f479d42341fded1d0a98540713339920774f7540edf7a76b8497fbc11493138c", + strip_prefix = "github.com/Microsoft/go-winio@v0.5.2", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Microsoft/go-winio/com_github_microsoft_go_winio-v0.5.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Microsoft/go-winio/com_github_microsoft_go_winio-v0.5.2.zip", ], ) go_repository( @@ -5833,10 +5823,10 @@ def go_deps(): name = "com_github_mitchellh_mapstructure", build_file_proto_mode = "disable_global", importpath = "github.com/mitchellh/mapstructure", - sha256 = "bfe856861145c25f6f26c2985760e86a4634e2a28bb9b4582ff0e8a9d2621e10", - strip_prefix = "github.com/mitchellh/mapstructure@v1.4.1", + sha256 = "118d5b2cb65c50dba967fb6d708f450a9caf93f321f8fc99080675b2ee374199", + strip_prefix = "github.com/mitchellh/mapstructure@v1.5.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/mapstructure/com_github_mitchellh_mapstructure-v1.4.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/mapstructure/com_github_mitchellh_mapstructure-v1.5.0.zip", ], ) go_repository( @@ -5913,10 +5903,10 @@ def go_deps(): name = "com_github_moby_sys_mountinfo", build_file_proto_mode = "disable_global", importpath = "github.com/moby/sys/mountinfo", - sha256 = "0f32aa52a3be8bf724fe26307d144ffc4155bebbf1f4445388cc5fe9fe33bcc6", - strip_prefix = "github.com/moby/sys/mountinfo@v0.4.1", + sha256 = "8dfcdd129483164002cae296d0d4e58b139b6576b25e06c325963d902079018c", + strip_prefix = "github.com/moby/sys/mountinfo@v0.5.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/sys/mountinfo/com_github_moby_sys_mountinfo-v0.4.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/sys/mountinfo/com_github_moby_sys_mountinfo-v0.5.0.zip", ], ) go_repository( @@ -5933,10 +5923,10 @@ def go_deps(): name = "com_github_moby_term", build_file_proto_mode = "disable_global", importpath = "github.com/moby/term", - sha256 = "f01dbf40f90d9023cd67543a3bc2d64c58ac9f4d931e1ba5bebd80ce9ab9ca47", - strip_prefix = "github.com/moby/term@v0.0.0-20201216013528-df9cb8a40635", + sha256 = "0d2e2ce8280f803a14d9c2af23a79cf854e06d47f2e6b7d455291ffd47c11e2f", + strip_prefix = "github.com/moby/term@v0.0.0-20210619224110-3f7ff695adc6", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/term/com_github_moby_term-v0.0.0-20201216013528-df9cb8a40635.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/term/com_github_moby_term-v0.0.0-20210619224110-3f7ff695adc6.zip", ], ) go_repository( @@ -6343,10 +6333,10 @@ def go_deps(): name = "com_github_opencontainers_runc", build_file_proto_mode = "disable_global", importpath = "github.com/opencontainers/runc", - sha256 = "452d88828d8879bc3ce924e70ee9ae803748648dab0aee49f2245ba24f5e13bb", - strip_prefix = "github.com/opencontainers/runc@v1.0.2", + sha256 = "435b8597a57794fe7e0b9f3721f832983a6fe5dea2655eca061431198e7c813d", + strip_prefix = "github.com/opencontainers/runc@v1.1.3", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/runc/com_github_opencontainers_runc-v1.0.2.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/runc/com_github_opencontainers_runc-v1.1.3.zip", ], ) go_repository( @@ -6373,10 +6363,10 @@ def go_deps(): name = "com_github_opencontainers_selinux", build_file_proto_mode = "disable_global", importpath = "github.com/opencontainers/selinux", - sha256 = "73b8d89f127ed7851b312ead035ef8f6523a742185d161df26eb80c3e9a2f45c", - strip_prefix = "github.com/opencontainers/selinux@v1.8.2", + sha256 = "57bd7c4d8d9819b5c1bc40d0b57675f79182e41b4b1e66211fd1a8f1741cc977", + strip_prefix = "github.com/opencontainers/selinux@v1.10.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/selinux/com_github_opencontainers_selinux-v1.8.2.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/selinux/com_github_opencontainers_selinux-v1.10.0.zip", ], ) go_repository( @@ -6463,10 +6453,10 @@ def go_deps(): name = "com_github_ory_dockertest_v3", build_file_proto_mode = "disable_global", importpath = "github.com/ory/dockertest/v3", - sha256 = "78778d8292b1e2544d302c8bf7802e36aa333d6408ed2098bd3e6050d48778a6", - strip_prefix = "github.com/ory/dockertest/v3@v3.8.1", + sha256 = "2c9dabed798ccf07ac92653d8895ab50991ecc5f578806f7b856360bcc2087a9", + strip_prefix = "github.com/ory/dockertest/v3@v3.9.1", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/ory/dockertest/v3/com_github_ory_dockertest_v3-v3.8.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/ory/dockertest/v3/com_github_ory_dockertest_v3-v3.9.1.zip", ], ) go_repository( @@ -7190,10 +7180,10 @@ def go_deps(): name = "com_github_seccomp_libseccomp_golang", build_file_proto_mode = "disable_global", importpath = "github.com/seccomp/libseccomp-golang", - sha256 = "5989692d87ef4c377fbc60d441795a90d9453b9e357d019e44d9033ab39ca888", - strip_prefix = "github.com/seccomp/libseccomp-golang@v0.9.1", + sha256 = "6bbc0328826c9240ee9c08a59010b49d79d0d1264599811b6ac19f0d97494beb", + strip_prefix = "github.com/seccomp/libseccomp-golang@v0.9.2-0.20220502022130-f33da4d89646", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/seccomp/libseccomp-golang/com_github_seccomp_libseccomp_golang-v0.9.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/seccomp/libseccomp-golang/com_github_seccomp_libseccomp_golang-v0.9.2-0.20220502022130-f33da4d89646.zip", ], ) go_repository( @@ -7330,10 +7320,10 @@ def go_deps(): name = "com_github_sirupsen_logrus", build_file_proto_mode = "disable_global", importpath = "github.com/sirupsen/logrus", - sha256 = "8caec32e0aba1b95effc69d645b50f937137f78f0d0534b149f017dc0164a354", - strip_prefix = "github.com/sirupsen/logrus@v1.8.1", + sha256 = "bf01c93f49912b88ee2e95dc99cab91a503ec3b526d1c756145391d555b98d14", + strip_prefix = "github.com/sirupsen/logrus@v1.9.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sirupsen/logrus/com_github_sirupsen_logrus-v1.8.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sirupsen/logrus/com_github_sirupsen_logrus-v1.9.0.zip", ], ) go_repository( @@ -7550,20 +7540,20 @@ def go_deps(): name = "com_github_stretchr_objx", build_file_proto_mode = "disable_global", importpath = "github.com/stretchr/objx", - sha256 = "5517d43cfb7e628b9c2c64010b934e346cd24726e3d6eaf02b7f86e10752e968", - strip_prefix = "github.com/stretchr/objx@v0.2.0", + sha256 = "fb5c74373b4385e57e900b2a9ddec7ba1eda2c0d93fab4d307c15097dcaa0765", + strip_prefix = "github.com/stretchr/objx@v0.4.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/objx/com_github_stretchr_objx-v0.2.0.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/objx/com_github_stretchr_objx-v0.4.0.zip", ], ) go_repository( name = "com_github_stretchr_testify", build_file_proto_mode = "disable_global", importpath = "github.com/stretchr/testify", - sha256 = "5a46ccebeff510df3e2f6d3842ee79d3f68d0e7b1554cd6ee93390d68b6c6b34", - strip_prefix = "github.com/stretchr/testify@v1.7.0", + sha256 = "d880adf449449120b459a2220f539c69648fd797ded5b745cf3add60ec84081e", + strip_prefix = "github.com/stretchr/testify@v1.8.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/testify/com_github_stretchr_testify-v1.7.0.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/testify/com_github_stretchr_testify-v1.8.0.zip", ], ) go_repository( @@ -7720,10 +7710,10 @@ def go_deps(): name = "com_github_twpayne_go_geom", build_file_proto_mode = "disable_global", importpath = "github.com/twpayne/go-geom", - sha256 = "31c2358ae2f1c10a406c529737c0928971fa3e17f4f807a45b02cf3eebacd03a", - strip_prefix = "github.com/twpayne/go-geom@v1.4.1", + sha256 = "df7e9bbccc443348b23fbb67039e216700eb79ed79f9412b38a6bb8a81edb4cb", + strip_prefix = "github.com/twpayne/go-geom@v1.4.2", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twpayne/go-geom/com_github_twpayne_go_geom-v1.4.1.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twpayne/go-geom/com_github_twpayne_go_geom-v1.4.2.zip", ], ) go_repository( @@ -8040,10 +8030,10 @@ def go_deps(): name = "com_github_xeipuuv_gojsonpointer", build_file_proto_mode = "disable_global", importpath = "github.com/xeipuuv/gojsonpointer", - sha256 = "5b1a4bcc8e003f214c92b3fa52959d9eb0e3af1c0c529efa55815db951146e48", - strip_prefix = "github.com/xeipuuv/gojsonpointer@v0.0.0-20180127040702-4e3ac2762d5f", + sha256 = "11b54f0bc358b09261075c3e15cd14d57102f3ab1ba88c345c53eab6aaf228de", + strip_prefix = "github.com/xeipuuv/gojsonpointer@v0.0.0-20190905194746-02993c407bfb", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xeipuuv/gojsonpointer/com_github_xeipuuv_gojsonpointer-v0.0.0-20180127040702-4e3ac2762d5f.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xeipuuv/gojsonpointer/com_github_xeipuuv_gojsonpointer-v0.0.0-20190905194746-02993c407bfb.zip", ], ) go_repository( @@ -8680,10 +8670,10 @@ def go_deps(): name = "in_gopkg_yaml_v3", build_file_proto_mode = "disable_global", importpath = "gopkg.in/yaml.v3", - sha256 = "5169b5625d3c351f13e8a4ec4802f709072701b441ed92181c6051ece53615a9", - strip_prefix = "gopkg.in/yaml.v3@v3.0.0-20210107192922-496545a6307b", + sha256 = "aab8fbc4e6300ea08e6afe1caea18a21c90c79f489f52c53e2f20431f1a9a015", + strip_prefix = "gopkg.in/yaml.v3@v3.0.1", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/gopkg.in/yaml.v3/in_gopkg_yaml_v3-v3.0.0-20210107192922-496545a6307b.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/gopkg.in/yaml.v3/in_gopkg_yaml_v3-v3.0.1.zip", ], ) go_repository( @@ -9330,10 +9320,10 @@ def go_deps(): name = "org_golang_x_net", build_file_proto_mode = "disable_global", importpath = "golang.org/x/net", - sha256 = "b3d53182e3eb8aa90a0105e84dc8fe58aaa8e37168d2302e70165a1039b5548f", - strip_prefix = "golang.org/x/net@v0.0.0-20220524220425-1d687d428aca", + sha256 = "1decf7a324a0916bc66304da1b68a834ce679379422de3a2855f3031f6dc39bd", + strip_prefix = "golang.org/x/net@v0.0.0-20220722155237-a158d28d115b", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.0.0-20220524220425-1d687d428aca.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.0.0-20220722155237-a158d28d115b.zip", ], ) go_repository( @@ -9370,10 +9360,10 @@ def go_deps(): name = "org_golang_x_sys", build_file_proto_mode = "disable_global", importpath = "golang.org/x/sys", - sha256 = "734caf189549ea9b85dd93f58e87e3f3bceaec72229449f5879c3c067a2ad60e", - strip_prefix = "golang.org/x/sys@v0.0.0-20220520151302-bc2c85ada10a", + sha256 = "f4480597a942160a2aaeb761d41ee67f610287785c263f1df253a3e157c98594", + strip_prefix = "golang.org/x/sys@v0.0.0-20220722155257-8c9f86f7a55f", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.0.0-20220520151302-bc2c85ada10a.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.0.0-20220722155257-8c9f86f7a55f.zip", ], ) go_repository( @@ -9710,9 +9700,9 @@ def go_deps(): name = "tools_gotest_v3", build_file_proto_mode = "disable_global", importpath = "gotest.tools/v3", - sha256 = "9c1e4b8a1477c52441aafc2025a4b4e8bc300a9817c5549c0dc7fffef34bdaef", - strip_prefix = "gotest.tools/v3@v3.0.3", + sha256 = "fe238394013ebf35c313b7de60c5df5b6271f7c5f982eb8eecefe324531a0f5f", + strip_prefix = "gotest.tools/v3@v3.2.0", urls = [ - "https://storage.googleapis.com/cockroach-godeps/gomod/gotest.tools/v3/tools_gotest_v3-v3.0.3.zip", + "https://storage.googleapis.com/cockroach-godeps/gomod/gotest.tools/v3/tools_gotest_v3-v3.2.0.zip", ], ) diff --git a/build/bazelutil/distdir_files.bzl b/build/bazelutil/distdir_files.bzl index 4d9cf40ecc50..896f199b51a8 100644 --- a/build/bazelutil/distdir_files.bzl +++ b/build/bazelutil/distdir_files.bzl @@ -42,7 +42,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/CloudyKit/jet/com_github_cloudykit_jet-v2.1.3-0.20180809161101-62edd43e4f88+incompatible.zip": "9191d5a10096ea10bbb4ea576131ba943a6ec600fd7358237e21f995240ec72f", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/CloudyKit/jet/v3/com_github_cloudykit_jet_v3-v3.0.0.zip": "eba40af7c0be5a2c4b0cdff2475ae6e16cb7f1acb7531a02b77de06b9b4a527a", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Codefor/geohash/com_github_codefor_geohash-v0.0.0-20140723084247-1b41c28e3a9d.zip": "1f9d85fc86919143b53f8c3078fd4d2ed0271faf2eabba4460d7709f4f94c1e7", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/DATA-DOG/go-sqlmock/com_github_data_dog_go_sqlmock-v1.4.1.zip": "fe11397cc3551d3d4b015f2759862ce980d9930b3d807f8375a89b5180ae9f8e", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/DATA-DOG/go-sqlmock/com_github_data_dog_go_sqlmock-v1.5.0.zip": "25720bfcbd739305238408ab54263224b69ff6934923dfd9caed76d3871d0151", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/DataDog/datadog-go/com_github_datadog_datadog_go-v3.2.0+incompatible.zip": "ede4a024d3c106b2f57ca04d7bfc7610e0c83f4d8a3bace2cf87b42fd5cf66cd", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/DataDog/zstd/com_github_datadog_zstd-v1.5.0.zip": "00989c1f3f3426aa6ed41f641193ff6a0d81031ba0b7fd81250e7e923d2f18a4", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/GeertJohan/go.incremental/com_github_geertjohan_go_incremental-v1.0.0.zip": "ce46b3b717f8d2927046bcfb99c6f490b1b547a681e6b23240ac2c2292a891e8", @@ -59,7 +59,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Masterminds/sprig/com_github_masterminds_sprig-v2.22.0+incompatible.zip": "1b4d772334cc94e5703291b5f0fe4ac4965ac265424b1060baf18ef5ff9d845c", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Masterminds/vcs/com_github_masterminds_vcs-v1.13.0.zip": "c89f09e1c75a80c29d8be82b75a1015b9e811d25d93617f773962f2765d7c9c7", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/MichaelTJones/walk/com_github_michaeltjones_walk-v0.0.0-20161122175330-4748e29d5718.zip": "fd1f0195976f587977eb26c9795f7989c02c0701bdff6f2d155a617ee69fdf6e", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Microsoft/go-winio/com_github_microsoft_go_winio-v0.5.1.zip": "eab2669b05741bdf1c81eb1cc4176dfd91b8431bf4f9fe4ca4c93f89f99f2ecb", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Microsoft/go-winio/com_github_microsoft_go_winio-v0.5.2.zip": "f479d42341fded1d0a98540713339920774f7540edf7a76b8497fbc11493138c", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Microsoft/hcsshim/com_github_microsoft_hcsshim-v0.8.18.zip": "71a2ca0d284b6cd843db1b4b4ecd367af25194c1b66e4b50990c448706b0b777", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/Microsoft/hcsshim/test/com_github_microsoft_hcsshim_test-v0.0.0-20210227013316-43a75bb4edd3.zip": "576f610aff477764e340aca7381f68ad980c410fee028f1d629c0cb6dc865fe9", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/NYTimes/gziphandler/com_github_nytimes_gziphandler-v0.0.0-20170623195520-56545f4a5d46.zip": "0c2cce989a022621fd3445948136b5ffab40e36a9ef167fc5d6df79077359e50", @@ -157,18 +157,17 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cactus/go-statsd-client/statsd/com_github_cactus_go_statsd_client_statsd-v0.0.0-20191106001114-12b4e2b38748.zip": "7823c66e8c56c950643954712edbc9974669a10fe0041b67c9bd81dabd0538c0", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/casbin/casbin/v2/com_github_casbin_casbin_v2-v2.1.2.zip": "753df5c3fa5de68592e95fd55427f264dc7590a0bf781a77eb56ae721d6d3351", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/com_github_cenkalti_backoff-v2.2.1+incompatible.zip": "f8196815a1b4d25e5b8158029d5264801fc8aa5ff128ccf30752fd169693d43b", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/v3/com_github_cenkalti_backoff_v3-v3.0.0.zip": "c69bf77e7b43cb3935d763c24af3810d9869a664bbcd26ffad9d3dc1bf602006", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/v4/com_github_cenkalti_backoff_v4-v4.1.2.zip": "079f531ecefaf6e9b9dd6600218979d83d9e64d0677553184ba412f10c88f820", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cenkalti/backoff/v4/com_github_cenkalti_backoff_v4-v4.1.3.zip": "73ff572a901c0307aa1c16db43812da7ca2555aa403cfdd9d3a239ecbdad2274", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/census-instrumentation/opencensus-proto/com_github_census_instrumentation_opencensus_proto-v0.2.1.zip": "b3c09f3e635d47b4138695a547d1f2c7138f382cbe5a8b5865b66a8e08233461", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/certifi/gocertifi/com_github_certifi_gocertifi-v0.0.0-20200922220541-2c3bb06c6054.zip": "11d525844c3dd711fb0ae31acc9ebd8a4d602215f14ff24ad1764ecb48464849", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cespare/xxhash/com_github_cespare_xxhash-v1.1.0.zip": "fe98c56670b21631f7fd3305a29a3b17e86a6cce3876a2119460717a18538e2e", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cespare/xxhash/v2/com_github_cespare_xxhash_v2-v2.1.2.zip": "ac641ac8330df61f677c87448fc679c47886087d2933a1e431556f423782ea38", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/checkpoint-restore/go-criu/v4/com_github_checkpoint_restore_go_criu_v4-v4.1.0.zip": "e0413b7c67d41b9e77207db083387d2eb300356541f9048c7ff0670ba7ace524", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/checkpoint-restore/go-criu/v5/com_github_checkpoint_restore_go_criu_v5-v5.0.0.zip": "2c0588503e6b07e6fc339e79f0f2b97986af506fbc6da14fd2c41d4d2a4ec2d3", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/checkpoint-restore/go-criu/v5/com_github_checkpoint_restore_go_criu_v5-v5.3.0.zip": "fab492b56bf2e39a16b060456bdf74931ad2290dc33db3ba8d01807febd29ebd", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/chzyer/logex/com_github_chzyer_logex-v1.1.10.zip": "2c94771c1e335a2c58a96444b3768b8e00297747d6ce7e7c14bab2e8b39d91bd", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/chzyer/readline/com_github_chzyer_readline-v0.0.0-20180603132655-2972be24d48e.zip": "3dc842677887278fb33d25078d375ae6a7a94bb77a8d205ee2230b581b6947a6", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/chzyer/test/com_github_chzyer_test-v0.0.0-20180213035817-a1ea475d72b1.zip": "ad8550bed3c4a94bbef57b9fc5bb15806eaceda00925716404320580d60e2f7d", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cilium/ebpf/com_github_cilium_ebpf-v0.6.2.zip": "1f1d549887e91674a2286e0050ccf2c337617c1b031d79a38855951f87ef24d1", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cilium/ebpf/com_github_cilium_ebpf-v0.7.0.zip": "8591e96d9be4780ce83da65ee7a346ccaa93901a160cc8afb47386fe341b1ddb", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/circonus-labs/circonus-gometrics/com_github_circonus_labs_circonus_gometrics-v2.3.1+incompatible.zip": "d8081141497e3cd34844df66af016c7900d58b324fb689e17e57bc053d91c9ba", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/circonus-labs/circonusllhist/com_github_circonus_labs_circonusllhist-v0.1.3.zip": "4dc805d9735dd9ca9b8875c0ad23126abb5bc969c5a40c61b5bc891808dbdcb6", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/clbanning/x2j/com_github_clbanning_x2j-v0.0.0-20191024224557-825249438eec.zip": "747daafe80e4ac504626c01a1d28b1a64b785586975a47b50d62853a444b72a0", @@ -204,9 +203,9 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/aufs/com_github_containerd_aufs-v1.0.0.zip": "66f63be768b16cdee12c6d040d4aa7c0e8af306c7620b0c18c1f636c8499ae52", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/btrfs/com_github_containerd_btrfs-v1.0.0.zip": "b6098229f65fe790a52e4db949ae020d9ff00fcd82b90ecb1337291a5aa8f9da", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/cgroups/com_github_containerd_cgroups-v1.0.1.zip": "68ef11daf1ad2ade3fa34665536c2cd51cd3e38fd0af4993fca6e1455a6d560f", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/console/com_github_containerd_console-v1.0.2.zip": "53af3db950dc4c31bbf3aade4b15750996c31efb34157c643232c8fcc0d1939c", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/console/com_github_containerd_console-v1.0.3.zip": "b7fdc4f70431cae45c8b89cbc604e993c0b9d7575e689ae8ee817630daaef3c4", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/containerd/com_github_containerd_containerd-v1.5.4.zip": "a88697b3fab925d50c5d0f10d6820ea42ca96b38dc52231ae7d4158c921e5190", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/continuity/com_github_containerd_continuity-v0.2.2.zip": "668ac17fa51edffaf270edfe35dd4c973c737f297b96391086a5809a8e736351", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/continuity/com_github_containerd_continuity-v0.3.0.zip": "16fc80789184fad70748b4972aa2630c95f56d8eb46b530c2a69fe43c1d6e64b", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/fifo/com_github_containerd_fifo-v1.0.0.zip": "6c0505fda39dbb0216326f55d9cdf7dd8a39367c0cf91d3e344fb177bfd7d639", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/go-cni/com_github_containerd_go_cni-v1.0.2.zip": "a4d7aa24c80d4dc1c6ec75534db6c3dbca5be628469f266f36f675e071ebb3dc", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/containerd/go-runc/com_github_containerd_go_runc-v1.0.0.zip": "61097092c5da43412b54044ede11e84920c52f774c880537df3e1c302ce08951", @@ -234,7 +233,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/crossdock/crossdock-go/com_github_crossdock_crossdock_go-v0.0.0-20160816171116-049aabb0122b.zip": "f8a2ed6cd39e4f3e8108b8987f72bf6746276ada6fd3fcc62015bdbdd097f1a3", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cyberdelia/go-metrics-graphite/com_github_cyberdelia_go_metrics_graphite-v0.0.0-20161219230853-39f87cc3b432.zip": "38a34b96a597d50553e367de6e4eb3488e83dc37cae3930b38d9b48695b08b0c", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cyberdelia/templates/com_github_cyberdelia_templates-v0.0.0-20141128023046-ca7fffd4298c.zip": "a0ed6b8037d36222f63128f6064ed5b0e461fa9798c3592440a08875154d6c72", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cyphar/filepath-securejoin/com_github_cyphar_filepath_securejoin-v0.2.2.zip": "d022873dbb9e8d3b7a43c9dedbea54dfc9a6c15f9632ba522a1257e8b948c100", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/cyphar/filepath-securejoin/com_github_cyphar_filepath_securejoin-v0.2.3.zip": "1e38690899f84b347ddc67cb8c6395812aea795e735b2208d680163278a3e3ba", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/d2g/dhcp4/com_github_d2g_dhcp4-v0.0.0-20170904100407-a1d1b6c41b1c.zip": "15df9468cf548a626e1319e92d550432512c4319cf555bf278ea9215de3504e3", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/d2g/dhcp4client/com_github_d2g_dhcp4client-v1.0.0.zip": "cad5e5d2e85d2f4b68835ea63472f24a6627d6f87058358df4b47902374a6a8b", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/d2g/dhcp4server/com_github_d2g_dhcp4server-v0.0.0-20181031114812-7d4a0a7f59a5.zip": "b2370ecaf825f0dc748a234fb676fbd9d24ac6d28eaa9d7c3a8f807a2badf11d", @@ -261,7 +260,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/dimchansky/utfbom/com_github_dimchansky_utfbom-v1.1.1.zip": "0c1a11101602d5f57ac3e790c0b72e09ff87d8d535535f43fbee9e6a42327350", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/djherbis/atime/com_github_djherbis_atime-v1.1.0.zip": "195cebcceb6d76328f5e5d373154b5c46a6a9bf6b27a88f9c0158276a07c7c41", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/dnaeon/go-vcr/com_github_dnaeon_go_vcr-v1.2.0.zip": "6d34b7e17c158d51ffc34f6ac64df05ab736b2ae50c0db07be4a9556dac10c52", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/docker/cli/com_github_docker_cli-v20.10.11+incompatible.zip": "7ecb380dfa0ef8d8f3cfada0136ecd00c115e005048bd5a8ee99f029aabe7df3", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/docker/cli/com_github_docker_cli-v20.10.17+incompatible.zip": "595cf0e156e2d8afa7e736cbbed7f307685d103fc6109ea75f9ca6ebcafb767d", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/docker/distribution/com_github_docker_distribution-v2.7.1+incompatible.zip": "be78bc43d74873b67afe05a6b244490088680dab75bdfaf26d0fd4d054595bc7", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/docker/go-connections/com_github_docker_go_connections-v0.4.0.zip": "570ebcee7e6fd844e00c89eeab2b1922081d6969df76078dfe4ffacd3db56ada", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/docker/go-events/com_github_docker_go_events-v0.0.0-20190806004212-e31b211e4f1c.zip": "0f654eb0e7e07c237a229935ea3488728ddb5b082af2918b64452a1129dccae3", @@ -370,7 +369,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/gobwas/ws/com_github_gobwas_ws-v1.0.2.zip": "f9e5c26e83278f19958c68be7b76ad6711c806b6dae766fad7692d2af867bedd", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/gocql/gocql/com_github_gocql_gocql-v0.0.0-20200228163523-cd4b606dd2fb.zip": "40095e622040db188068b66258742938a5b083f6696b46b4a40c0391f0dafcec", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/godbus/dbus/com_github_godbus_dbus-v0.0.0-20190422162347-ade71ed3457e.zip": "4949c4ae117d0c306a28bb05a7da82be3c4a76676939e6ec60540335c8eff90d", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/godbus/dbus/v5/com_github_godbus_dbus_v5-v5.0.4.zip": "23a23f08bea48e6e49a46a4015b64adbb1692dc6ddf0d83c2f0c2027cb8e31c8", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/godbus/dbus/v5/com_github_godbus_dbus_v5-v5.0.6.zip": "0097f9b4608dc4bf5ca63cd3a9f3334e5cff6be2cab6170cdef075ef97075d89", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/gofrs/flock/com_github_gofrs_flock-v0.8.1.zip": "9ace5b0a05672937904fba1fcb86cb45e7f701e508faeb5f612e243340351dfa", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/gofrs/uuid/com_github_gofrs_uuid-v4.0.0+incompatible.zip": "8cadafda9aea197d34898d6945692173ac1d8abf3b559c4e5a59a577fc60f55e", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/gogo/googleapis/com_github_gogo_googleapis-v1.4.1.zip": "34110f4fe52daa66bf190e6c5be70e2e384ceca3cb1bce3e20f32994ede5a141", @@ -459,7 +458,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/iancoleman/strcase/com_github_iancoleman_strcase-v0.2.0.zip": "cb5027fec91d36426f0978a6c42ab52d8735fa3e1711be0127feda70a9a9fd05", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/ianlancetaylor/demangle/com_github_ianlancetaylor_demangle-v0.0.0-20200824232613-28f6c0f3b639.zip": "f5709a6601f0b4dc17da3baba1a50cc95ebf3efdd040aecc7fcf4d0e89bab066", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/icrowley/fake/com_github_icrowley_fake-v0.0.0-20180203215853-4178557ae428.zip": "b503a0bc24e79b470d85701a11294430274f1203977e931008a88543f9f56fd4", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/imdario/mergo/com_github_imdario_mergo-v0.3.12.zip": "a89fac0be93400703776d7dc164433c2f1ecd7f1fe9dc0308584daf609545c7e", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/imdario/mergo/com_github_imdario_mergo-v0.3.13.zip": "04f72d0e4695b4a004846a5d4f60d2dc381bacb032ebb8d58905e6eb00d121d2", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/imkira/go-interpol/com_github_imkira_go_interpol-v1.1.0.zip": "de5111f7694700ea056beeb7c1ca1a827075d423422f251076ee17bd869477d9", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/inconshreveable/mousetrap/com_github_inconshreveable_mousetrap-v1.0.0.zip": "c3fa0813e78f5cef10dc0e9912c43e68e06ff970a98e98c4050fe14dbbfd18c7", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/influxdata/flux/com_github_influxdata_flux-v0.120.1.zip": "0cfc34ed0de87e3b1b47a656034761bbba5556c68de21f8989865955a85350cc", @@ -606,7 +605,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/go-wordwrap/com_github_mitchellh_go_wordwrap-v1.0.0.zip": "9ea185f97dfe616da351b63b229a5a212b14ac0e23bd3f943e39590eadb38031", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/gox/com_github_mitchellh_gox-v0.4.0.zip": "70c976edc82b069d55c4b05409be9e91d85c20238a5e38c60fbb0b03b43c9550", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/iochan/com_github_mitchellh_iochan-v1.0.0.zip": "f3eede01adb24c22945bf71b4f84ae25e3744a12b9d8bd7c016705adc0d778b8", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/mapstructure/com_github_mitchellh_mapstructure-v1.4.1.zip": "bfe856861145c25f6f26c2985760e86a4634e2a28bb9b4582ff0e8a9d2621e10", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/mapstructure/com_github_mitchellh_mapstructure-v1.5.0.zip": "118d5b2cb65c50dba967fb6d708f450a9caf93f321f8fc99080675b2ee374199", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/osext/com_github_mitchellh_osext-v0.0.0-20151018003038-5e2d6d41470f.zip": "d8e6e5f6bd749cfa0c1c17c40f5dc0fd19e4a0a83245f46bde23bea4e65d1a20", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mitchellh/reflectwalk/com_github_mitchellh_reflectwalk-v1.0.0.zip": "318ab84e22d4554a7540c7ebc9b4fb607e2608578c3a5bb72434203988048145", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/mjibson/esc/com_github_mjibson_esc-v0.2.0.zip": "9f090786bd43dddb5c0d798b449d5e8aede4cb7d106f56dcac0aebd8fd1929cc", @@ -615,9 +614,9 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/locker/com_github_moby_locker-v1.0.1.zip": "f07361346d12a24e168db7fb2f21281883bee6060f1aedf7507bccf20c4a793f", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/moby/com_github_moby_moby-v20.10.6+incompatible.zip": "b96610497d8d7b41eff039cd4b4ba595eedb3944b653b813f087364805e3db76", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/spdystream/com_github_moby_spdystream-v0.2.0.zip": "9db6d001a80f4c3cb332bb8a1bb9260908e1ffa9a20491e9bc05358263eed278", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/sys/mountinfo/com_github_moby_sys_mountinfo-v0.4.1.zip": "0f32aa52a3be8bf724fe26307d144ffc4155bebbf1f4445388cc5fe9fe33bcc6", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/sys/mountinfo/com_github_moby_sys_mountinfo-v0.5.0.zip": "8dfcdd129483164002cae296d0d4e58b139b6576b25e06c325963d902079018c", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/sys/symlink/com_github_moby_sys_symlink-v0.1.0.zip": "55ff27f7b35dc22c63c5ea4d79a127d45a18df2fcd2f22ca16f9a424c4b4cf51", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/term/com_github_moby_term-v0.0.0-20201216013528-df9cb8a40635.zip": "f01dbf40f90d9023cd67543a3bc2d64c58ac9f4d931e1ba5bebd80ce9ab9ca47", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/moby/term/com_github_moby_term-v0.0.0-20210619224110-3f7ff695adc6.zip": "0d2e2ce8280f803a14d9c2af23a79cf854e06d47f2e6b7d455291ffd47c11e2f", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/modern-go/concurrent/com_github_modern_go_concurrent-v0.0.0-20180306012644-bacd9c7ef1dd.zip": "91ef49599bec459869d94ff3dec128871ab66bd2dfa61041f1e1169f9b4a8073", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/modern-go/reflect2/com_github_modern_go_reflect2-v1.0.2.zip": "f46f41409c2e74293f82cfe6c70b5d582bff8ada0106a7d3ff5706520c50c21c", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/modocache/gover/com_github_modocache_gover-v0.0.0-20171022184752-b58185e213c5.zip": "4a96d0a90331d92074e902cf2772d22c1a067438bc627713b80bba4d5509e3d3", @@ -654,10 +653,10 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/op/go-logging/com_github_op_go_logging-v0.0.0-20160315200505-970db520ece7.zip": "c506eace74028656eb28677a4c162f9c023ce2f9c0207354ba80cca89f11b461", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/go-digest/com_github_opencontainers_go_digest-v1.0.0.zip": "615efb31ff6cd71035b8aa38c3659d8b4da46f3cd92ac807cb50449adfe37c86", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/image-spec/com_github_opencontainers_image_spec-v1.0.2.zip": "d842127b6038c1a74c2bb609d75bdde0ac9c7cde5c354ac82c4f953ce08d0c08", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/runc/com_github_opencontainers_runc-v1.0.2.zip": "452d88828d8879bc3ce924e70ee9ae803748648dab0aee49f2245ba24f5e13bb", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/runc/com_github_opencontainers_runc-v1.1.3.zip": "435b8597a57794fe7e0b9f3721f832983a6fe5dea2655eca061431198e7c813d", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/runtime-spec/com_github_opencontainers_runtime_spec-v1.0.3-0.20210326190908-1c3f411f0417.zip": "5197cb24f4f9d29287ab2f86d4ad46e19a1d042940b156d458b30ce2b641ce5e", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/runtime-tools/com_github_opencontainers_runtime_tools-v0.0.0-20181011054405-1d69bd0f9c39.zip": "49e4ed2cb59461d3af837a3d624096b1fb8f3f0aa021e11c2d3025cca83d862f", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/selinux/com_github_opencontainers_selinux-v1.8.2.zip": "73b8d89f127ed7851b312ead035ef8f6523a742185d161df26eb80c3e9a2f45c", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opencontainers/selinux/com_github_opencontainers_selinux-v1.10.0.zip": "57bd7c4d8d9819b5c1bc40d0b57675f79182e41b4b1e66211fd1a8f1741cc977", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opennota/wd/com_github_opennota_wd-v0.0.0-20180911144301-b446539ab1e7.zip": "f7976f0639a473690c38576162f76c9b253e0867e6dea81257375baa56cf79e9", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opentracing-contrib/go-grpc/com_github_opentracing_contrib_go_grpc-v0.0.0-20180928155321-4b5a12d3ff02.zip": "51f4dabc672c3d1f4c91eb09f033bab42620e55ee477c01751adeee0b6524f89", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opentracing-contrib/go-observer/com_github_opentracing_contrib_go_observer-v0.0.0-20170622124052-a52f23424492.zip": "50023eee1ef04412410f43d8b5dcf3ef481c0fc39067add27799654705fa84b2", @@ -666,7 +665,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/opentracing/opentracing-go/com_github_opentracing_opentracing_go-v1.2.0.zip": "9b1a75e9a454a0cf01a26c18e48cd321e3b300943ac5adb9098ba033dbd40db5", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/openzipkin-contrib/zipkin-go-opentracing/com_github_openzipkin_contrib_zipkin_go_opentracing-v0.4.5.zip": "74763b01a30fa2f7116f0408c792b4db50bb01200cfe5f3f8b351ac638d1adb4", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/openzipkin/zipkin-go/com_github_openzipkin_zipkin_go-v0.2.5.zip": "337535c088bd6f7a479e21747044286f66490871948989d52f7812bc4cca955e", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/ory/dockertest/v3/com_github_ory_dockertest_v3-v3.8.1.zip": "78778d8292b1e2544d302c8bf7802e36aa333d6408ed2098bd3e6050d48778a6", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/ory/dockertest/v3/com_github_ory_dockertest_v3-v3.9.1.zip": "2c9dabed798ccf07ac92653d8895ab50991ecc5f578806f7b856360bcc2087a9", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/otan-cockroach/go-libedit/com_github_otan_cockroach_go_libedit-v1.10.2-0.20201030151939-7cced08450e7.zip": "d2ae0f8e43c49f917a2cadf52178c0efe1336fda5b8410a3d0f1270ae05d2532", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/otan/gopgkrb5/com_github_otan_gopgkrb5-v1.0.3.zip": "8d7241eed0a03a88654c49ee0a0c5db4f5bd37682011ee953cddb623f16bb349", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/oxtoacart/bpool/com_github_oxtoacart_bpool-v0.0.0-20190530202638-03653db5a59c.zip": "6816ec3a6f197cbee0ba6ddb9ec70958bc28870e59864b24e43da0c858079a1b", @@ -735,7 +734,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sclevine/agouti/com_github_sclevine_agouti-v3.0.0+incompatible.zip": "b20c8a6a2c1fda0ae6a9cd6d319e78a7a5afea4bc90810cd46b99246d8219d23", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/scylladb/termtables/com_github_scylladb_termtables-v0.0.0-20191203121021-c4c0b6d42ff4.zip": "0afd3a75417e6b708c62329cea7f2822162c8bf6ada0de094cdc032461b8f196", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sean-/seed/com_github_sean__seed-v0.0.0-20170313163322-e2103e2c3529.zip": "0bc8e6e0a07e554674b0bb92ef4eb7de1650056b50878eed8d5d631aec9b6362", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/seccomp/libseccomp-golang/com_github_seccomp_libseccomp_golang-v0.9.1.zip": "5989692d87ef4c377fbc60d441795a90d9453b9e357d019e44d9033ab39ca888", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/seccomp/libseccomp-golang/com_github_seccomp_libseccomp_golang-v0.9.2-0.20220502022130-f33da4d89646.zip": "6bbc0328826c9240ee9c08a59010b49d79d0d1264599811b6ac19f0d97494beb", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sectioneight/md-to-godoc/com_github_sectioneight_md_to_godoc-v0.0.0-20161108233149-55e43be6c335.zip": "8b605818df307b414d0a680f147f0baeb37c9166df9e111ede5531cf50124203", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/securego/gosec/com_github_securego_gosec-v0.0.0-20200203094520-d13bb6d2420c.zip": "e0adea3cd40ba9d690b8054ff1341cf7d035084f50273a4f7bbac803fec3453a", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/segmentio/kafka-go/com_github_segmentio_kafka_go-v0.2.0.zip": "b2a88eb5b65fbb75dac0ba5e721cd2cb8e39275d1702a0f97e3c4807d78e8b48", @@ -745,7 +744,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/shurcooL/httpfs/com_github_shurcool_httpfs-v0.0.0-20190707220628-8d4bc4ba7749.zip": "a2079dbd8c236262ecbb22312467265fbbddd9b5ee789531c5f7f24fbdda174b", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/shurcooL/sanitized_anchor_name/com_github_shurcool_sanitized_anchor_name-v1.0.0.zip": "0af034323e0627a9e94367f87aa50ce29e5b165d54c8da2926cbaffd5834f757", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/shurcooL/vfsgen/com_github_shurcool_vfsgen-v0.0.0-20200824052919-0d455de96546.zip": "98198ecd8f122d1266ff2db193f1aae8a88f2f299bfc34b06ef356694cca537d", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sirupsen/logrus/com_github_sirupsen_logrus-v1.8.1.zip": "8caec32e0aba1b95effc69d645b50f937137f78f0d0534b149f017dc0164a354", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sirupsen/logrus/com_github_sirupsen_logrus-v1.9.0.zip": "bf01c93f49912b88ee2e95dc99cab91a503ec3b526d1c756145391d555b98d14", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/sjmudd/stopwatch/com_github_sjmudd_stopwatch-v0.0.0-20170613150411-f380bf8a9be1.zip": "69e0ed207172b04161ccb26977f4c657fbee77296eca0b7ff84f8b1f2c2a6847", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/slack-go/slack/com_github_slack_go_slack-v0.9.5.zip": "2b1cc2d4107c7017f1348beefeb23db1cdbecf94b32590da364daed420371cde", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/slok/go-http-metrics/com_github_slok_go_http_metrics-v0.10.0.zip": "bf2e2b626e4fbd9735165494c574f2474f400786d8bd96b6b4648eba352c817b", @@ -767,8 +766,8 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/streadway/amqp/com_github_streadway_amqp-v0.0.0-20190827072141-edfb9018d271.zip": "66bd109504bf565a4a777c20a8cf6a1c5d05cd87b59baa50da8b6f2b0da4c494", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/streadway/handy/com_github_streadway_handy-v0.0.0-20190108123426-d5acb3125c2a.zip": "f770ed96081220a9cbc5e975a06c2858b4f3d02820cb9902982116af491b171f", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/streadway/quantile/com_github_streadway_quantile-v0.0.0-20150917103942-b0c588724d25.zip": "45156bab62475784e2eacb349570c86bcf245a84d97825ce9ee2bf604a4438d5", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/objx/com_github_stretchr_objx-v0.2.0.zip": "5517d43cfb7e628b9c2c64010b934e346cd24726e3d6eaf02b7f86e10752e968", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/testify/com_github_stretchr_testify-v1.7.0.zip": "5a46ccebeff510df3e2f6d3842ee79d3f68d0e7b1554cd6ee93390d68b6c6b34", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/objx/com_github_stretchr_objx-v0.4.0.zip": "fb5c74373b4385e57e900b2a9ddec7ba1eda2c0d93fab4d307c15097dcaa0765", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/stretchr/testify/com_github_stretchr_testify-v1.8.0.zip": "d880adf449449120b459a2220f539c69648fd797ded5b745cf3add60ec84081e", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/subosito/gotenv/com_github_subosito_gotenv-v1.2.0.zip": "21474df92536f36de6f91dfbf466995289445cc4e5a5900d9c40ae8776b8b0cf", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/syndtr/gocapability/com_github_syndtr_gocapability-v0.0.0-20200815063812-42c35b437635.zip": "91ff91da1936e17aa68fc13756e40ba4db1d7c9375a4ef0969fe19c9aa281195", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/tchap/go-patricia/com_github_tchap_go_patricia-v2.2.6+incompatible.zip": "948494017eae153a8c2d4ae9b450fd42abcb2578211f1c28e69ab71a2f27814d", @@ -783,7 +782,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/trivago/tgo/com_github_trivago_tgo-v1.0.7.zip": "795b3a41901f6b694195d6be9c6e7730a971fbc0ec4cd236e73cc845aca6cb7e", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/tv42/httpunix/com_github_tv42_httpunix-v0.0.0-20191220191345-2ba4b9c3382c.zip": "3835d37bfd63336db8f0b0971368e0e9a03d70a446b32e93cbd30e99ba6e9d27", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twitchtv/twirp/com_github_twitchtv_twirp-v8.1.0+incompatible.zip": "6a5499c6572cf367ac9c2bd7913abef5bc8ef9de5e7194d12452863ddcec6104", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twpayne/go-geom/com_github_twpayne_go_geom-v1.4.1.zip": "31c2358ae2f1c10a406c529737c0928971fa3e17f4f807a45b02cf3eebacd03a", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twpayne/go-geom/com_github_twpayne_go_geom-v1.4.2.zip": "df7e9bbccc443348b23fbb67039e216700eb79ed79f9412b38a6bb8a81edb4cb", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twpayne/go-kml/com_github_twpayne_go_kml-v1.5.2.zip": "f67a698f9a02c889a1f6ff4e0a0625ec2359057674c0f25cf8c862ae519e382e", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twpayne/go-polyline/com_github_twpayne_go_polyline-v1.0.0.zip": "1794c8b7368bd16dec9cdb7b9be394c2030a1cc706a51edc318490667d9a5a97", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/twpayne/go-waypoint/com_github_twpayne_go_waypoint-v0.0.0-20200706203930-b263a7f6e4e8.zip": "8163a963b71e0723d694f87eeb15e3a7f9a32ad5fd189a1b78cf0aa293d300c8", @@ -813,7 +812,7 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xdg-go/stringprep/com_github_xdg_go_stringprep-v1.0.2.zip": "4f4d7c8ba09ab5fa288ff86902c2f4000f3a85cd55d9ff75a04ade18c8e33ad9", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xdg/scram/com_github_xdg_scram-v1.0.3.zip": "56875f465f0ed3170846db4d300328b9c769c35a3c59a479c8b9ac659765e48c", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xdg/stringprep/com_github_xdg_stringprep-v1.0.3.zip": "7cb9711fd7b3c1518e1fbd4e39be11737d7006a5e4a59f1ceb4ba9c205eb90fa", - "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xeipuuv/gojsonpointer/com_github_xeipuuv_gojsonpointer-v0.0.0-20180127040702-4e3ac2762d5f.zip": "5b1a4bcc8e003f214c92b3fa52959d9eb0e3af1c0c529efa55815db951146e48", + "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xeipuuv/gojsonpointer/com_github_xeipuuv_gojsonpointer-v0.0.0-20190905194746-02993c407bfb.zip": "11b54f0bc358b09261075c3e15cd14d57102f3ab1ba88c345c53eab6aaf228de", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xeipuuv/gojsonreference/com_github_xeipuuv_gojsonreference-v0.0.0-20180127040603-bd5ef7bd5415.zip": "7ec98f4df894413f4dc58c8df330ca8b24ff425b05a8e1074c3028c99f7e45e7", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xeipuuv/gojsonschema/com_github_xeipuuv_gojsonschema-v1.2.0.zip": "55c8ce068257aa0d263aad7470113dafcd50f955ee754fc853c2fdcd31ad096f", "https://storage.googleapis.com/cockroach-godeps/gomod/github.com/xiang90/probing/com_github_xiang90_probing-v0.0.0-20190116061207-43a291ad63a2.zip": "437bdc666239fda4581b592b068001f08269c68c70699a721bff9334412d4181", @@ -867,11 +866,11 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/lint/org_golang_x_lint-v0.0.0-20210508222113-6edffad5e616.zip": "0a4a5ebd2b1d79e7f480cbf5a54b45a257ae1ec9d11f01688efc5c35268d4603", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/mobile/org_golang_x_mobile-v0.0.0-20201217150744-e6ae53a27f4f.zip": "1fd2f665cdb7f64b80e2e1224941d1ecad10bd99327c6fc8906183d2ef3816df", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/mod/org_golang_x_mod-v0.6.0-dev.0.20220419223038-86c51ed26bb4.zip": "2b7471ed34a349f91055527c5328acd40e9aba006b644e51d40a8627efa76a92", - "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.0.0-20220524220425-1d687d428aca.zip": "b3d53182e3eb8aa90a0105e84dc8fe58aaa8e37168d2302e70165a1039b5548f", + "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/net/org_golang_x_net-v0.0.0-20220722155237-a158d28d115b.zip": "1decf7a324a0916bc66304da1b68a834ce679379422de3a2855f3031f6dc39bd", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/oauth2/org_golang_x_oauth2-v0.0.0-20220411215720-9780585627b5.zip": "81f60a99f4f3bcb34993ca5831386d8399c472a0ca4dc6f1e3659a071d002029", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/perf/org_golang_x_perf-v0.0.0-20180704124530-6e6d33e29852.zip": "a2c7d02cc94c4ba767b6322f70ddcba4941cb5f60fed1bada3aa7a4d3a8128f1", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sync/org_golang_x_sync-v0.0.0-20220513210516-0976fa681c29.zip": "71d4baca5c8f5ba665560e1bd96e3f73187d73d7dbc8f4a26faa73e5865b0749", - "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.0.0-20220520151302-bc2c85ada10a.zip": "734caf189549ea9b85dd93f58e87e3f3bceaec72229449f5879c3c067a2ad60e", + "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/sys/org_golang_x_sys-v0.0.0-20220722155257-8c9f86f7a55f.zip": "f4480597a942160a2aaeb761d41ee67f610287785c263f1df253a3e157c98594", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/term/org_golang_x_term-v0.0.0-20210927222741-03fcf44c2211.zip": "3adf713afa49fe26580ffe4adb1f4fb2f4921c945301aa5a9fb6d34031fa30cd", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/text/org_golang_x_text-v0.3.7.zip": "e1a9115e61a38da8bdc893d0ba83b65f89cc1114f152a98eb572c5ea6551e8d4", "https://storage.googleapis.com/cockroach-godeps/gomod/golang.org/x/time/org_golang_x_time-v0.0.0-20210723032227-1f47c861a9ac.zip": "e5d8ade42804ec7d96a632c031dde7db087e8bc4cd5dfd6f38df03ce4f16d9b6", @@ -918,11 +917,11 @@ DISTDIR_FILES = { "https://storage.googleapis.com/cockroach-godeps/gomod/gopkg.in/src-d/go-billy.v4/in_gopkg_src_d_go_billy_v4-v4.3.0.zip": "389c7137c3424429eb3454b382a19a4c5050b397f80a9be112a50e65d8a0e353", "https://storage.googleapis.com/cockroach-godeps/gomod/gopkg.in/tomb.v1/in_gopkg_tomb_v1-v1.0.0-20141024135613-dd632973f1e7.zip": "34898dc0e38ba7a792ab74a3e0fa113116313fd9142ffb444b011fd392762186", "https://storage.googleapis.com/cockroach-godeps/gomod/gopkg.in/warnings.v0/in_gopkg_warnings_v0-v0.1.2.zip": "c412b1f704c1e8ba59b6cfdb1072f8be847c03f77d6507c692913d6d9454e51c", - "https://storage.googleapis.com/cockroach-godeps/gomod/gopkg.in/yaml.v3/in_gopkg_yaml_v3-v3.0.0-20210107192922-496545a6307b.zip": "5169b5625d3c351f13e8a4ec4802f709072701b441ed92181c6051ece53615a9", + "https://storage.googleapis.com/cockroach-godeps/gomod/gopkg.in/yaml.v3/in_gopkg_yaml_v3-v3.0.1.zip": "aab8fbc4e6300ea08e6afe1caea18a21c90c79f489f52c53e2f20431f1a9a015", "https://storage.googleapis.com/cockroach-godeps/gomod/gorm.io/driver/postgres/io_gorm_driver_postgres-v1.0.8.zip": "a35ed3044796b91cf9ead206329ceb34b256da3044a3528a3aa185cd128f8ac8", "https://storage.googleapis.com/cockroach-godeps/gomod/gorm.io/gorm/io_gorm_gorm-v1.21.4.zip": "4048b3c1d2cd0b8372755fcf9bc33d621c1e532e4e2b791c17036e02ac9b0694", "https://storage.googleapis.com/cockroach-godeps/gomod/gotest.tools/tools_gotest-v2.2.0+incompatible.zip": "55fab831b2660201183b54d742602563d4e17e7125ee75788a309a4f6cb7285e", - "https://storage.googleapis.com/cockroach-godeps/gomod/gotest.tools/v3/tools_gotest_v3-v3.0.3.zip": "9c1e4b8a1477c52441aafc2025a4b4e8bc300a9817c5549c0dc7fffef34bdaef", + "https://storage.googleapis.com/cockroach-godeps/gomod/gotest.tools/v3/tools_gotest_v3-v3.2.0.zip": "fe238394013ebf35c313b7de60c5df5b6271f7c5f982eb8eecefe324531a0f5f", "https://storage.googleapis.com/cockroach-godeps/gomod/honnef.co/go/tools/co_honnef_go_tools-v0.3.2.zip": "9cc6be802987a1ad579e7a1d90bde4c50b9832ce9213eab302bf8916ab3dc2b7", "https://storage.googleapis.com/cockroach-godeps/gomod/k8s.io/api/io_k8s_api-v0.22.1.zip": "f7bdf8655b5078d05124dacb2eeaf2e2dc356334f174b623d3afa9130517e272", "https://storage.googleapis.com/cockroach-godeps/gomod/k8s.io/apiextensions-apiserver/io_k8s_apiextensions_apiserver-v0.17.3.zip": "f3be44b21eaea21dbc2655f207f838a94e4ed63b24e5ce4f1d688c329b53c9ff", diff --git a/go.mod b/go.mod index 5da30337a5da..90fb356bc227 100644 --- a/go.mod +++ b/go.mod @@ -58,7 +58,7 @@ require ( github.com/coreos/go-oidc v2.2.1+incompatible github.com/dave/dst v0.24.0 github.com/docker/distribution v2.7.1+incompatible - github.com/docker/docker v20.10.8+incompatible + github.com/docker/docker v20.10.17+incompatible github.com/docker/go-connections v0.4.0 github.com/dustin/go-humanize v1.0.0 github.com/edsrzf/mmap-go v1.0.0 @@ -139,8 +139,8 @@ require ( github.com/spf13/afero v1.6.0 github.com/spf13/cobra v1.2.1 github.com/spf13/pflag v1.0.5 - github.com/stretchr/testify v1.7.0 - github.com/twpayne/go-geom v1.4.1 + github.com/stretchr/testify v1.8.0 + github.com/twpayne/go-geom v1.4.2 github.com/wadey/gocovmerge v0.0.0-20160331181800-b5bfa59ec0ad github.com/xdg-go/pbkdf2 v1.0.0 github.com/xdg-go/scram v1.0.2 @@ -156,11 +156,11 @@ require ( golang.org/x/crypto v0.0.0-20220518034528-6f7dac969898 golang.org/x/exp v0.0.0-20220104160115-025e73f80486 golang.org/x/lint v0.0.0-20210508222113-6edffad5e616 - golang.org/x/net v0.0.0-20220524220425-1d687d428aca + golang.org/x/net v0.0.0-20220722155237-a158d28d115b golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5 golang.org/x/perf v0.0.0-20180704124530-6e6d33e29852 golang.org/x/sync v0.0.0-20220513210516-0976fa681c29 - golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a + golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 golang.org/x/text v0.3.7 golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac @@ -170,7 +170,7 @@ require ( google.golang.org/grpc v1.46.0 google.golang.org/protobuf v1.28.0 gopkg.in/yaml.v2 v2.4.0 - gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b + gopkg.in/yaml.v3 v3.0.1 honnef.co/go/tools v0.3.2 vitess.io/vitess v0.0.0-00010101000000-000000000000 ) @@ -191,7 +191,7 @@ require ( github.com/Masterminds/goutils v1.1.0 // indirect github.com/Masterminds/semver v1.5.0 // indirect github.com/Masterminds/sprig v2.22.0+incompatible // indirect - github.com/Microsoft/go-winio v0.5.1 // indirect + github.com/Microsoft/go-winio v0.5.2 // indirect github.com/PuerkitoBio/purell v1.1.1 // indirect github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 // indirect github.com/abbot/go-http-auth v0.4.1-0.20181019201920-860ed7f246ff // indirect @@ -209,7 +209,7 @@ require ( github.com/aws/smithy-go v1.11.2 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect - github.com/cenkalti/backoff/v4 v4.1.2 // indirect + github.com/cenkalti/backoff/v4 v4.1.3 // indirect github.com/cespare/xxhash/v2 v2.1.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/dimchansky/utfbom v1.1.1 // indirect @@ -252,7 +252,7 @@ require ( github.com/hashicorp/hcl v1.0.0 // indirect github.com/huandu/xstrings v1.3.0 // indirect github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639 // indirect - github.com/imdario/mergo v0.3.12 // indirect + github.com/imdario/mergo v0.3.13 // indirect github.com/inconshreveable/mousetrap v1.0.0 // indirect github.com/jackc/chunkreader/v2 v2.0.1 // indirect github.com/jackc/pgio v1.0.0 // indirect @@ -284,8 +284,8 @@ require ( github.com/minio/sha256-simd v1.0.0 // indirect github.com/mitchellh/copystructure v1.0.0 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect - github.com/mitchellh/mapstructure v1.4.1 // indirect - github.com/moby/term v0.0.0-20201216013528-df9cb8a40635 // indirect + github.com/mitchellh/mapstructure v1.5.0 // indirect + github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect github.com/morikuni/aec v1.0.0 // indirect @@ -307,7 +307,7 @@ require ( github.com/rs/xid v1.3.0 // indirect github.com/russross/blackfriday v1.6.0 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect - github.com/sirupsen/logrus v1.8.1 // indirect + github.com/sirupsen/logrus v1.9.0 // indirect github.com/slok/go-http-metrics v0.10.0 // indirect github.com/spf13/cast v1.3.1 // indirect github.com/spf13/jwalterweatherman v1.1.0 // indirect diff --git a/go.sum b/go.sum index 735c2f7de033..395678b9392d 100644 --- a/go.sum +++ b/go.sum @@ -162,10 +162,10 @@ github.com/CloudyKit/jet v2.1.3-0.20180809161101-62edd43e4f88+incompatible/go.mo github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= github.com/Codefor/geohash v0.0.0-20140723084247-1b41c28e3a9d h1:iG9B49Q218F/XxXNRM7k/vWf7MKmLIS8AcJV9cGN4nA= github.com/Codefor/geohash v0.0.0-20140723084247-1b41c28e3a9d/go.mod h1:RVnhzAX71far8Kc3TQeA0k/dcaEKUnTDSOyet/JCmGI= -github.com/DATA-DOG/go-sqlmock v1.3.2/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= github.com/DATA-DOG/go-sqlmock v1.3.3/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= -github.com/DATA-DOG/go-sqlmock v1.4.1 h1:ThlnYciV1iM/V0OSF/dtkqWb6xo5qITT1TJBG1MRDJM= github.com/DATA-DOG/go-sqlmock v1.4.1/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= +github.com/DATA-DOG/go-sqlmock v1.5.0 h1:Shsta01QNfFxHCfpW6YH2STWB0MudeXXEWMr20OEh60= +github.com/DATA-DOG/go-sqlmock v1.5.0/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= github.com/DataDog/datadog-go v2.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/DataDog/zstd v1.3.6-0.20190409195224-796139022798/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= @@ -205,8 +205,9 @@ github.com/Microsoft/go-winio v0.4.16/go.mod h1:XB6nPKklQyQ7GC9LdcBEcBl8PF76WugX github.com/Microsoft/go-winio v0.4.17-0.20210211115548-6eac466e5fa3/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84= github.com/Microsoft/go-winio v0.4.17-0.20210324224401-5516f17a5958/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84= github.com/Microsoft/go-winio v0.4.17/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84= -github.com/Microsoft/go-winio v0.5.1 h1:aPJp2QD7OOrhO5tQXqQoGSJc+DjDtWTGLOmNyAm6FgY= github.com/Microsoft/go-winio v0.5.1/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84= +github.com/Microsoft/go-winio v0.5.2 h1:a9IhgEQBCUEk6QCdml9CiJGhAws+YwffDHEMp1VMrpA= +github.com/Microsoft/go-winio v0.5.2/go.mod h1:WpS1mjBmmwHBEWmogvA2mj8546UReBk4v8QkMxJ6pZY= github.com/Microsoft/hcsshim v0.8.6/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg= github.com/Microsoft/hcsshim v0.8.7-0.20190325164909-8abdbb8205e4/go.mod h1:Op3hHsoHPAvb6lceZHDtd9OkTew38wNoXnJs8iY7rUg= github.com/Microsoft/hcsshim v0.8.7/go.mod h1:OHd7sQqRFrYd3RmSgbgji+ctCwkbq2wbEYNSzOYtcBQ= @@ -396,10 +397,10 @@ github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n github.com/cenkalti/backoff v0.0.0-20181003080854-62661b46c409/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= -github.com/cenkalti/backoff/v3 v3.0.0/go.mod h1:cIeZDE3IrqwwJl6VUwCN6trj1oXrTS4rc0ij+ULvLYs= github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= -github.com/cenkalti/backoff/v4 v4.1.2 h1:6Yo7N8UP2K6LWZnW94DLVSSrbobcWdVzAYOisuDPIFo= github.com/cenkalti/backoff/v4 v4.1.2/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= +github.com/cenkalti/backoff/v4 v4.1.3 h1:cFAlzYUlVYDysBEH2T5hyJZMh3+5+WCBvSnK6Q8UtC4= +github.com/cenkalti/backoff/v4 v4.1.3/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/certifi/gocertifi v0.0.0-20191021191039-0944d244cd40/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= github.com/certifi/gocertifi v0.0.0-20200922220541-2c3bb06c6054/go.mod h1:sGbDF6GwGcLpkNXPUTkMRoywsNa/ol15pxFe6ERfguA= @@ -411,6 +412,7 @@ github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cb github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/checkpoint-restore/go-criu/v4 v4.1.0/go.mod h1:xUQBLp4RLc5zJtWY++yjOoMoB5lihDt7fai+75m+rGw= github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M= +github.com/checkpoint-restore/go-criu/v5 v5.3.0/go.mod h1:E/eQpaFtUKGOOSEBZgmKAcn+zUUwWxqcaKZlF54wK8E= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= @@ -419,6 +421,7 @@ github.com/cilium/ebpf v0.0.0-20200702112145-1c8d4c9ef775/go.mod h1:7cR51M8ViRLI github.com/cilium/ebpf v0.2.0/go.mod h1:To2CFviqOWL/M0gIMsvSMlqe7em/l1ALkX1PyjrX2Qs= github.com/cilium/ebpf v0.4.0/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs= github.com/cilium/ebpf v0.6.2/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs= +github.com/cilium/ebpf v0.7.0/go.mod h1:/oI2+1shJiTGAMgl6/RgJr36Eo1jzrRcAWbcXO2usCA= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= @@ -513,6 +516,7 @@ github.com/containerd/console v0.0.0-20181022165439-0650fd9eeb50/go.mod h1:Tj/on github.com/containerd/console v0.0.0-20191206165004-02ecf6a7291e/go.mod h1:8Pf4gM6VEbTNRIT26AyyU7hxdQU3MvAvxVI0sc00XBE= github.com/containerd/console v1.0.1/go.mod h1:XUsP6YE/mKtz6bxc+I8UiKKTP04qjQL4qcS3XoQ5xkw= github.com/containerd/console v1.0.2/go.mod h1:ytZPjGgY2oeTkAONYafi2kSj0aYggsf8acV1PGKCbzQ= +github.com/containerd/console v1.0.3/go.mod h1:7LqA/THxQ86k76b8c/EMSiaJ3h1eZkMkXar0TQ1gf3U= github.com/containerd/containerd v1.2.10/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA= github.com/containerd/containerd v1.3.0-beta.2.0.20190828155532-0293cbd26c69/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA= github.com/containerd/containerd v1.3.0/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA= @@ -537,6 +541,7 @@ github.com/containerd/continuity v0.0.0-20201208142359-180525291bb7/go.mod h1:kR github.com/containerd/continuity v0.0.0-20210208174643-50096c924a4e/go.mod h1:EXlVlkqNba9rJe3j7w3Xa924itAMLgZH4UD/Q4PExuQ= github.com/containerd/continuity v0.1.0/go.mod h1:ICJu0PwR54nI0yPEnJ6jcS+J7CZAUXrLh8lPo2knzsM= github.com/containerd/continuity v0.2.2/go.mod h1:pWygW9u7LtS1o4N/Tn0FoCFDIXZ7rxcMX7HX1Dmibvk= +github.com/containerd/continuity v0.3.0/go.mod h1:wJEAIwKOm/pBZuBd0JmeTvnLquTB1Ag8espWhkykbPM= github.com/containerd/fifo v0.0.0-20180307165137-3d5202aec260/go.mod h1:ODA38xgv3Kuk8dQz2ZQXpnv/UZZUHUCL7pnLehbXgQI= github.com/containerd/fifo v0.0.0-20190226154929-a9fb20d87448/go.mod h1:ODA38xgv3Kuk8dQz2ZQXpnv/UZZUHUCL7pnLehbXgQI= github.com/containerd/fifo v0.0.0-20200410184934-f15a3290365b/go.mod h1:jPQ2IAeZRCYxpS/Cm1495vGFww6ecHmMk1YJH2Q5ln0= @@ -615,6 +620,7 @@ github.com/crossdock/crossdock-go v0.0.0-20160816171116-049aabb0122b/go.mod h1:v github.com/cyberdelia/go-metrics-graphite v0.0.0-20161219230853-39f87cc3b432/go.mod h1:xwIwAxMvYnVrGJPe2FKx5prTrnAjGOD8zvDOnxnrrkM= github.com/cyberdelia/templates v0.0.0-20141128023046-ca7fffd4298c/go.mod h1:GyV+0YP4qX0UQ7r2MoYZ+AvYDp12OF5yg4q8rGnyNh4= github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= +github.com/cyphar/filepath-securejoin v0.2.3/go.mod h1:aPGpWjXOXUn2NCNjFvBE6aRxGGx79pTxQpKOJNYHHl4= github.com/d2g/dhcp4 v0.0.0-20170904100407-a1d1b6c41b1c/go.mod h1:Ct2BUK8SB0YC1SMSibvLzxjeJLnrYEVLULFNiHY9YfQ= github.com/d2g/dhcp4client v1.0.0/go.mod h1:j0hNfjhrt2SxUOw55nL0ATM/z4Yt3t2Kd1mW34z5W5s= github.com/d2g/dhcp4server v0.0.0-20181031114812-7d4a0a7f59a5/go.mod h1:Eo87+Kg/IX2hfWJfwxMzLyuSZyxSoAug2nGa1G2QAi8= @@ -660,6 +666,8 @@ github.com/djherbis/atime v1.1.0/go.mod h1:28OF6Y8s3NQWwacXc5eZTsEsiMzp7LF8MbXE+ github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E= github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= github.com/docker/cli v20.10.11+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= +github.com/docker/cli v20.10.14+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= +github.com/docker/cli v20.10.17+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v0.0.0-20190905152932-14b96e55d84c/go.mod h1:0+TTO4EOBfRPhZXAeF1Vu+W3hHZ8eLp8PgKVZlcvtFY= github.com/docker/distribution v2.7.1-0.20190205005809-0d3efadf0154+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docker/distribution v2.7.1+incompatible h1:a5mlkVzth6W5A4fOsS3D2EO5BUmsJpcB+cRlLU7cSug= @@ -968,6 +976,7 @@ github.com/godbus/dbus v0.0.0-20180201030542-885f9cc04c9c/go.mod h1:/YcGZj5zSblf github.com/godbus/dbus v0.0.0-20190422162347-ade71ed3457e/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= +github.com/godbus/dbus/v5 v5.0.6/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= @@ -1271,8 +1280,9 @@ github.com/imdario/mergo v0.3.8/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJ github.com/imdario/mergo v0.3.9/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= github.com/imdario/mergo v0.3.10/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= -github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= +github.com/imdario/mergo v0.3.13 h1:lFzP57bqS/wsqKssCGmtLAb8A0wKjLGrve2q3PPVcBk= +github.com/imdario/mergo v0.3.13/go.mod h1:4lJ1jqUDcsbIECGy0RUJAXNIhg+6ocWgb1ALK2O4oXg= github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= @@ -1523,7 +1533,6 @@ github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.1.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.3.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.8.0/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.0/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.2/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.4/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= @@ -1658,8 +1667,9 @@ github.com/mitchellh/mapstructure v1.2.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RR github.com/mitchellh/mapstructure v1.3.2/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.4.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/mapstructure v1.4.1 h1:CpVNEelQCZBooIPDn+AR3NpivK/TIKU8bDxdASFVQag= github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= +github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/osext v0.0.0-20151018003038-5e2d6d41470f/go.mod h1:OkQIRizQZAeMln+1tSwduZz7+Af5oFlKirV/MSYes2A= github.com/mitchellh/reflectwalk v1.0.0 h1:9D+8oIskB4VJBN5SFlmc27fSlIBZaov1Wpk/IfikLNY= github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= @@ -1674,10 +1684,12 @@ github.com/moby/moby v20.10.6+incompatible/go.mod h1:fDXVQ6+S340veQPv35CzDahGBmH github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= github.com/moby/sys/mountinfo v0.4.0/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A= github.com/moby/sys/mountinfo v0.4.1/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A= +github.com/moby/sys/mountinfo v0.5.0/go.mod h1:3bMD3Rg+zkqx8MRYPi7Pyb0Ie97QEBmdxbhnCLlSvSU= github.com/moby/sys/symlink v0.1.0/go.mod h1:GGDODQmbFOjFsXvfLVn3+ZRxkch54RkSiGqsZeMYowQ= github.com/moby/term v0.0.0-20200312100748-672ec06f55cd/go.mod h1:DdlQx2hp0Ss5/fLikoLlEeIYiATotOjgB//nb973jeo= -github.com/moby/term v0.0.0-20201216013528-df9cb8a40635 h1:rzf0wL0CHVc8CEsgyygG0Mn9CNCCPZqOPaz8RiiHYQk= github.com/moby/term v0.0.0-20201216013528-df9cb8a40635/go.mod h1:FBS0z0QWA44HXygs7VXDUOGoN/1TV3RuWkLO04am3wc= +github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6 h1:dcztxKSvZ4Id8iPpHERQBbIJfabdt4wUm5qy3wOL2Zc= +github.com/moby/term v0.0.0-20210619224110-3f7ff695adc6/go.mod h1:E2VnQOmVuvZB6UYnnDB0qG5Nq/1tD9acaOpo6xmt0Kw= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -1767,6 +1779,8 @@ github.com/opencontainers/runc v1.0.0-rc8.0.20190926000215-3e425f80a8c9/go.mod h github.com/opencontainers/runc v1.0.0-rc9/go.mod h1:qT5XzbpPznkRYVz/mWwUaVBUv2rmF59PVA73FjuZG0U= github.com/opencontainers/runc v1.0.0-rc93/go.mod h1:3NOsor4w32B2tC0Zbl8Knk4Wg84SM2ImC1fxBuqJ/H0= github.com/opencontainers/runc v1.0.2/go.mod h1:aTaHFFwQXuA71CiyxOdFFIorAoemI04suvGRQFzWTD0= +github.com/opencontainers/runc v1.1.2/go.mod h1:Tj1hFw6eFWp/o33uxGf5yF2BX5yz2Z6iptFpuvbbKqc= +github.com/opencontainers/runc v1.1.3/go.mod h1:1J5XiS+vdZ3wCyZybsuxXZWGrgSr8fFJHLXuG2PsnNg= github.com/opencontainers/runtime-spec v0.1.2-0.20190507144316-5b71a03e2700/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= github.com/opencontainers/runtime-spec v1.0.1/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= github.com/opencontainers/runtime-spec v1.0.2-0.20190207185410-29686dbc5559/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= @@ -1777,6 +1791,7 @@ github.com/opencontainers/runtime-tools v0.0.0-20181011054405-1d69bd0f9c39/go.mo github.com/opencontainers/selinux v1.6.0/go.mod h1:VVGKuOLlE7v4PJyT6h7mNWvq1rzqiriPsEqVhc+svHE= github.com/opencontainers/selinux v1.8.0/go.mod h1:RScLhm78qiWa2gbVCcGkC7tCGdgk3ogry1nUQF8Evvo= github.com/opencontainers/selinux v1.8.2/go.mod h1:MUIHuUEvKB1wtJjQdOyYRgOnLD2xAPP8dBsCoU0KuF8= +github.com/opencontainers/selinux v1.10.0/go.mod h1:2i0OySw99QjzBBQByd1Gr9gSjvuho1lHsJxIJ3gGbJI= github.com/opennota/wd v0.0.0-20180911144301-b446539ab1e7 h1:cVQhwfBgiKTMAdYPbVeuIiTkdY59qZ3sp5RpyO8CNtg= github.com/opennota/wd v0.0.0-20180911144301-b446539ab1e7/go.mod h1:CS6cd3lWylVJV6EWs4Q/lkDEVGQOrEbBdwCowzzkN6A= github.com/opentracing-contrib/go-grpc v0.0.0-20180928155321-4b5a12d3ff02/go.mod h1:JNdpVEzCpXBgIiv4ds+TzhN1hrtxq6ClLrTlT9OQRSc= @@ -1794,8 +1809,8 @@ github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnh github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/openzipkin/zipkin-go v0.2.5 h1:UwtQQx2pyPIgWYHRg+epgdx1/HnBQTgN3/oIYEJTQzU= github.com/openzipkin/zipkin-go v0.2.5/go.mod h1:KpXfKdgRDnnhsxw4pNIH9Md5lyFqKUa4YDFlwRYAMyE= -github.com/ory/dockertest/v3 v3.6.0/go.mod h1:4ZOpj8qBUmh8fcBSVzkH2bws2s91JdGvHUqan4GHEuQ= github.com/ory/dockertest/v3 v3.8.1/go.mod h1:wSRQ3wmkz+uSARYMk7kVJFDBGm8x5gSxIhI7NDc+BAQ= +github.com/ory/dockertest/v3 v3.9.1/go.mod h1:42Ir9hmvaAPm0Mgibk6mBPi7SFvTXxEcnztDYOJ//uM= github.com/otan-cockroach/go-libedit v1.10.2-0.20201030151939-7cced08450e7 h1:+sIdymRXD4aKCvmVMBLL7/bO95KZFYrbz0EzQ1Jlj4A= github.com/otan-cockroach/go-libedit v1.10.2-0.20201030151939-7cced08450e7/go.mod h1:X8+oa2glxe4aJyviH7x8FG5AoSdqZ0VJYOxt83gh6m8= github.com/otan/gopgkrb5 v1.0.3 h1:iDZlYPC8mxvKvpIvDu66j48Q4WqW15HuWUX+MIwjF0U= @@ -1991,6 +2006,8 @@ github.com/sclevine/agouti v3.0.0+incompatible/go.mod h1:b4WX9W9L1sfQKXeJf1mUTLZ github.com/scylladb/termtables v0.0.0-20191203121021-c4c0b6d42ff4/go.mod h1:C1a7PQSMz9NShzorzCiG2fk9+xuCgLkPeCvMHYR2OWg= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo= +github.com/seccomp/libseccomp-golang v0.9.2-0.20210429002308-3879420cc921/go.mod h1:JA8cRccbGaA1s33RQf7Y1+q9gHmZX1yB/z9WDN1C6fg= +github.com/seccomp/libseccomp-golang v0.9.2-0.20220502022130-f33da4d89646/go.mod h1:JA8cRccbGaA1s33RQf7Y1+q9gHmZX1yB/z9WDN1C6fg= github.com/sectioneight/md-to-godoc v0.0.0-20161108233149-55e43be6c335/go.mod h1:lPZq22klO8la1kyImIDhrGytugMV0TsrsZB55a+xxI0= github.com/securego/gosec v0.0.0-20200203094520-d13bb6d2420c/go.mod h1:gp0gaHj0WlmPh9BdsTmo1aq6C27yIPWdxCKGFGdVKBE= github.com/segmentio/kafka-go v0.1.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo= @@ -2016,8 +2033,9 @@ github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMB github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE= github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= +github.com/sirupsen/logrus v1.9.0 h1:trlNQbNUG3OdDrDil03MCb1H2o9nJ1x4/5LYw7byDE0= +github.com/sirupsen/logrus v1.9.0/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/sjmudd/stopwatch v0.0.0-20170613150411-f380bf8a9be1/go.mod h1:Pgf1sZ2KrHK8vdRTV5UHGp80LT7HMUKuNAiKC402abY= github.com/slack-go/slack v0.9.5 h1:j7uOUDowybWf9eSgZg/AbGx6J1OPJB6SE8Z5dNl6Mtw= github.com/slack-go/slack v0.9.5/go.mod h1:wWL//kk0ho+FcQXcBTmEafUI5dz4qz5f4mMk8oIkioQ= @@ -2074,8 +2092,9 @@ github.com/streadway/quantile v0.0.0-20150917103942-b0c588724d25/go.mod h1:lbP8t github.com/stretchr/objx v0.0.0-20180129172003-8a3f7159479f/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.2.0 h1:Hbg2NidpLE8veEBkEZTL3CvlkUIVzuU9jDplZO54c48= github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= +github.com/stretchr/objx v0.4.0 h1:M2gUjqZET1qApGOWNSnZ49BAIMX4F/1plDv3+l31EJ4= +github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/testify v0.0.0-20151208002404-e3a8ff8ce365/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v0.0.0-20170130113145-4d4bfba8f1d1/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v0.0.0-20180303142811-b89eecf5ca5d/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= @@ -2087,8 +2106,10 @@ github.com/stretchr/testify v1.5.0/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5 github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.6.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk= +github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/syndtr/gocapability v0.0.0-20170704070218-db04d3cc01c8/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww= @@ -2118,8 +2139,8 @@ github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqri github.com/tv42/httpunix v0.0.0-20191220191345-2ba4b9c3382c/go.mod h1:hzIxponao9Kjc7aWznkXaL4U4TWaDSs8zcsY4Ka08nM= github.com/twitchtv/twirp v8.1.0+incompatible h1:KGXanpa9LXdVE/V5P/tA27rkKFmXRGCtSNT7zdeeVOY= github.com/twitchtv/twirp v8.1.0+incompatible/go.mod h1:RRJoFSAmTEh2weEqWtpPE3vFK5YBhA6bqp2l1kfCC5A= -github.com/twpayne/go-geom v1.4.1 h1:LeivFqaGBRfyg0XJJ9pkudcptwhSSrYN9KZUW6HcgdA= -github.com/twpayne/go-geom v1.4.1/go.mod h1:k/zktXdL+qnA6OgKsdEGUTA17jbQ2ZPTUa3CCySuGpE= +github.com/twpayne/go-geom v1.4.2 h1:I2MtC83UDniuTVzGWZOyhMn9hDPrjLm0jsUbohimtZQ= +github.com/twpayne/go-geom v1.4.2/go.mod h1:zrqClsxeaIieScWGuas1Cm/5Nr/9i1xk9+0t+2ec9g8= github.com/twpayne/go-kml v1.5.2 h1:rFMw2/EwgkVssGS2MT6YfWSPZz6BgcJkLxQ53jnE8rQ= github.com/twpayne/go-kml v1.5.2/go.mod h1:kz8jAiIz6FIdU2Zjce9qGlVtgFYES9vt7BTPBHf5jl4= github.com/twpayne/go-polyline v1.0.0/go.mod h1:ICh24bcLYBX8CknfvNPKqoTbe+eg+MX1NPyJmSBo7pU= @@ -2183,6 +2204,7 @@ github.com/xdg/stringprep v0.0.0-20180714160509-73f8eece6fdc/go.mod h1:Jhud4/sHM github.com/xdg/stringprep v1.0.0/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y= github.com/xdg/stringprep v1.0.3/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= +github.com/xeipuuv/gojsonpointer v0.0.0-20190905194746-02993c407bfb/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= github.com/xeipuuv/gojsonschema v0.0.0-20180618132009-1d523034197f/go.mod h1:5yf86TLmAcydyeJq5YvxkGPE2fm/u4myDekKRoLuqhs= github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= @@ -2444,7 +2466,6 @@ golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191002035440-2ec189313ef0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20191003171128-d98b1b443823/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191004110552-13f9640d40b9/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191112182307-2180aed22343/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191126235420-ef20fe5d7933/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -2496,8 +2517,8 @@ golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220524220425-1d687d428aca h1:xTaFYiPROfpPhqrfTIDXj0ri1SpfueYT951s4bAuDO8= -golang.org/x/net v0.0.0-20220524220425-1d687d428aca/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b h1:PxfKdU9lEEDYjdIzOtC4qFWgkU2rGHdKlKowJSMN9h0= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -2596,7 +2617,6 @@ golang.org/x/sys v0.0.0-20200107162124-548cf772de50/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200120151820-655fe14d7479/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200121082415-34d275377bf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200124204421-9fbb57f87de9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -2672,6 +2692,8 @@ golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211013075003-97ac67df715c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211116061358-0a5406a5449c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -2680,12 +2702,15 @@ golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220405210540-1e041c57c461/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220408201424-a24fb2fb8a0f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220502124256-b6088ccd6cba/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a h1:dGzPydgVsqGcTRVwiLJ1jVbufYwmzD3LfVPLKsKg+0k= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f h1:v4INt8xihDGvnrfjMDVXGxw9wrfxYyCjk0KbXjhR55s= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210220032956-6a3ed077a48d/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= @@ -3103,16 +3128,19 @@ gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200605160147-a5ece683394c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gorm.io/driver/postgres v1.0.8/go.mod h1:4eOzrI1MUfm6ObJU/UcmbXyiHSs8jSwH95G5P5dxcAg= gorm.io/gorm v1.20.12/go.mod h1:0HFTzE/SqkGTzK6TlDPPQbAYCluiVvhzoA1+aVyzenw= gorm.io/gorm v1.21.4/go.mod h1:0HFTzE/SqkGTzK6TlDPPQbAYCluiVvhzoA1+aVyzenw= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= -gotest.tools/v3 v3.0.3 h1:4AuOwCGf4lLR9u3YOe2awrHygurzhO/HeQ6laiA6Sx0= gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= +gotest.tools/v3 v3.2.0 h1:I0DwBVMGAx26dttAj1BtJLAkVGncrkkUXfJLC4Flt/I= +gotest.tools/v3 v3.2.0/go.mod h1:Mcr9QNxkg0uMvy/YElmo4SpXgJKWgQvYrT7Kw5RzJ1A= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/vendor b/vendor index a1ce3f5a68d2..f75c86555397 160000 --- a/vendor +++ b/vendor @@ -1 +1 @@ -Subproject commit a1ce3f5a68d24722aa6eb559be181e8095445892 +Subproject commit f75c86555397b3b01da5d61e962bd46bbdb4cd47 From 497cd51bdb0b6648c0aabb8b22083c55d05d5333 Mon Sep 17 00:00:00 2001 From: Tobias Grieger Date: Wed, 17 Aug 2022 11:52:49 +0200 Subject: [PATCH 2/9] roachtest: own jepsen tests to test-eng See #82060. Release justification: testing-only change Release note: None --- pkg/cmd/roachtest/tests/jepsen.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pkg/cmd/roachtest/tests/jepsen.go b/pkg/cmd/roachtest/tests/jepsen.go index 9d533256d98a..e3c4f3b5a203 100644 --- a/pkg/cmd/roachtest/tests/jepsen.go +++ b/pkg/cmd/roachtest/tests/jepsen.go @@ -348,9 +348,8 @@ func RegisterJepsen(r registry.Registry) { for _, nemesis := range jepsenNemeses { nemesis := nemesis // copy for closure s := registry.TestSpec{ - Name: fmt.Sprintf("jepsen/%s/%s", testName, nemesis.name), - // We don't run jepsen on older releases due to the high rate of flakes. - Owner: registry.OwnerKV, + Name: fmt.Sprintf("jepsen/%s/%s", testName, nemesis.name), + Owner: registry.OwnerTestEng, // The Jepsen tests do funky things to machines, like muck with the // system clock; therefore, their clusters cannot be reused other tests // except the Jepsen ones themselves which reset all this state when From b1811c9f575d22d4cdf77db51570036a15e38940 Mon Sep 17 00:00:00 2001 From: Tobias Grieger Date: Wed, 17 Aug 2022 11:54:21 +0200 Subject: [PATCH 3/9] roachtest: own version/mixed/* tests to test-eng Closes #82060. Release justification: test-only change Release note: None --- pkg/cmd/roachtest/tests/version.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/cmd/roachtest/tests/version.go b/pkg/cmd/roachtest/tests/version.go index 174a61cc7d0e..5fa1cca59d3c 100644 --- a/pkg/cmd/roachtest/tests/version.go +++ b/pkg/cmd/roachtest/tests/version.go @@ -217,7 +217,7 @@ func registerVersion(r registry.Registry) { for _, n := range []int{3, 5} { r.Add(registry.TestSpec{ Name: fmt.Sprintf("version/mixed/nodes=%d", n), - Owner: registry.OwnerKV, + Owner: registry.OwnerTestEng, Cluster: r.MakeClusterSpec(n + 1), Run: func(ctx context.Context, t test.Test, c cluster.Cluster) { pred, err := PredecessorVersion(*t.BuildVersion()) From 6d6c4e62e9573581e35ce9c9edee7a84a7460ce2 Mon Sep 17 00:00:00 2001 From: Tobias Grieger Date: Wed, 17 Aug 2022 11:57:17 +0200 Subject: [PATCH 4/9] roachtest: own smoketest/secure to test-eng Release justification: testing Release note: None --- pkg/cmd/roachtest/tests/smoketest_secure.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/cmd/roachtest/tests/smoketest_secure.go b/pkg/cmd/roachtest/tests/smoketest_secure.go index a0d7465947fc..7ee99b40e4d5 100644 --- a/pkg/cmd/roachtest/tests/smoketest_secure.go +++ b/pkg/cmd/roachtest/tests/smoketest_secure.go @@ -29,7 +29,7 @@ func registerSecure(r registry.Registry) { r.Add(registry.TestSpec{ Name: fmt.Sprintf("smoketest/secure/nodes=%d", numNodes), Tags: []string{"smoketest", "weekly"}, - Owner: registry.OwnerKV, // TODO: OwnerTestEng once the open PR that introduces it has merged + Owner: registry.OwnerTestEng, Cluster: r.MakeClusterSpec(numNodes), Run: func(ctx context.Context, t test.Test, c cluster.Cluster) { c.Put(ctx, t.Cockroach(), "./cockroach") From 2b7c666010f2d8b83973ddeb928ca242d9441ed8 Mon Sep 17 00:00:00 2001 From: Marius Posta Date: Wed, 17 Aug 2022 11:30:36 -0400 Subject: [PATCH 5/9] scplan: make EXPLAIN target output stable This commit does not make any functional changes. It merely ensures that the diagrams generated by an EXPLAIN (DDL) statement list the schema change targets in a predefined order: first the to-public targets, then the transient targets, and finally the to-absent targets. This helps readability and makes the declarative schema changer data-driven test output more stable. Release justification: low-impact, test-only change Release note: None --- pkg/sql/schemachanger/scplan/plan_explain.go | 9 +- .../schemachanger/testdata/explain/add_column | 12 +- .../testdata/explain/add_column_default_seq | 12 +- .../alter_table_add_primary_key_drop_rowid | 30 ++-- ...d_primary_key_drop_rowid.rollback_10_of_15 | 10 +- ...d_primary_key_drop_rowid.rollback_11_of_15 | 10 +- ...d_primary_key_drop_rowid.rollback_12_of_15 | 10 +- ...d_primary_key_drop_rowid.rollback_13_of_15 | 10 +- ...d_primary_key_drop_rowid.rollback_14_of_15 | 10 +- ...d_primary_key_drop_rowid.rollback_15_of_15 | 10 +- ...dd_primary_key_drop_rowid.rollback_1_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_2_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_3_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_4_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_5_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_6_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_7_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_8_of_15 | 6 +- ...dd_primary_key_drop_rowid.rollback_9_of_15 | 10 +- .../alter_table_alter_primary_key_drop_rowid | 30 ++-- ...r_primary_key_drop_rowid.rollback_10_of_15 | 10 +- ...r_primary_key_drop_rowid.rollback_11_of_15 | 10 +- ...r_primary_key_drop_rowid.rollback_12_of_15 | 10 +- ...r_primary_key_drop_rowid.rollback_13_of_15 | 10 +- ...r_primary_key_drop_rowid.rollback_14_of_15 | 10 +- ...r_primary_key_drop_rowid.rollback_15_of_15 | 10 +- ...er_primary_key_drop_rowid.rollback_1_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_2_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_3_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_4_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_5_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_6_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_7_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_8_of_15 | 6 +- ...er_primary_key_drop_rowid.rollback_9_of_15 | 10 +- .../alter_table_alter_primary_key_vanilla | 14 +- .../testdata/explain/drop_column_basic | 22 +-- .../explain/drop_column_basic.rollback_1_of_7 | 6 +- .../explain/drop_column_basic.rollback_2_of_7 | 6 +- .../explain/drop_column_basic.rollback_3_of_7 | 6 +- .../explain/drop_column_basic.rollback_4_of_7 | 6 +- .../explain/drop_column_basic.rollback_5_of_7 | 6 +- .../explain/drop_column_basic.rollback_6_of_7 | 6 +- .../explain/drop_column_basic.rollback_7_of_7 | 6 +- .../explain/drop_column_computed_index | 28 +-- ...drop_column_computed_index.rollback_1_of_7 | 10 +- ...drop_column_computed_index.rollback_2_of_7 | 10 +- ...drop_column_computed_index.rollback_3_of_7 | 10 +- ...drop_column_computed_index.rollback_4_of_7 | 10 +- ...drop_column_computed_index.rollback_5_of_7 | 10 +- ...drop_column_computed_index.rollback_6_of_7 | 10 +- ...drop_column_computed_index.rollback_7_of_7 | 10 +- ...ndex_separate_statements.rollback_10_of_15 | 18 +- ...ndex_separate_statements.rollback_11_of_15 | 18 +- ...ndex_separate_statements.rollback_12_of_15 | 18 +- ...ndex_separate_statements.rollback_13_of_15 | 18 +- ...ndex_separate_statements.rollback_14_of_15 | 18 +- ...ndex_separate_statements.rollback_15_of_15 | 18 +- ...index_separate_statements.rollback_1_of_15 | 14 +- ...index_separate_statements.rollback_2_of_15 | 14 +- ...index_separate_statements.rollback_3_of_15 | 14 +- ...index_separate_statements.rollback_4_of_15 | 14 +- ...index_separate_statements.rollback_5_of_15 | 14 +- ...index_separate_statements.rollback_6_of_15 | 14 +- ...index_separate_statements.rollback_7_of_15 | 14 +- ...index_separate_statements.rollback_8_of_15 | 14 +- ...index_separate_statements.rollback_9_of_15 | 18 +- ...index_separate_statements.statement_1_of_2 | 32 ++-- ...index_separate_statements.statement_2_of_2 | 28 +-- .../testdata/explain/drop_column_unique_index | 26 +-- .../drop_column_unique_index.rollback_1_of_7 | 6 +- .../drop_column_unique_index.rollback_2_of_7 | 6 +- .../drop_column_unique_index.rollback_3_of_7 | 6 +- .../drop_column_unique_index.rollback_4_of_7 | 6 +- .../drop_column_unique_index.rollback_5_of_7 | 6 +- .../drop_column_unique_index.rollback_6_of_7 | 6 +- .../drop_column_unique_index.rollback_7_of_7 | 6 +- .../testdata/explain/drop_column_with_index | 26 +-- .../drop_column_with_index.rollback_1_of_7 | 10 +- .../drop_column_with_index.rollback_2_of_7 | 10 +- .../drop_column_with_index.rollback_3_of_7 | 10 +- .../drop_column_with_index.rollback_4_of_7 | 10 +- .../drop_column_with_index.rollback_5_of_7 | 10 +- .../drop_column_with_index.rollback_6_of_7 | 10 +- .../drop_column_with_index.rollback_7_of_7 | 10 +- ...olumns_separate_statements.rollback_1_of_7 | 10 +- ...olumns_separate_statements.rollback_2_of_7 | 10 +- ...olumns_separate_statements.rollback_3_of_7 | 10 +- ...olumns_separate_statements.rollback_4_of_7 | 10 +- ...olumns_separate_statements.rollback_5_of_7 | 10 +- ...olumns_separate_statements.rollback_6_of_7 | 10 +- ...olumns_separate_statements.rollback_7_of_7 | 10 +- ...lumns_separate_statements.statement_1_of_2 | 32 ++-- ...lumns_separate_statements.statement_2_of_2 | 16 +- .../testdata/explain_verbose/add_column | 50 +++--- .../explain_verbose/add_column_default_seq | 50 +++--- .../alter_table_add_primary_key_drop_rowid | 158 ++++++++-------- ...d_primary_key_drop_rowid.rollback_10_of_15 | 78 ++++---- ...d_primary_key_drop_rowid.rollback_11_of_15 | 78 ++++---- ...d_primary_key_drop_rowid.rollback_12_of_15 | 78 ++++---- ...d_primary_key_drop_rowid.rollback_13_of_15 | 78 ++++---- ...d_primary_key_drop_rowid.rollback_14_of_15 | 78 ++++---- ...d_primary_key_drop_rowid.rollback_15_of_15 | 78 ++++---- ...dd_primary_key_drop_rowid.rollback_1_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_2_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_3_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_4_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_5_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_6_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_7_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_8_of_15 | 40 ++--- ...dd_primary_key_drop_rowid.rollback_9_of_15 | 78 ++++---- .../alter_table_alter_primary_key_drop_rowid | 158 ++++++++-------- ...r_primary_key_drop_rowid.rollback_10_of_15 | 78 ++++---- ...r_primary_key_drop_rowid.rollback_11_of_15 | 78 ++++---- ...r_primary_key_drop_rowid.rollback_12_of_15 | 78 ++++---- ...r_primary_key_drop_rowid.rollback_13_of_15 | 78 ++++---- ...r_primary_key_drop_rowid.rollback_14_of_15 | 78 ++++---- ...r_primary_key_drop_rowid.rollback_15_of_15 | 78 ++++---- ...er_primary_key_drop_rowid.rollback_1_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_2_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_3_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_4_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_5_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_6_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_7_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_8_of_15 | 40 ++--- ...er_primary_key_drop_rowid.rollback_9_of_15 | 78 ++++---- .../alter_table_alter_primary_key_vanilla | 68 +++---- .../explain_verbose/drop_column_basic | 96 +++++----- .../drop_column_basic.rollback_1_of_7 | 34 ++-- .../drop_column_basic.rollback_2_of_7 | 34 ++-- .../drop_column_basic.rollback_3_of_7 | 34 ++-- .../drop_column_basic.rollback_4_of_7 | 34 ++-- .../drop_column_basic.rollback_5_of_7 | 34 ++-- .../drop_column_basic.rollback_6_of_7 | 34 ++-- .../drop_column_basic.rollback_7_of_7 | 34 ++-- .../drop_column_computed_index | 124 ++++++------- ...drop_column_computed_index.rollback_1_of_7 | 58 +++--- ...drop_column_computed_index.rollback_2_of_7 | 52 +++--- ...drop_column_computed_index.rollback_3_of_7 | 52 +++--- ...drop_column_computed_index.rollback_4_of_7 | 52 +++--- ...drop_column_computed_index.rollback_5_of_7 | 40 ++--- ...drop_column_computed_index.rollback_6_of_7 | 40 ++--- ...drop_column_computed_index.rollback_7_of_7 | 40 ++--- ...ndex_separate_statements.rollback_10_of_15 | 152 ++++++++-------- ...ndex_separate_statements.rollback_11_of_15 | 152 ++++++++-------- ...ndex_separate_statements.rollback_12_of_15 | 152 ++++++++-------- ...ndex_separate_statements.rollback_13_of_15 | 148 +++++++-------- ...ndex_separate_statements.rollback_14_of_15 | 148 +++++++-------- ...ndex_separate_statements.rollback_15_of_15 | 148 +++++++-------- ...index_separate_statements.rollback_1_of_15 | 94 +++++----- ...index_separate_statements.rollback_2_of_15 | 82 ++++----- ...index_separate_statements.rollback_3_of_15 | 82 ++++----- ...index_separate_statements.rollback_4_of_15 | 82 ++++----- ...index_separate_statements.rollback_5_of_15 | 64 +++---- ...index_separate_statements.rollback_6_of_15 | 64 +++---- ...index_separate_statements.rollback_7_of_15 | 64 +++---- ...index_separate_statements.rollback_8_of_15 | 64 +++---- ...index_separate_statements.rollback_9_of_15 | 152 ++++++++-------- ...index_separate_statements.statement_1_of_2 | 168 +++++++++--------- ...index_separate_statements.statement_2_of_2 | 132 +++++++------- .../explain_verbose/drop_column_unique_index | 132 +++++++------- .../drop_column_unique_index.rollback_1_of_7 | 40 ++--- .../drop_column_unique_index.rollback_2_of_7 | 40 ++--- .../drop_column_unique_index.rollback_3_of_7 | 40 ++--- .../drop_column_unique_index.rollback_4_of_7 | 40 ++--- .../drop_column_unique_index.rollback_5_of_7 | 40 ++--- .../drop_column_unique_index.rollback_6_of_7 | 40 ++--- .../drop_column_unique_index.rollback_7_of_7 | 40 ++--- .../explain_verbose/drop_column_with_index | 124 ++++++------- .../drop_column_with_index.rollback_1_of_7 | 58 +++--- .../drop_column_with_index.rollback_2_of_7 | 52 +++--- .../drop_column_with_index.rollback_3_of_7 | 52 +++--- .../drop_column_with_index.rollback_4_of_7 | 52 +++--- .../drop_column_with_index.rollback_5_of_7 | 40 ++--- .../drop_column_with_index.rollback_6_of_7 | 40 ++--- .../drop_column_with_index.rollback_7_of_7 | 40 ++--- ...olumns_separate_statements.rollback_1_of_7 | 58 +++--- ...olumns_separate_statements.rollback_2_of_7 | 52 +++--- ...olumns_separate_statements.rollback_3_of_7 | 52 +++--- ...olumns_separate_statements.rollback_4_of_7 | 52 +++--- ...olumns_separate_statements.rollback_5_of_7 | 40 ++--- ...olumns_separate_statements.rollback_6_of_7 | 40 ++--- ...olumns_separate_statements.rollback_7_of_7 | 40 ++--- ...lumns_separate_statements.statement_1_of_2 | 168 +++++++++--------- ...lumns_separate_statements.statement_2_of_2 | 86 ++++----- 187 files changed, 3751 insertions(+), 3748 deletions(-) diff --git a/pkg/sql/schemachanger/scplan/plan_explain.go b/pkg/sql/schemachanger/scplan/plan_explain.go index 0deda38e5282..01f6c162fb26 100644 --- a/pkg/sql/schemachanger/scplan/plan_explain.go +++ b/pkg/sql/schemachanger/scplan/plan_explain.go @@ -190,8 +190,11 @@ func (p Plan) explainTargets(s scstage.Stage, sn treeprinter.Node, style treepri // Generate format string for printing element status transition. fmtCompactTransition := fmt.Sprintf("%%-%ds → %%-%ds %%s", beforeMaxLen, afterMaxLen) // Go over each target grouping. - targetTypeMap.ForEach(func(key, numTransitions int) { - ts := scpb.TargetStatus(key) + for _, ts := range []scpb.TargetStatus{scpb.ToPublic, scpb.Transient, scpb.ToAbsent} { + numTransitions := targetTypeMap.GetDefault(int(ts)) + if numTransitions == 0 { + continue + } plural := "s" if numTransitions == 1 { plural = "" @@ -233,7 +236,7 @@ func (p Plan) explainTargets(s scstage.Stage, sn treeprinter.Node, style treepri } } } - }) + } return nil } diff --git a/pkg/sql/schemachanger/testdata/explain/add_column b/pkg/sql/schemachanger/testdata/explain/add_column index 6333498041d6..812fc97f3772 100644 --- a/pkg/sql/schemachanger/testdata/explain/add_column +++ b/pkg/sql/schemachanger/testdata/explain/add_column @@ -87,10 +87,6 @@ Schema change plan for ALTER TABLE ‹db›.‹public›.‹tbl› ADD COLUMN │ └── ValidateUniqueIndex {"IndexID":2,"TableID":106} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase - │ ├── 3 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} - │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} │ ├── 3 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 106, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -99,6 +95,10 @@ Schema change plan for ALTER TABLE ‹db›.‹public›.‹tbl› ADD COLUMN │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 106, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 3} │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 3} + │ ├── 3 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} + │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} │ └── 9 Mutation operations │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":106} │ ├── SetIndexName {"IndexID":1,"Name":"crdb_internal_in...","TableID":106} @@ -110,10 +110,10 @@ Schema change plan for ALTER TABLE ‹db›.‹public›.‹tbl› ADD COLUMN │ ├── SetJobStateOnDescriptor {"DescriptorID":106} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase - │ ├── 1 element transitioning toward ABSENT - │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} │ ├── 1 element transitioning toward TRANSIENT_ABSENT │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 106, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} + │ ├── 1 element transitioning toward ABSENT + │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} │ └── 5 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":106} │ ├── CreateGcJobForIndex {"IndexID":3,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/add_column_default_seq b/pkg/sql/schemachanger/testdata/explain/add_column_default_seq index c142761d30ce..badb937c82c4 100644 --- a/pkg/sql/schemachanger/testdata/explain/add_column_default_seq +++ b/pkg/sql/schemachanger/testdata/explain/add_column_default_seq @@ -93,10 +93,6 @@ Schema change plan for ALTER TABLE ‹db›.‹public›.‹tbl› ADD COLUMN │ └── ValidateUniqueIndex {"IndexID":2,"TableID":106} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase - │ ├── 3 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} - │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} │ ├── 3 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 106, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -105,6 +101,10 @@ Schema change plan for ALTER TABLE ‹db›.‹public›.‹tbl› ADD COLUMN │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 106, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 3} │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 3} + │ ├── 3 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} + │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} │ └── 10 Mutation operations │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":106} │ ├── SetIndexName {"IndexID":1,"Name":"crdb_internal_in...","TableID":106} @@ -117,10 +117,10 @@ Schema change plan for ALTER TABLE ‹db›.‹public›.‹tbl› ADD COLUMN │ ├── SetJobStateOnDescriptor {"DescriptorID":107} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase - │ ├── 1 element transitioning toward ABSENT - │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} │ ├── 1 element transitioning toward TRANSIENT_ABSENT │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 106, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} + │ ├── 1 element transitioning toward ABSENT + │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} │ └── 6 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":106} │ ├── CreateGcJobForIndex {"IndexID":3,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid index 5010dcb6d6b4..e29f32904a6b 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid @@ -7,9 +7,6 @@ EXPLAIN (ddl) alter table t add primary key (a); Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ADD PRIMARY KEY (‹a›); ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 2 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} @@ -20,6 +17,9 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ADD PRIM │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} + │ ├── 2 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 11 Mutation operations │ ├── MakeDroppedColumnDeleteAndWriteOnly {"ColumnID":2,"TableID":104} │ ├── LogEvent {"TargetStatus":1} @@ -82,14 +82,14 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ADD PRIM │ │ └── 1 Validation operation │ │ └── ValidateUniqueIndex {"IndexID":2,"TableID":104} │ ├── Stage 8 of 15 in PostCommitPhase - │ │ ├── 2 elements transitioning toward ABSENT - │ │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ │ ├── 4 elements transitioning toward TRANSIENT_ABSENT │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} │ │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ │ ├── 2 elements transitioning toward ABSENT + │ │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ │ └── 8 Mutation operations │ │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":104} │ │ ├── SetIndexName {"IndexID":1,"Name":"crdb_internal_in...","TableID":104} @@ -144,17 +144,17 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ADD PRIM │ └── ValidateUniqueIndex {"IndexID":4,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 4 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ └── VALIDATED → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ ├── 5 elements transitioning toward TRANSIENT_ABSENT │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ └── VALIDATED → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ └── 6 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} @@ -163,8 +163,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ADD PRIM │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 4 in PostCommitNonRevertiblePhase - │ ├── 1 element transitioning toward ABSENT - │ │ └── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 4} @@ -175,6 +173,8 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ADD PRIM │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 2} │ │ ├── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} + │ ├── 1 element transitioning toward ABSENT + │ │ └── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ └── 12 Mutation operations │ ├── CreateGcJobForIndex {"IndexID":1,"TableID":104} │ ├── MakeIndexAbsent {"IndexID":1,"TableID":104} @@ -196,12 +196,12 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ADD PRIM │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} └── Stage 4 of 4 in PostCommitNonRevertiblePhase + ├── 1 element transitioning toward TRANSIENT_ABSENT + │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} ├── 3 elements transitioning toward ABSENT │ ├── DELETE_ONLY → ABSENT Column:{DescID: 104, ColumnID: 2} │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} │ └── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - ├── 1 element transitioning toward TRANSIENT_ABSENT - │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} └── 6 Mutation operations ├── CreateGcJobForIndex {"IndexID":2,"TableID":104} ├── MakeIndexAbsent {"IndexID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 index e41be8c7d550..fd643771f8ff 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 10 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 index 8c8d302fed27..958c1bf0ac6b 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 11 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 index e129d7283411..eaf8ecf2ed40 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 12 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 index 7a4a9511852e..ca9464597e3a 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 13 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 index cbf35c8706d6..2a06a1d1df25 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 14 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 index 6f796eaeb27c..0f91679d7906 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 15 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 index af155f491507..3e2316912c76 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase + ├── 2 elements transitioning toward PUBLIC + │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} ├── 8 elements transitioning toward ABSENT │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - ├── 2 elements transitioning toward PUBLIC - │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} └── 11 Mutation operations ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} ├── MakeColumnPublic {"ColumnID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 index f4248306ad11..864bea701966 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 index 8f222a0984b6..84035dd0ab55 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 index 32ebb26bc944..2391459261fb 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 index 4233c8264288..eba9610c63f1 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 index f6691650b4cc..7d052cfd47a3 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 index 49035f4490c3..8437d7e65490 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 index 5b572f98718e..3c3821ec75c8 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 8 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 index 3792e52361f2..3bea4b83f4b5 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 9 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ADD PRIMARY KEY (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 14 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid index be4e49446701..64793318132c 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid @@ -7,9 +7,6 @@ EXPLAIN (ddl) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 2 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} @@ -20,6 +17,9 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} + │ ├── 2 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 11 Mutation operations │ ├── MakeDroppedColumnDeleteAndWriteOnly {"ColumnID":2,"TableID":104} │ ├── LogEvent {"TargetStatus":1} @@ -82,14 +82,14 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ │ └── 1 Validation operation │ │ └── ValidateUniqueIndex {"IndexID":2,"TableID":104} │ ├── Stage 8 of 15 in PostCommitPhase - │ │ ├── 2 elements transitioning toward ABSENT - │ │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ │ ├── 4 elements transitioning toward TRANSIENT_ABSENT │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} │ │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ │ ├── 2 elements transitioning toward ABSENT + │ │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ │ └── 8 Mutation operations │ │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":104} │ │ ├── SetIndexName {"IndexID":1,"Name":"crdb_internal_in...","TableID":104} @@ -144,17 +144,17 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ └── ValidateUniqueIndex {"IndexID":4,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 4 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ └── VALIDATED → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ ├── 5 elements transitioning toward TRANSIENT_ABSENT │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ └── VALIDATED → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ └── 6 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} @@ -163,8 +163,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 4 in PostCommitNonRevertiblePhase - │ ├── 1 element transitioning toward ABSENT - │ │ └── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 4} @@ -175,6 +173,8 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 2} │ │ ├── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} + │ ├── 1 element transitioning toward ABSENT + │ │ └── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ └── 12 Mutation operations │ ├── CreateGcJobForIndex {"IndexID":1,"TableID":104} │ ├── MakeIndexAbsent {"IndexID":1,"TableID":104} @@ -196,12 +196,12 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} └── Stage 4 of 4 in PostCommitNonRevertiblePhase + ├── 1 element transitioning toward TRANSIENT_ABSENT + │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} ├── 3 elements transitioning toward ABSENT │ ├── DELETE_ONLY → ABSENT Column:{DescID: 104, ColumnID: 2} │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} │ └── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - ├── 1 element transitioning toward TRANSIENT_ABSENT - │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} └── 6 Mutation operations ├── CreateGcJobForIndex {"IndexID":2,"TableID":104} ├── MakeIndexAbsent {"IndexID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 index c46321d34ef6..c50cd82e2034 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 10 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 index 7adcc9b13c16..9f3b00c112d1 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 11 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 index aa8ef1e3a521..56d371336c69 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 12 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 index 61b554a7bd61..3ad86ec0957c 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 13 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 index b5c5a97284fd..e1d31a0182a3 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 14 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 index 3cbc8eac266d..87e851ad9f10 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 15 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 index 278d404a265d..ff686b4b1338 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase + ├── 2 elements transitioning toward PUBLIC + │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} ├── 8 elements transitioning toward ABSENT │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - ├── 2 elements transitioning toward PUBLIC - │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} └── 11 Mutation operations ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} ├── MakeColumnPublic {"ColumnID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 index 9615729cabde..770f9d5416d4 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 index 8d1339a76f05..376ff31bfd55 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 index 6a9198a9f45c..306a06bd733c 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 index 12c92622463c..dc9fc66d1bf8 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 index 61cc5bb17586..bb5926696a3e 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 index 9530cc6ebb4a..2fdbc227bb6d 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 index c88c0d45f98b..15249b2aecaf 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 @@ -8,6 +8,9 @@ EXPLAIN (ddl) rollback at post-commit stage 8 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ ├── 8 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} @@ -17,9 +20,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 index eb5df4ea76fd..e3e444d9d15f 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 @@ -8,6 +8,11 @@ EXPLAIN (ddl) rollback at post-commit stage 9 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› ALTER PRIMARY KEY USING COLUMNS (‹a›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 4 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 11 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -20,11 +25,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› A │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ ├── 4 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 14 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"rowid","TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_vanilla b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_vanilla index b3cd5c6552b4..3aa9a50f8030 100644 --- a/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_vanilla +++ b/pkg/sql/schemachanger/testdata/explain/alter_table_alter_primary_key_vanilla @@ -99,11 +99,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ └── ValidateUniqueIndex {"IndexID":4,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} @@ -114,6 +109,11 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 3} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ └── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 1} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 10 Mutation operations │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":104} │ ├── SetIndexName {"IndexID":1,"Name":"crdb_internal_in...","TableID":104} @@ -126,11 +126,11 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› ALTER PR │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase - │ ├── 1 element transitioning toward ABSENT - │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ ├── 2 elements transitioning toward TRANSIENT_ABSENT │ │ ├── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 1} + │ ├── 1 element transitioning toward ABSENT + │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ └── 7 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":104} │ ├── CreateGcJobForIndex {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic b/pkg/sql/schemachanger/testdata/explain/drop_column_basic index 9191bf7214ce..55f8d319519c 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic @@ -7,15 +7,15 @@ EXPLAIN (ddl) ALTER TABLE t DROP COLUMN j; Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹j›; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 2 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ ├── 2 elements transitioning toward TRANSIENT_ABSENT │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ ├── 2 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ └── 7 Mutation operations │ ├── MakeDroppedColumnDeleteAndWriteOnly {"ColumnID":2,"TableID":104} │ ├── LogEvent {"TargetStatus":1} @@ -75,18 +75,18 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ └── ValidateUniqueIndex {"IndexID":2,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase - │ ├── 5 elements transitioning toward ABSENT - │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} │ ├── 2 elements transitioning toward TRANSIENT_ABSENT │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ ├── 5 elements transitioning toward ABSENT + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ └── 8 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":104} @@ -97,10 +97,10 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase - │ ├── 1 element transitioning toward ABSENT - │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ ├── 1 element transitioning toward TRANSIENT_ABSENT │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} + │ ├── 1 element transitioning toward ABSENT + │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ └── 5 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":104} │ ├── CreateGcJobForIndex {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_1_of_7 index 3a3643d03245..d9f1893ae57c 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_1_of_7 @@ -8,14 +8,14 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase + ├── 2 elements transitioning toward PUBLIC + │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} ├── 4 elements transitioning toward ABSENT │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - ├── 2 elements transitioning toward PUBLIC - │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} └── 9 Mutation operations ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} ├── MakeColumnPublic {"ColumnID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_2_of_7 index b186f8147827..0e850b79dd7b 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_2_of_7 @@ -8,14 +8,14 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── 4 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ └── 8 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_3_of_7 index 3564215441a9..cf65e3b830ce 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_3_of_7 @@ -8,14 +8,14 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── 4 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ └── 8 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_4_of_7 index fada25d32582..d9ff3c6936b8 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_4_of_7 @@ -8,14 +8,14 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── 4 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ └── 8 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_5_of_7 index 2b3854b6a7b4..01fac955a805 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_5_of_7 @@ -8,14 +8,14 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── 4 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ └── 7 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_6_of_7 index 800a1818fd39..173baf41cb86 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_6_of_7 @@ -8,14 +8,14 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── 4 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ └── 7 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":3,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_7_of_7 index ed3dd8a6cc16..17bddbf91798 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_basic.rollback_7_of_7 @@ -8,14 +8,14 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── 4 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ └── 7 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":2,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index index 4bf1f0a25b51..92aecc1f9ed5 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index @@ -7,6 +7,12 @@ EXPLAIN (ddl) ALTER TABLE t DROP COLUMN j CASCADE; Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹j› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 6 elements transitioning toward ABSENT │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -14,12 +20,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── 2 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 12 Mutation operations │ ├── MakeDroppedColumnDeleteAndWriteOnly {"ColumnID":2,"TableID":104} │ ├── LogEvent {"TargetStatus":1} @@ -84,6 +84,12 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ └── ValidateUniqueIndex {"IndexID":3,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 9 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 3} @@ -94,12 +100,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ └── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ ├── 2 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 10 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":3,"TableID":104} @@ -112,13 +112,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase + │ ├── 1 element transitioning toward TRANSIENT_ABSENT + │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 4 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT Column:{DescID: 104, ColumnID: 3} │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 3} │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ │ └── DELETE_ONLY → ABSENT SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 1 element transitioning toward TRANSIENT_ABSENT - │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 9 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":104} │ ├── LogEvent {"TargetStatus":1} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_1_of_7 index 61a89e25d4db..77ad6b95fc79 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_1_of_7 @@ -8,11 +8,6 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase - ├── 4 elements transitioning toward ABSENT - │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} ├── 6 elements transitioning toward PUBLIC │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -20,6 +15,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} + ├── 4 elements transitioning toward ABSENT + │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} └── 14 Mutation operations ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_2_of_7 index fade3c656f29..d3394699f993 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_2_of_7 @@ -8,11 +8,6 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -20,6 +15,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_3_of_7 index 98789b6951b4..1ed91bb75392 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_3_of_7 @@ -8,11 +8,6 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -20,6 +15,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_4_of_7 index a2c90d2aa915..8c9b172f19b4 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_4_of_7 @@ -8,11 +8,6 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -20,6 +15,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_5_of_7 index 40b4ecd7191a..4adec81d213d 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_5_of_7 @@ -8,11 +8,6 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -20,6 +15,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_6_of_7 index 4c9fd672dead..c8d92c0f1ab3 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_6_of_7 @@ -8,11 +8,6 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -20,6 +15,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_7_of_7 index 1291f5f8b041..b92da02f8e93 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_computed_index.rollback_7_of_7 @@ -8,11 +8,6 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} @@ -20,6 +15,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 3} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_10_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_10_of_15 index e0aeec5611b8..81c5a97133f6 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_10_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_10_of_15 @@ -9,6 +9,15 @@ EXPLAIN (ddl) rollback at post-commit stage 10 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 8 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 13 elements transitioning toward ABSENT │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} @@ -23,15 +32,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ ├── 8 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 19 Mutation operations │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_11_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_11_of_15 index 6c67fafa30ca..dc4aa0e21a95 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_11_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_11_of_15 @@ -9,6 +9,15 @@ EXPLAIN (ddl) rollback at post-commit stage 11 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 8 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 13 elements transitioning toward ABSENT │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} @@ -23,15 +32,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ ├── 8 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 19 Mutation operations │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_12_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_12_of_15 index 10abeb6c1d4d..b1a78782d20e 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_12_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_12_of_15 @@ -9,6 +9,15 @@ EXPLAIN (ddl) rollback at post-commit stage 12 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 8 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 13 elements transitioning toward ABSENT │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} @@ -23,15 +32,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ ├── 8 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 19 Mutation operations │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_13_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_13_of_15 index f4f834b277dd..80ae4dccacd1 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_13_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_13_of_15 @@ -9,6 +9,15 @@ EXPLAIN (ddl) rollback at post-commit stage 13 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 8 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 13 elements transitioning toward ABSENT │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} @@ -23,15 +32,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ ├── 8 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 17 Mutation operations │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_14_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_14_of_15 index a059869c7d00..0478d2649978 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_14_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_14_of_15 @@ -9,6 +9,15 @@ EXPLAIN (ddl) rollback at post-commit stage 14 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 8 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 13 elements transitioning toward ABSENT │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} @@ -23,15 +32,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ ├── 8 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 17 Mutation operations │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_15_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_15_of_15 index 1c7e9e571e6a..b8134bf555dd 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_15_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_15_of_15 @@ -9,6 +9,15 @@ EXPLAIN (ddl) rollback at post-commit stage 15 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 8 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 13 elements transitioning toward ABSENT │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} @@ -23,15 +32,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ ├── 8 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 17 Mutation operations │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_1_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_1_of_15 index 4038e58ef625..4f02059816af 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_1_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_1_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase - ├── 6 elements transitioning toward ABSENT - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ └── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} ├── 6 elements transitioning toward PUBLIC │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + ├── 6 elements transitioning toward ABSENT + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ └── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} └── 14 Mutation operations ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_2_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_2_of_15 index c1df9924429a..2dbc302c090a 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_2_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_2_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_3_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_3_of_15 index 90fa2bdcdd3b..34b703a5f5b4 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_3_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_3_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_4_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_4_of_15 index 37823b8973cd..df01b16d59a9 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_4_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_4_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 13 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_5_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_5_of_15 index cff6470d1586..65eace05ff7a 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_5_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_5_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_6_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_6_of_15 index 6d8b0b607f80..a81e44c4c0f6 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_6_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_6_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_7_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_7_of_15 index 343c3970c961..4ad3d4fe93ec 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_7_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_7_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_8_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_8_of_15 index 2333970b0678..253057d1c2d3 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_8_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_8_of_15 @@ -9,13 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 8 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 6 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} @@ -23,6 +16,13 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 12 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetColumnName {"ColumnID":4,"Name":"crdb_internal_id...","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_9_of_15 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_9_of_15 index 723c3cea9b08..71cfc4c03175 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_9_of_15 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.rollback_9_of_15 @@ -9,6 +9,15 @@ EXPLAIN (ddl) rollback at post-commit stage 9 of 15; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.public.‹t› (‹k›); └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 8 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 13 elements transitioning toward ABSENT │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} @@ -23,15 +32,6 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ ├── 8 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 4} - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 20 Mutation operations │ ├── SetIndexName {"IndexID":1,"Name":"t_pkey","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_1_of_2 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_1_of_2 index 4ca6238a76a2..9b5eaa493681 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_1_of_2 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_1_of_2 @@ -7,13 +7,6 @@ EXPLAIN (ddl) ALTER TABLE t DROP COLUMN j CASCADE; Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹j› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 4} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 3 elements transitioning toward PUBLIC │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} @@ -22,6 +15,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 4} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 14 Mutation operations │ ├── MakeDroppedColumnDeleteAndWriteOnly {"ColumnID":2,"TableID":104} │ ├── LogEvent {"TargetStatus":1} @@ -88,6 +88,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ └── ValidateUniqueIndex {"IndexID":3,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ ├── 3 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} │ ├── 11 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 4} @@ -100,13 +107,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ └── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ ├── 3 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} │ └── 10 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":4,"TableID":104} @@ -119,13 +119,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase + │ ├── 1 element transitioning toward TRANSIENT_ABSENT + │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 4 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT Column:{DescID: 104, ColumnID: 4} │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ │ └── DELETE_ONLY → ABSENT SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 1 element transitioning toward TRANSIENT_ABSENT - │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 9 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":104} │ ├── LogEvent {"TargetStatus":1} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 index a317fdec2cdb..2737cfb21a29 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 @@ -56,9 +56,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ └── 1 Validation operation │ │ └── ValidateUniqueIndex {"IndexID":3,"TableID":104} │ ├── Stage 8 of 15 in PostCommitPhase - │ │ ├── 2 elements transitioning toward ABSENT - │ │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ │ ├── 7 elements transitioning toward PUBLIC │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} │ │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} @@ -69,6 +66,9 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} │ │ ├── 1 element transitioning toward TRANSIENT_ABSENT │ │ │ └── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} + │ │ ├── 2 elements transitioning toward ABSENT + │ │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} │ │ └── 12 Mutation operations │ │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":104} │ │ ├── SetIndexName {"IndexID":1,"Name":"crdb_internal_in...","TableID":104} @@ -127,6 +127,14 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ └── ValidateUniqueIndex {"IndexID":5,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: idx, IndexID: 5} + │ ├── 4 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ ├── 10 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 4} @@ -138,14 +146,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ └── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: idx, IndexID: 5} - │ ├── 4 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} │ └── 10 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":4,"TableID":104} @@ -158,6 +158,9 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} └── Stage 2 of 2 in PostCommitNonRevertiblePhase + ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ ├── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} ├── 6 elements transitioning toward ABSENT │ ├── DELETE_ONLY → ABSENT Column:{DescID: 104, ColumnID: 2} │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} @@ -165,9 +168,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ └── DELETE_ONLY → ABSENT SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - ├── 2 elements transitioning toward TRANSIENT_ABSENT - │ ├── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} └── 13 Mutation operations ├── CreateGcJobForIndex {"IndexID":1,"TableID":104} ├── MakeIndexAbsent {"IndexID":1,"TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index index af2234fa4ee0..ea6ccb35eb5f 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index @@ -10,9 +10,6 @@ EXPLAIN (ddl) ALTER TABLE t.test DROP pi; Schema change plan for ALTER TABLE ‹t›.‹public›.‹test› DROP COLUMN ‹pi›; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 2 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 106, ColumnID: 3} - │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -23,6 +20,9 @@ Schema change plan for ALTER TABLE ‹t›.‹public›.‹test› DROP COLUMN │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} + │ ├── 2 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 106, ColumnID: 3} + │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ └── 11 Mutation operations │ ├── MakeDroppedColumnDeleteAndWriteOnly {"ColumnID":3,"TableID":106} │ ├── LogEvent {"TargetStatus":1} @@ -86,14 +86,6 @@ Schema change plan for ALTER TABLE ‹t›.‹public›.‹test› DROP COLUMN │ └── ValidateUniqueIndex {"IndexID":4,"TableID":106} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase - │ ├── 7 elements transitioning toward ABSENT - │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 106, ColumnID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 1} - │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106, Name: test_pkey, IndexID: 1} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 106, Name: test_pkey, IndexID: 4} @@ -102,6 +94,14 @@ Schema change plan for ALTER TABLE ‹t›.‹public›.‹test› DROP COLUMN │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} + │ ├── 7 elements transitioning toward ABSENT + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 106, ColumnID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 1} + │ │ ├── PUBLIC → WRITE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106, Name: test_pkey, IndexID: 1} │ └── 8 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":3,"TableID":106} │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":106} @@ -112,10 +112,10 @@ Schema change plan for ALTER TABLE ‹t›.‹public›.‹test› DROP COLUMN │ ├── SetJobStateOnDescriptor {"DescriptorID":106} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase - │ ├── 1 element transitioning toward ABSENT - │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} │ ├── 1 element transitioning toward TRANSIENT_ABSENT │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 106, IndexID: 5, ConstraintID: 6, SourceIndexID: 1} + │ ├── 1 element transitioning toward ABSENT + │ │ └── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} │ └── 5 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":106} │ ├── CreateGcJobForIndex {"IndexID":5,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_1_of_7 index 5073ab3745c0..ffd822345aac 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_1_of_7 @@ -11,6 +11,9 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 7; Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP COLUMN ‹pi›; └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase + ├── 2 elements transitioning toward PUBLIC + │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} + │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} ├── 8 elements transitioning toward ABSENT │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -20,9 +23,6 @@ Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP C │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ └── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - ├── 2 elements transitioning toward PUBLIC - │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} - │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} └── 9 Mutation operations ├── SetColumnName {"ColumnID":3,"Name":"pi","TableID":106} ├── MakeColumnPublic {"ColumnID":3,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_2_of_7 index f100c22ccaf9..6d68357ece79 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_2_of_7 @@ -11,6 +11,9 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 7; Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP COLUMN ‹pi›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ ├── 8 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -20,9 +23,6 @@ Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP C │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ └── 8 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"pi","TableID":106} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":5,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_3_of_7 index c487400caa27..bd29f1941187 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_3_of_7 @@ -11,6 +11,9 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 7; Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP COLUMN ‹pi›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ ├── 8 elements transitioning toward ABSENT │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -20,9 +23,6 @@ Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP C │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ └── 8 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"pi","TableID":106} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":5,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_4_of_7 index 75174dec9c2f..01ea76466665 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_4_of_7 @@ -11,6 +11,9 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 7; Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP COLUMN ‹pi›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ ├── 8 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -20,9 +23,6 @@ Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP C │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ └── 8 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"pi","TableID":106} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":5,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_5_of_7 index 63581e07274e..d89e80f0db3b 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_5_of_7 @@ -11,6 +11,9 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 7; Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP COLUMN ‹pi›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ ├── 8 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -20,9 +23,6 @@ Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP C │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ └── 7 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"pi","TableID":106} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":5,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_6_of_7 index 3aaed05a4262..f59337f7cc66 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_6_of_7 @@ -11,6 +11,9 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 7; Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP COLUMN ‹pi›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ ├── 8 elements transitioning toward ABSENT │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -20,9 +23,6 @@ Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP C │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ └── 7 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"pi","TableID":106} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":5,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_7_of_7 index b7b4d3a04cb7..bdabbddc006e 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_unique_index.rollback_7_of_7 @@ -11,6 +11,9 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 7; Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP COLUMN ‹pi›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} + │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ ├── 8 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} @@ -20,9 +23,6 @@ Schema change plan for rolling back ALTER TABLE ‹t›.public.‹test› DROP C │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106, ColumnID: 3} - │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} │ └── 7 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"pi","TableID":106} │ ├── MakeDroppedIndexDeleteOnly {"IndexID":4,"TableID":106} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index index 2d2feca31f96..4511771cbf3c 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index @@ -7,17 +7,17 @@ EXPLAIN (ddl) ALTER TABLE t DROP COLUMN j; Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹j›; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ ├── 2 elements transitioning toward PUBLIC │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ ├── 2 elements transitioning toward TRANSIENT_ABSENT │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ └── 9 Mutation operations │ ├── MakeDroppedNonPrimaryIndexDeleteAndWriteOnly {"IndexID":2,"TableID":104} │ ├── SetIndexName {"IndexID":2,"Name":"crdb_internal_in...","TableID":104} @@ -79,6 +79,12 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ └── ValidateUniqueIndex {"IndexID":3,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 8 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} @@ -88,12 +94,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 2} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ └── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ ├── 2 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 9 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedPrimaryIndexDeleteAndWriteOnly {"IndexID":1,"TableID":104} @@ -105,11 +105,11 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase + │ ├── 1 element transitioning toward TRANSIENT_ABSENT + │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 2 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ │ └── DELETE_ONLY → ABSENT SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 1 element transitioning toward TRANSIENT_ABSENT - │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 8 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":104} │ ├── LogEvent {"TargetStatus":1} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_1_of_7 index 3aa981462041..c2576a55fc4a 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_1_of_7 @@ -8,16 +8,16 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase - ├── 4 elements transitioning toward ABSENT - │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} ├── 4 elements transitioning toward PUBLIC │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} + ├── 4 elements transitioning toward ABSENT + │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} └── 11 Mutation operations ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} ├── SetIndexName {"IndexID":2,"Name":"t_j_idx","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_2_of_7 index 7e58176c74de..c40861e107bf 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_2_of_7 @@ -8,16 +8,16 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetIndexName {"IndexID":2,"Name":"t_j_idx","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_3_of_7 index c913887eba9a..af14d4e1530e 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_3_of_7 @@ -8,16 +8,16 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetIndexName {"IndexID":2,"Name":"t_j_idx","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_4_of_7 index 5fb9f426ba75..fbc8f4e50d1f 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_4_of_7 @@ -8,16 +8,16 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 10 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetIndexName {"IndexID":2,"Name":"t_j_idx","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_5_of_7 index 9a34edeb342a..41b0d24c3bc6 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_5_of_7 @@ -8,16 +8,16 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetIndexName {"IndexID":2,"Name":"t_j_idx","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_6_of_7 index f9fef0bf8338..5f4ffa684b1c 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_6_of_7 @@ -8,16 +8,16 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetIndexName {"IndexID":2,"Name":"t_j_idx","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_7_of_7 index 1817b9bdffe3..b887580de4b1 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_with_index.rollback_7_of_7 @@ -8,16 +8,16 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j›; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ ├── 4 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ └── 9 Mutation operations │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} │ ├── SetIndexName {"IndexID":2,"Name":"t_j_idx","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_1_of_7 index fdcdae2e5819..323d81e19409 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_1_of_7 @@ -9,11 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 1 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹k› CASCADE; └── PostCommitNonRevertiblePhase └── Stage 1 of 1 in PostCommitNonRevertiblePhase - ├── 4 elements transitioning toward ABSENT - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ └── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} ├── 8 elements transitioning toward PUBLIC │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 3} │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: k, ColumnID: 3} @@ -23,6 +18,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + ├── 4 elements transitioning toward ABSENT + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ └── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} └── 17 Mutation operations ├── SetColumnName {"ColumnID":3,"Name":"k","TableID":104} ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_2_of_7 index b8d5dad53ea5..b1b40d712674 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_2_of_7 @@ -9,11 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 2 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹k› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 8 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 3} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: k, ColumnID: 3} @@ -23,6 +18,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 16 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"k","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_3_of_7 index 84d3aacf150f..eba3783b25d2 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_3_of_7 @@ -9,11 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 3 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹k› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 8 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 3} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: k, ColumnID: 3} @@ -23,6 +18,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 16 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"k","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_4_of_7 index be6d464361e7..013ea01434ad 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_4_of_7 @@ -9,11 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 4 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹k› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 8 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 3} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: k, ColumnID: 3} @@ -23,6 +18,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── DELETE_ONLY → ABSENT PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 16 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"k","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_5_of_7 index ca606b5d9cab..86b2eb04ee35 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_5_of_7 @@ -9,11 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 5 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹k› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 8 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 3} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: k, ColumnID: 3} @@ -23,6 +18,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 15 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"k","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_6_of_7 index f5d3db3f31ba..6703a40adf4f 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_6_of_7 @@ -9,11 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 6 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹k› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 8 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 3} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: k, ColumnID: 3} @@ -23,6 +18,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── MERGE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 15 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"k","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_7_of_7 index bd510aa98094..617c3e3b16d7 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.rollback_7_of_7 @@ -9,11 +9,6 @@ EXPLAIN (ddl) rollback at post-commit stage 7 of 7; Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹j› CASCADE; ALTER TABLE ‹defaultdb›.public.‹t› DROP COLUMN ‹k› CASCADE; └── PostCommitNonRevertiblePhase ├── Stage 1 of 2 in PostCommitNonRevertiblePhase - │ ├── 4 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 8 elements transitioning toward PUBLIC │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104, ColumnID: 3} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: k, ColumnID: 3} @@ -23,6 +18,11 @@ Schema change plan for rolling back ALTER TABLE ‹defaultdb›.public.‹t› D │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ ├── 4 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── WRITE_ONLY → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 15 Mutation operations │ ├── SetColumnName {"ColumnID":3,"Name":"k","TableID":104} │ ├── SetColumnName {"ColumnID":2,"Name":"j","TableID":104} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_1_of_2 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_1_of_2 index 4ca6238a76a2..9b5eaa493681 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_1_of_2 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_1_of_2 @@ -7,13 +7,6 @@ EXPLAIN (ddl) ALTER TABLE t DROP COLUMN j CASCADE; Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹j› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 6 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 4} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ├── 3 elements transitioning toward PUBLIC │ │ ├── ABSENT → BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} @@ -22,6 +15,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ ├── 6 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104, ColumnID: 4} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ └── 14 Mutation operations │ ├── MakeDroppedColumnDeleteAndWriteOnly {"ColumnID":2,"TableID":104} │ ├── LogEvent {"TargetStatus":1} @@ -88,6 +88,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ └── ValidateUniqueIndex {"IndexID":3,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ ├── 3 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} │ ├── 11 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 4} @@ -100,13 +107,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} │ │ └── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ ├── 3 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ └── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} │ └── 10 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":4,"TableID":104} @@ -119,13 +119,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase + │ ├── 1 element transitioning toward TRANSIENT_ABSENT + │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 4 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT Column:{DescID: 104, ColumnID: 4} │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ │ └── DELETE_ONLY → ABSENT SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 1 element transitioning toward TRANSIENT_ABSENT - │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 9 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":104} │ ├── LogEvent {"TargetStatus":1} diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 index ac66bdc75b1b..b604773cc105 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 @@ -66,6 +66,12 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ └── ValidateUniqueIndex {"IndexID":3,"TableID":104} └── PostCommitNonRevertiblePhase ├── Stage 1 of 3 in PostCommitNonRevertiblePhase + │ ├── 2 elements transitioning toward PUBLIC + │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ └── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 14 elements transitioning toward ABSENT │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 3} │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104, ColumnID: 2} @@ -81,12 +87,6 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ │ ├── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ ├── 2 elements transitioning toward PUBLIC - │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ ├── 2 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── PUBLIC → TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ └── WRITE_ONLY → TRANSIENT_DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 12 Mutation operations │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":3,"TableID":104} │ ├── MakeDroppedColumnDeleteOnly {"ColumnID":2,"TableID":104} @@ -101,13 +101,13 @@ Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COL │ ├── SetJobStateOnDescriptor {"DescriptorID":104} │ └── UpdateSchemaChangerJob {"IsNonCancelable":true,"RunningStatus":"PostCommitNonRev..."} ├── Stage 2 of 3 in PostCommitNonRevertiblePhase + │ ├── 1 element transitioning toward TRANSIENT_ABSENT + │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ ├── 4 elements transitioning toward ABSENT │ │ ├── DELETE_ONLY → ABSENT Column:{DescID: 104, ColumnID: 4} │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} │ │ ├── WRITE_ONLY → DELETE_ONLY PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ │ └── DELETE_ONLY → ABSENT SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ ├── 1 element transitioning toward TRANSIENT_ABSENT - │ │ └── TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ └── 9 Mutation operations │ ├── MakeDroppedIndexDeleteOnly {"IndexID":1,"TableID":104} │ ├── LogEvent {"TargetStatus":1} diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/add_column b/pkg/sql/schemachanger/testdata/explain_verbose/add_column index 5223609af54d..6fd0514da4dc 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/add_column +++ b/pkg/sql/schemachanger/testdata/explain_verbose/add_column @@ -347,26 +347,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN j INT NOT NULL DEFAU │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 3 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ │ PUBLIC → WRITE_ONLY - │ │ │ - │ │ └── • IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ rule: "index no longer public before dependents" - │ │ │ ├── • 3 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 106, ColumnID: 2} @@ -429,6 +409,26 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN j INT NOT NULL DEFAU │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ + │ ├── • 3 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ │ PUBLIC → WRITE_ONLY + │ │ │ + │ │ └── • IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ rule: "index no longer public before dependents" + │ │ │ └── • 9 Mutation operations │ │ │ ├── • MakeDroppedPrimaryIndexDeleteAndWriteOnly @@ -488,11 +488,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN j INT NOT NULL DEFAU │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 1 element transitioning toward ABSENT - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 1 element transitioning toward TRANSIENT_ABSENT │ │ │ │ │ └── • TemporaryIndex:{DescID: 106, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} @@ -504,6 +499,11 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN j INT NOT NULL DEFAU │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 3} │ │ rule: "dependents removed before index" │ │ + │ ├── • 1 element transitioning toward ABSENT + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 5 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/add_column_default_seq b/pkg/sql/schemachanger/testdata/explain_verbose/add_column_default_seq index 7f42f2e53628..af8573661385 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/add_column_default_seq +++ b/pkg/sql/schemachanger/testdata/explain_verbose/add_column_default_seq @@ -372,26 +372,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN l INT NOT NULL DEFAU │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 3 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ │ PUBLIC → WRITE_ONLY - │ │ │ - │ │ └── • IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ rule: "index no longer public before dependents" - │ │ │ ├── • 3 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 106, ColumnID: 2} @@ -454,6 +434,26 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN l INT NOT NULL DEFAU │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ + │ ├── • 3 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ │ PUBLIC → WRITE_ONLY + │ │ │ + │ │ └── • IndexName:{DescID: 106, Name: tbl_pkey, IndexID: 1} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ rule: "index no longer public before dependents" + │ │ │ └── • 10 Mutation operations │ │ │ ├── • MakeDroppedPrimaryIndexDeleteAndWriteOnly @@ -516,11 +516,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN l INT NOT NULL DEFAU │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 1 element transitioning toward ABSENT - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 1 element transitioning toward TRANSIENT_ABSENT │ │ │ │ │ └── • TemporaryIndex:{DescID: 106, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} @@ -532,6 +527,11 @@ EXPLAIN (ddl, verbose) ALTER TABLE db.public.tbl ADD COLUMN l INT NOT NULL DEFAU │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 3} │ │ rule: "dependents removed before index" │ │ + │ ├── • 1 element transitioning toward ABSENT + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 6 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid index 840de9b9c9dd..5efc6fc6eee7 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid @@ -10,17 +10,6 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 2 elements transitioning toward ABSENT -│ │ │ -│ │ ├── • Column:{DescID: 104, ColumnID: 2} -│ │ │ PUBLIC → WRITE_ONLY -│ │ │ -│ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} -│ │ │ PUBLIC → ABSENT -│ │ │ -│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} -│ │ rule: "column no longer public before dependents" -│ │ │ ├── • 2 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} @@ -64,6 +53,17 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ rule: "temp index existence precedes index dependents" │ │ +│ ├── • 2 elements transitioning toward ABSENT +│ │ │ +│ │ ├── • Column:{DescID: 104, ColumnID: 2} +│ │ │ PUBLIC → WRITE_ONLY +│ │ │ +│ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} +│ │ │ PUBLIC → ABSENT +│ │ │ +│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} +│ │ rule: "column no longer public before dependents" +│ │ │ └── • 11 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteAndWriteOnly @@ -307,17 +307,6 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ │ │ ├── • Stage 8 of 15 in PostCommitPhase │ │ │ -│ │ ├── • 2 elements transitioning toward ABSENT -│ │ │ │ -│ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED -│ │ │ │ -│ │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} -│ │ │ │ PUBLIC → ABSENT -│ │ │ │ -│ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} -│ │ │ rule: "index no longer public before dependents" -│ │ │ │ │ ├── • 4 elements transitioning toward TRANSIENT_ABSENT │ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -354,6 +343,17 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ │ rule: "temp index existence precedes index dependents" │ │ │ +│ │ ├── • 2 elements transitioning toward ABSENT +│ │ │ │ +│ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} +│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ +│ │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} +│ │ │ rule: "index no longer public before dependents" +│ │ │ │ │ └── • 8 Mutation operations │ │ │ │ │ ├── • MakeDroppedPrimaryIndexDeleteAndWriteOnly @@ -536,35 +536,6 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ ├── • Stage 1 of 4 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column no longer public before dependents" - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ VALIDATED → DELETE_ONLY - │ │ │ ├── • 5 elements transitioning toward TRANSIENT_ABSENT │ │ │ │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} @@ -594,6 +565,35 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column no longer public before dependents" + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ VALIDATED → DELETE_ONLY + │ │ │ └── • 6 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -623,20 +623,6 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ ├── • Stage 2 of 4 in PostCommitNonRevertiblePhase │ │ - │ ├── • 1 element transitioning toward ABSENT - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ DELETE_ONLY → ABSENT - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ rule: "dependents removed before index" - │ │ │ ├── • 2 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} @@ -708,6 +694,20 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} │ │ rule: "dependents removed before index" │ │ + │ ├── • 1 element transitioning toward ABSENT + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ DELETE_ONLY → ABSENT + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ rule: "dependents removed before index" + │ │ │ └── • 12 Mutation operations │ │ │ ├── • CreateGcJobForIndex @@ -800,6 +800,20 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ RunningStatus: PostCommitNonRevertiblePhase stage 4 of 4 with 4 MutationType ops pending │ └── • Stage 4 of 4 in PostCommitNonRevertiblePhase + │ + ├── • 1 element transitioning toward TRANSIENT_ABSENT + │ │ + │ └── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ + │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} + │ │ rule: "dependents removed before index" + │ │ + │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} + │ │ rule: "dependents removed before index" + │ │ + │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 2} + │ rule: "dependents removed before index" │ ├── • 3 elements transitioning toward ABSENT │ │ @@ -846,20 +860,6 @@ EXPLAIN (ddl, verbose) alter table t add primary key (a); │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} │ rule: "column no longer public before dependents" │ - ├── • 1 element transitioning toward TRANSIENT_ABSENT - │ │ - │ └── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ - │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} - │ │ rule: "dependents removed before index" - │ │ - │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} - │ │ rule: "dependents removed before index" - │ │ - │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 2} - │ rule: "dependents removed before index" - │ └── • 6 Mutation operations │ ├── • CreateGcJobForIndex diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 index 0dee763526b4..70d3efd7ab0c 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_10_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 10 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -79,45 +118,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 10 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 index 911306702681..b94dfda93991 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_11_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 11 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -79,45 +118,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 11 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 index fd014c62622d..9ae70b4b805d 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_12_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 12 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -79,45 +118,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 12 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 index 423199c3c70a..1faec8dbe273 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_13_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 13 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -73,45 +112,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 13 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 index 4e9bac68e208..f7bd63391384 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_14_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 14 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -73,45 +112,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 14 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 index 4977e27698a1..bf6d40168120 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_15_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 15 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -73,45 +112,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 15 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 index 4acd3e789d86..8743e1a38665 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_1_of_15 @@ -10,6 +10,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 15; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase + │ + ├── • 2 elements transitioning toward PUBLIC + │ │ + │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ WRITE_ONLY → PUBLIC + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ rule: "column dependents exist before column becomes public" + │ │ + │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ ABSENT → PUBLIC │ ├── • 8 elements transitioning toward ABSENT │ │ @@ -73,26 +93,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 15; │ └── • skip PUBLIC → ABSENT operations │ rule: "skip index-column removal ops on index removal" │ - ├── • 2 elements transitioning toward PUBLIC - │ │ - │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ WRITE_ONLY → PUBLIC - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ rule: "column dependents exist before column becomes public" - │ │ - │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ ABSENT → PUBLIC - │ └── • 11 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 index 546771b269f3..8b03f3f772b9 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_2_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -67,26 +87,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 index 4c4c94c62677..318373d1697a 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_3_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -67,26 +87,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 index e3e559d8ee7b..402225ead8eb 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_4_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -67,26 +87,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 index f263220642b2..02a0588a6cc5 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_5_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 index 8bdecf543ac8..b45a32931c8d 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_6_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 index 993ea0a50de3..4c4ecd558e2c 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_7_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 index 2530e6c25df8..3114ba6ea984 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_8_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 8 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 8 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 index 1f7afde05cca..c0f5328ffc7e 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_add_primary_key_drop_rowid.rollback_9_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 9 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -82,45 +121,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 9 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 14 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid index e0be656adee5..b263d11a028e 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid @@ -10,17 +10,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 2 elements transitioning toward ABSENT -│ │ │ -│ │ ├── • Column:{DescID: 104, ColumnID: 2} -│ │ │ PUBLIC → WRITE_ONLY -│ │ │ -│ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} -│ │ │ PUBLIC → ABSENT -│ │ │ -│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} -│ │ rule: "column no longer public before dependents" -│ │ │ ├── • 2 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} @@ -64,6 +53,17 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ rule: "temp index existence precedes index dependents" │ │ +│ ├── • 2 elements transitioning toward ABSENT +│ │ │ +│ │ ├── • Column:{DescID: 104, ColumnID: 2} +│ │ │ PUBLIC → WRITE_ONLY +│ │ │ +│ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} +│ │ │ PUBLIC → ABSENT +│ │ │ +│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} +│ │ rule: "column no longer public before dependents" +│ │ │ └── • 11 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteAndWriteOnly @@ -309,17 +309,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ │ │ ├── • Stage 8 of 15 in PostCommitPhase │ │ │ -│ │ ├── • 2 elements transitioning toward ABSENT -│ │ │ │ -│ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED -│ │ │ │ -│ │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} -│ │ │ │ PUBLIC → ABSENT -│ │ │ │ -│ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} -│ │ │ rule: "index no longer public before dependents" -│ │ │ │ │ ├── • 4 elements transitioning toward TRANSIENT_ABSENT │ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -356,6 +345,17 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 2} │ │ │ rule: "temp index existence precedes index dependents" │ │ │ +│ │ ├── • 2 elements transitioning toward ABSENT +│ │ │ │ +│ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} +│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ +│ │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} +│ │ │ rule: "index no longer public before dependents" +│ │ │ │ │ └── • 8 Mutation operations │ │ │ │ │ ├── • MakeDroppedPrimaryIndexDeleteAndWriteOnly @@ -539,35 +539,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ ├── • Stage 1 of 4 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column no longer public before dependents" - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ VALIDATED → DELETE_ONLY - │ │ │ ├── • 5 elements transitioning toward TRANSIENT_ABSENT │ │ │ │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} @@ -597,6 +568,35 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column no longer public before dependents" + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ VALIDATED → DELETE_ONLY + │ │ │ └── • 6 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -626,20 +626,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ ├── • Stage 2 of 4 in PostCommitNonRevertiblePhase │ │ - │ ├── • 1 element transitioning toward ABSENT - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ DELETE_ONLY → ABSENT - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ rule: "dependents removed before index" - │ │ │ ├── • 2 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 4, TemporaryIndexID: 5, SourceIndexID: 2} @@ -711,6 +697,20 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} │ │ rule: "dependents removed before index" │ │ + │ ├── • 1 element transitioning toward ABSENT + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ DELETE_ONLY → ABSENT + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ rule: "dependents removed before index" + │ │ │ └── • 12 Mutation operations │ │ │ ├── • CreateGcJobForIndex @@ -805,6 +805,20 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ RunningStatus: PostCommitNonRevertiblePhase stage 4 of 4 with 4 MutationType ops pending │ └── • Stage 4 of 4 in PostCommitNonRevertiblePhase + │ + ├── • 1 element transitioning toward TRANSIENT_ABSENT + │ │ + │ └── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ + │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} + │ │ rule: "dependents removed before index" + │ │ + │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} + │ │ rule: "dependents removed before index" + │ │ + │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 2} + │ rule: "dependents removed before index" │ ├── • 3 elements transitioning toward ABSENT │ │ @@ -851,20 +865,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (a); │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} │ rule: "column no longer public before dependents" │ - ├── • 1 element transitioning toward TRANSIENT_ABSENT - │ │ - │ └── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ - │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} - │ │ rule: "dependents removed before index" - │ │ - │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} - │ │ rule: "dependents removed before index" - │ │ - │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 2} - │ rule: "dependents removed before index" - │ └── • 6 Mutation operations │ ├── • CreateGcJobForIndex diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 index 360c5d4fcd74..5cfe89f5a628 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_10_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 10 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -79,45 +118,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 10 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 index 740a6e476ad8..ad1d2e1b4d96 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_11_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 11 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -79,45 +118,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 11 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 index a9d13a2aae08..60787b6e6048 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_12_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 12 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -79,45 +118,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 12 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 index 1174f0c55601..6cfdad474ba9 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_13_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 13 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -73,45 +112,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 13 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 index 6ad47dc922c2..760e1b3d1471 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_14_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 14 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -73,45 +112,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 14 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 index 2c3ea2373d7f..6a167bf95feb 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_15_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 15 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -73,45 +112,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 15 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 index 62081fa425ee..d51a1e040625 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_1_of_15 @@ -10,6 +10,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 15; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase + │ + ├── • 2 elements transitioning toward PUBLIC + │ │ + │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ WRITE_ONLY → PUBLIC + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ rule: "column dependents exist before column becomes public" + │ │ + │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ ABSENT → PUBLIC │ ├── • 8 elements transitioning toward ABSENT │ │ @@ -73,26 +93,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 15; │ └── • skip PUBLIC → ABSENT operations │ rule: "skip index-column removal ops on index removal" │ - ├── • 2 elements transitioning toward PUBLIC - │ │ - │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ WRITE_ONLY → PUBLIC - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ rule: "column dependents exist before column becomes public" - │ │ - │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ ABSENT → PUBLIC - │ └── • 11 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 index 8471f6587f94..aa23a022eeef 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_2_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -67,26 +87,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 index 39a7044cb506..f3cfddf39da9 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_3_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -67,26 +87,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 index 0e46b751f917..c436ca65271b 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_4_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -67,26 +87,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 index 6896fa8c2d3e..b1767530c446 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_5_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 index 012f3fbf38b2..f15875995c99 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_6_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 index 1e22b6cb7f2a..63b584cc6eb1 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_7_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 index fc568b938c90..2523c05e2d9d 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_8_of_15 @@ -11,6 +11,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 8 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 8 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 index ae01b435b079..befa3a831016 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_drop_rowid.rollback_9_of_15 @@ -11,6 +11,45 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 9 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 4 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -82,45 +121,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 9 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 4 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: rowid, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ ABSENT → PUBLIC - │ │ │ └── • 14 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_vanilla b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_vanilla index c98e00852d1f..821d19903f2f 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_vanilla +++ b/pkg/sql/schemachanger/testdata/explain_verbose/alter_table_alter_primary_key_vanilla @@ -381,35 +381,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (j); │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ PUBLIC → WRITE_ONLY - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ rule: "index no longer public before dependents" - │ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -473,6 +444,35 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (j); │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 1} │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ PUBLIC → WRITE_ONLY + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ rule: "index no longer public before dependents" + │ │ │ └── • 10 Mutation operations │ │ │ ├── • MakeDroppedPrimaryIndexDeleteAndWriteOnly @@ -529,11 +529,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (j); │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 1 element transitioning toward ABSENT - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT │ │ │ │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} @@ -548,6 +543,11 @@ EXPLAIN (ddl, verbose) ALTER TABLE t ALTER PRIMARY KEY USING COLUMNS (j); │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 5, SourceIndexID: 1} │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT │ │ + │ ├── • 1 element transitioning toward ABSENT + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 7 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic index 373e54cb12ef..700b8e466494 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic @@ -10,17 +10,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 2 elements transitioning toward ABSENT -│ │ │ -│ │ ├── • Column:{DescID: 104, ColumnID: 2} -│ │ │ PUBLIC → WRITE_ONLY -│ │ │ -│ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} -│ │ │ PUBLIC → ABSENT -│ │ │ -│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} -│ │ rule: "column no longer public before dependents" -│ │ │ ├── • 2 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -43,6 +32,17 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} │ │ rule: "temp index existence precedes index dependents" │ │ +│ ├── • 2 elements transitioning toward ABSENT +│ │ │ +│ │ ├── • Column:{DescID: 104, ColumnID: 2} +│ │ │ PUBLIC → WRITE_ONLY +│ │ │ +│ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} +│ │ │ PUBLIC → ABSENT +│ │ │ +│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} +│ │ rule: "column no longer public before dependents" +│ │ │ └── • 7 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteAndWriteOnly @@ -255,6 +255,38 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "primary index swap" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ + │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ ├── • 5 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -290,38 +322,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} │ │ rule: "index no longer public before dependents" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "primary index swap" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ - │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ └── • 8 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -368,11 +368,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 1 element transitioning toward ABSENT - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 1 element transitioning toward TRANSIENT_ABSENT │ │ │ │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 3, SourceIndexID: 1} @@ -381,6 +376,11 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} │ │ rule: "dependents removed before index" │ │ + │ ├── • 1 element transitioning toward ABSENT + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 5 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_1_of_7 index 245daf91aed5..53c03b826ac2 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_1_of_7 @@ -10,6 +10,23 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase + │ + ├── • 2 elements transitioning toward PUBLIC + │ │ + │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ WRITE_ONLY → PUBLIC + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ rule: "column dependents exist before column becomes public" + │ │ + │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ ABSENT → PUBLIC │ ├── • 4 elements transitioning toward ABSENT │ │ @@ -40,23 +57,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; │ └── • skip PUBLIC → ABSENT operations │ rule: "skip index-column removal ops on index removal" │ - ├── • 2 elements transitioning toward PUBLIC - │ │ - │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ WRITE_ONLY → PUBLIC - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ rule: "column dependents exist before column becomes public" - │ │ - │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ ABSENT → PUBLIC - │ └── • 9 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_2_of_7 index aa29a0e6d909..d1eaa2e6a8ec 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_2_of_7 @@ -11,6 +11,23 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -37,23 +54,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 8 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_3_of_7 index 5e9f38bdcc55..872386c6bff4 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_3_of_7 @@ -11,6 +11,23 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -37,23 +54,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 8 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_4_of_7 index 9181618deb1b..877404d74cab 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_4_of_7 @@ -11,6 +11,23 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -37,23 +54,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 8 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_5_of_7 index c0c32aa8f125..8b77cfc8abd8 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_5_of_7 @@ -11,6 +11,23 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -31,23 +48,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 7 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_6_of_7 index c0998e2e2a28..16f125654282 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_6_of_7 @@ -11,6 +11,23 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -31,23 +48,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 7 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_7_of_7 index 051c4fb737e7..376a03a0a5d7 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_basic.rollback_7_of_7 @@ -11,6 +11,23 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1} @@ -31,23 +48,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 7 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index index 997dc3ebe4d4..35c731e28db8 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index @@ -10,6 +10,28 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ +│ ├── • 2 elements transitioning toward PUBLIC +│ │ │ +│ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} +│ │ │ ABSENT → BACKFILL_ONLY +│ │ │ +│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} +│ │ │ ABSENT → PUBLIC +│ │ │ +│ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} +│ │ rule: "index existence precedes index dependents" +│ │ +│ ├── • 2 elements transitioning toward TRANSIENT_ABSENT +│ │ │ +│ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} +│ │ │ ABSENT → DELETE_ONLY +│ │ │ +│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} +│ │ │ ABSENT → PUBLIC +│ │ │ +│ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} +│ │ rule: "temp index existence precedes index dependents" +│ │ │ ├── • 6 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -42,28 +64,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ rule: "index no longer public before dependents" │ │ -│ ├── • 2 elements transitioning toward PUBLIC -│ │ │ -│ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} -│ │ │ ABSENT → BACKFILL_ONLY -│ │ │ -│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} -│ │ │ ABSENT → PUBLIC -│ │ │ -│ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} -│ │ rule: "index existence precedes index dependents" -│ │ -│ ├── • 2 elements transitioning toward TRANSIENT_ABSENT -│ │ │ -│ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} -│ │ │ ABSENT → DELETE_ONLY -│ │ │ -│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} -│ │ │ ABSENT → PUBLIC -│ │ │ -│ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} -│ │ rule: "temp index existence precedes index dependents" -│ │ │ └── • 12 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteAndWriteOnly @@ -311,6 +311,38 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "primary index swap" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ + │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ ├── • 9 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -373,38 +405,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ VALIDATED → DELETE_ONLY │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "primary index swap" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ - │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ └── • 10 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -459,6 +459,14 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 1 element transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ │ + │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -498,14 +506,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ │ rule: "dependents removed before index" │ │ - │ ├── • 1 element transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ │ - │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ │ └── • 9 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_1_of_7 index bde234b00922..ecc312a9f615 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_1_of_7 @@ -10,35 +10,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase - │ - ├── • 4 elements transitioning toward ABSENT - │ │ - │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ rule: "dependents removed before index" - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ DELETE_ONLY → ABSENT - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ - │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ PUBLIC → ABSENT - │ │ - │ └── • skip PUBLIC → ABSENT operations - │ rule: "skip index-column removal ops on index removal" │ ├── • 6 elements transitioning toward PUBLIC │ │ @@ -91,6 +62,35 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; │ └── • IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ ABSENT → PUBLIC │ + ├── • 4 elements transitioning toward ABSENT + │ │ + │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ rule: "dependents removed before index" + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ DELETE_ONLY → ABSENT + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ + │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ PUBLIC → ABSENT + │ │ + │ └── • skip PUBLIC → ABSENT operations + │ rule: "skip index-column removal ops on index removal" + │ └── • 14 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_2_of_7 index 4c0bf9dbbce7..6a95fd897cc1 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_2_of_7 @@ -11,32 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -88,6 +62,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_3_of_7 index ff0b9d0fad27..83b3b5aa26a2 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_3_of_7 @@ -11,32 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -88,6 +62,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_4_of_7 index aaebf618a796..ca95ff2ce34e 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_4_of_7 @@ -11,32 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ DELETE_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -88,6 +62,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ DELETE_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_5_of_7 index f8dbece8de40..354a2465c819 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_5_of_7 @@ -11,26 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -82,6 +62,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_6_of_7 index 93c0e45a0a2d..0b44f8d865f8 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_6_of_7 @@ -11,26 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -82,6 +62,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_7_of_7 index abc74e749ce7..8ac4a5aa514c 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_computed_index.rollback_7_of_7 @@ -11,26 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -82,6 +62,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_10_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_10_of_15 index f05213ca9cc3..2bf366388dd8 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_10_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_10_of_15 @@ -12,6 +12,82 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 10 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 8 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 4} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "ensure columns are in increasing order" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ rule: "index named right before index becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 13 elements transitioning toward ABSENT │ │ │ │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} @@ -95,82 +171,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 10 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 8 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 4} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "ensure columns are in increasing order" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ rule: "index named right before index becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 19 Mutation operations │ │ │ ├── • SetIndexName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_11_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_11_of_15 index d8bf9dc7912e..4704b7a78459 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_11_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_11_of_15 @@ -12,6 +12,82 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 11 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 8 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 4} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "ensure columns are in increasing order" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ rule: "index named right before index becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 13 elements transitioning toward ABSENT │ │ │ │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} @@ -95,82 +171,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 11 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 8 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 4} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "ensure columns are in increasing order" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ rule: "index named right before index becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 19 Mutation operations │ │ │ ├── • SetIndexName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_12_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_12_of_15 index 5aefa606e47b..596d1e07a5d3 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_12_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_12_of_15 @@ -12,6 +12,82 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 12 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 8 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 4} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "ensure columns are in increasing order" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ rule: "index named right before index becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 13 elements transitioning toward ABSENT │ │ │ │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} @@ -95,82 +171,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 12 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 8 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 4} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "ensure columns are in increasing order" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ rule: "index named right before index becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 19 Mutation operations │ │ │ ├── • SetIndexName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_13_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_13_of_15 index 5cd1f482e48f..3b1418718bc2 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_13_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_13_of_15 @@ -12,80 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 13 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 13 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ PUBLIC → WRITE_ONLY - │ │ │ - │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ rule: "index no longer public before dependents" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -162,6 +88,80 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 13 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 13 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ PUBLIC → WRITE_ONLY + │ │ │ + │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ rule: "index no longer public before dependents" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 17 Mutation operations │ │ │ ├── • SetIndexName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_14_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_14_of_15 index 07fcbfe44afe..a69bdaacd53a 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_14_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_14_of_15 @@ -12,80 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 14 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 13 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ PUBLIC → WRITE_ONLY - │ │ │ - │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ rule: "index no longer public before dependents" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -162,6 +88,80 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 14 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 13 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ PUBLIC → WRITE_ONLY + │ │ │ + │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ rule: "index no longer public before dependents" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 17 Mutation operations │ │ │ ├── • SetIndexName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_15_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_15_of_15 index 31fd31cda1e1..69cce34e2ea7 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_15_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_15_of_15 @@ -12,80 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 15 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 13 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ rule: "index no longer public before dependents" - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ PUBLIC → WRITE_ONLY - │ │ │ - │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ rule: "index no longer public before dependents" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -162,6 +88,80 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 15 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 13 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ rule: "index no longer public before dependents" + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ PUBLIC → WRITE_ONLY + │ │ │ + │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ rule: "index no longer public before dependents" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 6} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 6} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 17 Mutation operations │ │ │ ├── • SetIndexName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_1_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_1_of_15 index 00caae4639f3..4718c0215723 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_1_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_1_of_15 @@ -11,53 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 15; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase - │ - ├── • 6 elements transitioning toward ABSENT - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ rule: "dependents removed before index" - │ │ - │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ DELETE_ONLY → ABSENT - │ │ - │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ - │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ rule: "dependents removed before index" │ ├── • 6 elements transitioning toward PUBLIC │ │ @@ -113,6 +66,53 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 15; │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ABSENT → PUBLIC │ + ├── • 6 elements transitioning toward ABSENT + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ rule: "dependents removed before index" + │ │ + │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ DELETE_ONLY → ABSENT + │ │ + │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ + │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ rule: "dependents removed before index" + │ └── • 14 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_2_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_2_of_15 index 9341293d4412..574bff0d5326 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_2_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_2_of_15 @@ -12,47 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 6 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -107,6 +66,47 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 6 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_3_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_3_of_15 index 16274a9e8a14..32b37c2c8908 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_3_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_3_of_15 @@ -12,47 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 6 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -107,6 +66,47 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 6 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_4_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_4_of_15 index 9d1dddf77714..0b7e271f6a84 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_4_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_4_of_15 @@ -12,47 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 6 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ DELETE_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -107,6 +66,47 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 6 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ DELETE_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 13 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_5_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_5_of_15 index 0b9deb3eef5e..9cc38bdf8e41 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_5_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_5_of_15 @@ -12,38 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 6 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -98,6 +66,38 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 6 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_6_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_6_of_15 index 298708bb6371..345ac0651925 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_6_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_6_of_15 @@ -12,38 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 6 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -98,6 +66,38 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 6 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_7_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_7_of_15 index a2c1c6d9192c..22abb30c48d0 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_7_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_7_of_15 @@ -12,38 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 6 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -98,6 +66,38 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 6 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_8_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_8_of_15 index 81a068e0f6be..8a2b76adbf42 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_8_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_8_of_15 @@ -12,38 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 8 of 15; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 6 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 6 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -98,6 +66,38 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 8 of 15; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 6 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 12 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_9_of_15 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_9_of_15 index 8116a9c38a85..0835f894c952 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_9_of_15 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.rollback_9_of_15 @@ -12,6 +12,82 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 9 of 15; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 8 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 2} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Column:{DescID: 104, ColumnID: 4} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} + │ │ │ │ rule: "ensure columns are in increasing order" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ rule: "primary index swap" + │ │ │ + │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ rule: "index named right before index becomes public" + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 13 elements transitioning toward ABSENT │ │ │ │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} @@ -101,82 +177,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 9 of 15; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 8 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 2} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Column:{DescID: 104, ColumnID: 4} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC Column:{DescID: 104, ColumnID: 2} - │ │ │ │ rule: "ensure columns are in increasing order" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 104, ColumnFamilyID: 0, ColumnID: 4} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 2, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ rule: "primary index swap" - │ │ │ - │ │ ├── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 4, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 2} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ rule: "index named right before index becomes public" - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} - │ │ ABSENT → PUBLIC - │ │ │ └── • 20 Mutation operations │ │ │ ├── • SetIndexName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_1_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_1_of_2 index f35c6c887d52..2b666c0c5ffa 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_1_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_1_of_2 @@ -10,38 +10,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 6 elements transitioning toward ABSENT -│ │ │ -│ │ ├── • Column:{DescID: 104, ColumnID: 2} -│ │ │ PUBLIC → WRITE_ONLY -│ │ │ -│ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} -│ │ │ │ PUBLIC → ABSENT -│ │ │ │ -│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} -│ │ │ rule: "column no longer public before dependents" -│ │ │ -│ │ ├── • Column:{DescID: 104, ColumnID: 4} -│ │ │ │ PUBLIC → WRITE_ONLY -│ │ │ │ -│ │ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} -│ │ │ rule: "secondary indexes containing column as key reach write-only before column" -│ │ │ -│ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} -│ │ │ │ PUBLIC → ABSENT -│ │ │ │ -│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 4} -│ │ │ rule: "column no longer public before dependents" -│ │ │ -│ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} -│ │ │ PUBLIC → VALIDATED -│ │ │ -│ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} -│ │ │ PUBLIC → ABSENT -│ │ │ -│ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} -│ │ rule: "index no longer public before dependents" -│ │ │ ├── • 3 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} @@ -76,6 +44,38 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ │ rule: "temp index existence precedes index dependents" │ │ +│ ├── • 6 elements transitioning toward ABSENT +│ │ │ +│ │ ├── • Column:{DescID: 104, ColumnID: 2} +│ │ │ PUBLIC → WRITE_ONLY +│ │ │ +│ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} +│ │ │ rule: "column no longer public before dependents" +│ │ │ +│ │ ├── • Column:{DescID: 104, ColumnID: 4} +│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ +│ │ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} +│ │ │ rule: "secondary indexes containing column as key reach write-only before column" +│ │ │ +│ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 4} +│ │ │ rule: "column no longer public before dependents" +│ │ │ +│ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} +│ │ │ PUBLIC → VALIDATED +│ │ │ +│ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} +│ │ │ PUBLIC → ABSENT +│ │ │ +│ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} +│ │ rule: "index no longer public before dependents" +│ │ │ └── • 14 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteAndWriteOnly @@ -341,6 +341,47 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "primary index swap" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 3 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ + │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -421,47 +462,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ VALIDATED → DELETE_ONLY │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "primary index swap" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 3 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ - │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ └── • 10 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -516,6 +516,17 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 1 element transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ │ + │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 4} @@ -558,17 +569,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ rule: "dependents removed before index" │ │ - │ ├── • 1 element transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ │ - │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ │ └── • 9 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 index 89f18b0e9cf9..6ba3d0e67732 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 @@ -172,17 +172,6 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ │ │ ├── • Stage 8 of 15 in PostCommitPhase │ │ │ -│ │ ├── • 2 elements transitioning toward ABSENT -│ │ │ │ -│ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED -│ │ │ │ -│ │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} -│ │ │ │ PUBLIC → ABSENT -│ │ │ │ -│ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} -│ │ │ rule: "index no longer public before dependents" -│ │ │ │ │ ├── • 7 elements transitioning toward PUBLIC │ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} @@ -245,6 +234,17 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ │ │ └── • Precedence dependency from PUBLIC PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} │ │ │ rule: "primary index with new columns should exist before temp indexes" │ │ │ +│ │ ├── • 2 elements transitioning toward ABSENT +│ │ │ │ +│ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} +│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ +│ │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 1} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} +│ │ │ rule: "index no longer public before dependents" +│ │ │ │ │ └── • 12 Mutation operations │ │ │ │ │ ├── • MakeDroppedPrimaryIndexDeleteAndWriteOnly @@ -455,6 +455,47 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: idx, IndexID: 5} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ rule: "index named right before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: idx, IndexID: 5} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 4 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} + │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ ├── • 10 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -529,47 +570,6 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ │ └── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ VALIDATED → DELETE_ONLY │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 5} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 5} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: idx, IndexID: 5} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ rule: "index named right before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: idx, IndexID: 5} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY SecondaryIndex:{DescID: 104, IndexID: 5, ConstraintID: 4, TemporaryIndexID: 6, SourceIndexID: 3} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 4 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} - │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ └── • 10 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -615,6 +615,20 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ pending │ └── • Stage 2 of 2 in PostCommitNonRevertiblePhase + │ + ├── • 2 elements transitioning toward TRANSIENT_ABSENT + │ │ + │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ │ + │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ + │ └── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} + │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT │ ├── • 6 elements transitioning toward ABSENT │ │ @@ -692,20 +706,6 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ rule: "dependents removed before index" │ - ├── • 2 elements transitioning toward TRANSIENT_ABSENT - │ │ - │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ │ - │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ - │ └── • TemporaryIndex:{DescID: 104, IndexID: 6, ConstraintID: 4, SourceIndexID: 3} - │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ └── • 13 Mutation operations │ ├── • CreateGcJobForIndex diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index index 5d0819b20b2b..8cc693129b2a 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index @@ -13,17 +13,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t.test DROP pi; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 2 elements transitioning toward ABSENT -│ │ │ -│ │ ├── • Column:{DescID: 106, ColumnID: 3} -│ │ │ PUBLIC → WRITE_ONLY -│ │ │ -│ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} -│ │ │ PUBLIC → ABSENT -│ │ │ -│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 106, ColumnID: 3} -│ │ rule: "column no longer public before dependents" -│ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} @@ -70,6 +59,17 @@ EXPLAIN (ddl, verbose) ALTER TABLE t.test DROP pi; │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 106, IndexID: 5, ConstraintID: 6, SourceIndexID: 1} │ │ rule: "temp index existence precedes index dependents" │ │ +│ ├── • 2 elements transitioning toward ABSENT +│ │ │ +│ │ ├── • Column:{DescID: 106, ColumnID: 3} +│ │ │ PUBLIC → WRITE_ONLY +│ │ │ +│ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} +│ │ │ PUBLIC → ABSENT +│ │ │ +│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 106, ColumnID: 3} +│ │ rule: "column no longer public before dependents" +│ │ │ └── • 11 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteAndWriteOnly @@ -320,6 +320,56 @@ EXPLAIN (ddl, verbose) ALTER TABLE t.test DROP pi; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "primary index swap" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 106, Name: test_pkey, IndexID: 4} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 4} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 4} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 106, Name: test_pkey, IndexID: 4} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 4 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 106, IndexID: 5, ConstraintID: 6, SourceIndexID: 1} + │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} + │ │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} + │ │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} + │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ + │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ ├── • 7 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 106, ColumnID: 3} @@ -373,56 +423,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t.test DROP pi; │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} │ │ rule: "index no longer public before dependents" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "primary index swap" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 106, Name: test_pkey, IndexID: 4} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 4} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 4} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 4} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 106, Name: test_pkey, IndexID: 4} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 4 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 106, IndexID: 5, ConstraintID: 6, SourceIndexID: 1} - │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 5} - │ │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 5} - │ │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} - │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ - │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ └── • 8 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -469,11 +469,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t.test DROP pi; │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ - │ ├── • 1 element transitioning toward ABSENT - │ │ │ - │ │ └── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 1 element transitioning toward TRANSIENT_ABSENT │ │ │ │ │ └── • TemporaryIndex:{DescID: 106, IndexID: 5, ConstraintID: 6, SourceIndexID: 1} @@ -488,6 +483,11 @@ EXPLAIN (ddl, verbose) ALTER TABLE t.test DROP pi; │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 106, ColumnID: 4, IndexID: 5} │ │ rule: "dependents removed before index" │ │ + │ ├── • 1 element transitioning toward ABSENT + │ │ │ + │ │ └── • PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 5 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_1_of_7 index 004496d3175e..d772a10165ed 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_1_of_7 @@ -13,6 +13,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase + │ + ├── • 2 elements transitioning toward PUBLIC + │ │ + │ ├── • Column:{DescID: 106, ColumnID: 3} + │ │ │ WRITE_ONLY → PUBLIC + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ rule: "column dependents exist before column becomes public" + │ │ + │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ ABSENT → PUBLIC │ ├── • 8 elements transitioning toward ABSENT │ │ @@ -79,26 +99,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; │ └── • skip PUBLIC → ABSENT operations │ rule: "skip index-column removal ops on index removal" │ - ├── • 2 elements transitioning toward PUBLIC - │ │ - │ ├── • Column:{DescID: 106, ColumnID: 3} - │ │ │ WRITE_ONLY → PUBLIC - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ rule: "column dependents exist before column becomes public" - │ │ - │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ ABSENT → PUBLIC - │ └── • 9 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_2_of_7 index 5f3f9104f38d..853124d947e3 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_2_of_7 @@ -14,6 +14,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 106, ColumnID: 3} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} @@ -70,26 +90,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 106, ColumnID: 3} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ ABSENT → PUBLIC - │ │ │ └── • 8 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_3_of_7 index e0606d4c2adc..ddca208de1ed 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_3_of_7 @@ -14,6 +14,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 106, ColumnID: 3} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} @@ -70,26 +90,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 106, ColumnID: 3} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ ABSENT → PUBLIC - │ │ │ └── • 8 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_4_of_7 index fe1c100821c1..3fbb9ff1946b 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_4_of_7 @@ -14,6 +14,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 106, ColumnID: 3} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} @@ -70,26 +90,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 106, ColumnID: 3} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ ABSENT → PUBLIC - │ │ │ └── • 8 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_5_of_7 index aff17316dc89..5f14c41d52a4 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_5_of_7 @@ -14,6 +14,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 106, ColumnID: 3} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 106, ColumnID: 3} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ ABSENT → PUBLIC - │ │ │ └── • 7 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_6_of_7 index 5f4247e79190..c28e13ac0914 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_6_of_7 @@ -14,6 +14,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 106, ColumnID: 3} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 106, ColumnID: 3} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ ABSENT → PUBLIC - │ │ │ └── • 7 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_7_of_7 index 0dc89d7e443f..54d780f503ce 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_unique_index.rollback_7_of_7 @@ -14,6 +14,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • Column:{DescID: 106, ColumnID: 3} + │ │ │ │ WRITE_ONLY → PUBLIC + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} + │ │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} + │ │ │ rule: "column dependents exist before column becomes public" + │ │ │ + │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} + │ │ ABSENT → PUBLIC + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106, IndexID: 4, ConstraintID: 5, TemporaryIndexID: 5, SourceIndexID: 1} @@ -58,26 +78,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • Column:{DescID: 106, ColumnID: 3} - │ │ │ │ WRITE_ONLY → PUBLIC - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC ColumnDefaultExpression:{DescID: 106, ColumnID: 3} - │ │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1} - │ │ │ rule: "column dependents exist before column becomes public" - │ │ │ - │ │ └── • ColumnName:{DescID: 106, Name: pi, ColumnID: 3} - │ │ ABSENT → PUBLIC - │ │ │ └── • 7 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index index b41427f836b1..04f7ba90824b 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index @@ -10,6 +10,28 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ +│ ├── • 2 elements transitioning toward PUBLIC +│ │ │ +│ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} +│ │ │ ABSENT → BACKFILL_ONLY +│ │ │ +│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} +│ │ │ ABSENT → PUBLIC +│ │ │ +│ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} +│ │ rule: "index existence precedes index dependents" +│ │ +│ ├── • 2 elements transitioning toward TRANSIENT_ABSENT +│ │ │ +│ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} +│ │ │ ABSENT → DELETE_ONLY +│ │ │ +│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} +│ │ │ ABSENT → PUBLIC +│ │ │ +│ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} +│ │ rule: "temp index existence precedes index dependents" +│ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -33,28 +55,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ rule: "index no longer public before dependents" │ │ -│ ├── • 2 elements transitioning toward PUBLIC -│ │ │ -│ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} -│ │ │ ABSENT → BACKFILL_ONLY -│ │ │ -│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} -│ │ │ ABSENT → PUBLIC -│ │ │ -│ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} -│ │ rule: "index existence precedes index dependents" -│ │ -│ ├── • 2 elements transitioning toward TRANSIENT_ABSENT -│ │ │ -│ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} -│ │ │ ABSENT → DELETE_ONLY -│ │ │ -│ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} -│ │ │ ABSENT → PUBLIC -│ │ │ -│ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} -│ │ rule: "temp index existence precedes index dependents" -│ │ │ └── • 9 Mutation operations │ │ │ ├── • MakeDroppedNonPrimaryIndexDeleteAndWriteOnly @@ -276,6 +276,38 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "primary index swap" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ + │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ ├── • 8 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -335,38 +367,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ └── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ VALIDATED → DELETE_ONLY │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "primary index swap" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ - │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ └── • 9 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -417,6 +417,14 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 1 element transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ │ + │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ │ ├── • 2 elements transitioning toward ABSENT │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} @@ -434,14 +442,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j; │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ │ rule: "dependents removed before index" │ │ - │ ├── • 1 element transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ │ - │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ │ └── • 8 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_1_of_7 index 6f6b889b7440..9b1401870269 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_1_of_7 @@ -10,35 +10,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase - │ - ├── • 4 elements transitioning toward ABSENT - │ │ - │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ rule: "dependents removed before index" - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ DELETE_ONLY → ABSENT - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ - │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ PUBLIC → ABSENT - │ │ - │ └── • skip PUBLIC → ABSENT operations - │ rule: "skip index-column removal ops on index removal" │ ├── • 4 elements transitioning toward PUBLIC │ │ @@ -76,6 +47,35 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; │ └── • IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ ABSENT → PUBLIC │ + ├── • 4 elements transitioning toward ABSENT + │ │ + │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ rule: "dependents removed before index" + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ DELETE_ONLY → ABSENT + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ + │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ PUBLIC → ABSENT + │ │ + │ └── • skip PUBLIC → ABSENT operations + │ rule: "skip index-column removal ops on index removal" + │ └── • 11 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_2_of_7 index 82e4260ba635..4deb830f13a3 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_2_of_7 @@ -11,32 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -73,6 +47,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_3_of_7 index 36bb4b14306e..6b6b69e52916 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_3_of_7 @@ -11,32 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -73,6 +47,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_4_of_7 index 6c3b6617fb3c..0888536fa528 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_4_of_7 @@ -11,32 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ DELETE_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -73,6 +47,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ DELETE_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 10 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_5_of_7 index bf419182fc97..e006d5b5a1e0 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_5_of_7 @@ -11,26 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -67,6 +47,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_6_of_7 index c3973d89c23d..96bda0fc1209 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_6_of_7 @@ -11,26 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -67,6 +47,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_7_of_7 index b117b12c35da..b8f616d4a377 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_with_index.rollback_7_of_7 @@ -11,26 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ ├── • 4 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -67,6 +47,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_j_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ └── • 9 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_1_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_1_of_7 index 19a74f8b3ddb..800f2b32570c 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_1_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_1_of_7 @@ -11,35 +11,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; └── • PostCommitNonRevertiblePhase │ └── • Stage 1 of 1 in PostCommitNonRevertiblePhase - │ - ├── • 4 elements transitioning toward ABSENT - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ PUBLIC → ABSENT - │ │ │ - │ │ └── • skip PUBLIC → ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ - │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ - │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ rule: "dependents removed before index" - │ │ - │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ DELETE_ONLY → ABSENT - │ │ - │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ rule: "dependents removed before index" │ ├── • 8 elements transitioning toward PUBLIC │ │ @@ -131,6 +102,35 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 1 of 7; │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ ABSENT → PUBLIC │ + ├── • 4 elements transitioning toward ABSENT + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ PUBLIC → ABSENT + │ │ │ + │ │ └── • skip PUBLIC → ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ + │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ + │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ rule: "dependents removed before index" + │ │ + │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ DELETE_ONLY → ABSENT + │ │ + │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ rule: "dependents removed before index" + │ └── • 17 Mutation operations │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_2_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_2_of_7 index 47440d25bde8..edbfc1db5d4b 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_2_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_2_of_7 @@ -12,32 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -128,6 +102,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 2 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 16 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_3_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_3_of_7 index 436f63476a4e..346b3959bf6c 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_3_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_3_of_7 @@ -12,32 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ BACKFILL_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -128,6 +102,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 3 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ BACKFILL_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 16 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_4_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_4_of_7 index ccccecda5617..1de7929d523d 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_4_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_4_of_7 @@ -12,32 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ DELETE_ONLY → ABSENT - │ │ │ │ - │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "dependents removed before index" - │ │ │ │ - │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -128,6 +102,32 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 4 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ DELETE_ONLY → ABSENT + │ │ │ │ + │ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "dependents removed before index" + │ │ │ │ + │ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 16 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_5_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_5_of_7 index 59017a11e83e..e7880cba75e0 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_5_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_5_of_7 @@ -12,26 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -122,6 +102,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 5 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 15 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_6_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_6_of_7 index e35e72f2c47f..fe79e3805c63 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_6_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_6_of_7 @@ -12,26 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ MERGE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -122,6 +102,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 6 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ MERGE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 15 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_7_of_7 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_7_of_7 index c386157dc870..a0933fcf6761 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_7_of_7 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.rollback_7_of_7 @@ -12,26 +12,6 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ ├── • Stage 1 of 2 in PostCommitNonRevertiblePhase │ │ - │ ├── • 4 elements transitioning toward ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → DELETE_ONLY - │ │ │ ├── • 8 elements transitioning toward PUBLIC │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -122,6 +102,26 @@ EXPLAIN (ddl, verbose) rollback at post-commit stage 7 of 7; │ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ ABSENT → PUBLIC │ │ + │ ├── • 4 elements transitioning toward ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → DELETE_ONLY + │ │ │ └── • 15 Mutation operations │ │ │ ├── • SetColumnName diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_1_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_1_of_2 index f35c6c887d52..2b666c0c5ffa 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_1_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_1_of_2 @@ -10,38 +10,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 6 elements transitioning toward ABSENT -│ │ │ -│ │ ├── • Column:{DescID: 104, ColumnID: 2} -│ │ │ PUBLIC → WRITE_ONLY -│ │ │ -│ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} -│ │ │ │ PUBLIC → ABSENT -│ │ │ │ -│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} -│ │ │ rule: "column no longer public before dependents" -│ │ │ -│ │ ├── • Column:{DescID: 104, ColumnID: 4} -│ │ │ │ PUBLIC → WRITE_ONLY -│ │ │ │ -│ │ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} -│ │ │ rule: "secondary indexes containing column as key reach write-only before column" -│ │ │ -│ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} -│ │ │ │ PUBLIC → ABSENT -│ │ │ │ -│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 4} -│ │ │ rule: "column no longer public before dependents" -│ │ │ -│ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} -│ │ │ PUBLIC → VALIDATED -│ │ │ -│ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} -│ │ │ PUBLIC → ABSENT -│ │ │ -│ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} -│ │ rule: "index no longer public before dependents" -│ │ │ ├── • 3 elements transitioning toward PUBLIC │ │ │ │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} @@ -76,6 +44,38 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} │ │ rule: "temp index existence precedes index dependents" │ │ +│ ├── • 6 elements transitioning toward ABSENT +│ │ │ +│ │ ├── • Column:{DescID: 104, ColumnID: 2} +│ │ │ PUBLIC → WRITE_ONLY +│ │ │ +│ │ ├── • ColumnName:{DescID: 104, Name: j, ColumnID: 2} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 2} +│ │ │ rule: "column no longer public before dependents" +│ │ │ +│ │ ├── • Column:{DescID: 104, ColumnID: 4} +│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ +│ │ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} +│ │ │ rule: "secondary indexes containing column as key reach write-only before column" +│ │ │ +│ │ ├── • ColumnName:{DescID: 104, Name: crdb_internal_idx_expr, ColumnID: 4} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104, ColumnID: 4} +│ │ │ rule: "column no longer public before dependents" +│ │ │ +│ │ ├── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} +│ │ │ PUBLIC → VALIDATED +│ │ │ +│ │ └── • IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} +│ │ │ PUBLIC → ABSENT +│ │ │ +│ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} +│ │ rule: "index no longer public before dependents" +│ │ │ └── • 14 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteAndWriteOnly @@ -341,6 +341,47 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "primary index swap" + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ rule: "index named right before index becomes public" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 3 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ + │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ rule: "skip index-column removal ops on index removal" + │ │ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 2} @@ -421,47 +462,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • SecondaryIndex:{DescID: 104, IndexID: 2, ConstraintID: 0} │ │ VALIDATED → DELETE_ONLY │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "primary index swap" - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ rule: "index named right before index becomes public" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 3} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 3 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ - │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ rule: "skip index-column removal ops on index removal" - │ │ │ └── • 10 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -516,6 +516,17 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 1 element transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ │ + │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 4} @@ -558,17 +569,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN j CASCADE; │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ rule: "dependents removed before index" │ │ - │ ├── • 1 element transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ │ - │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ │ └── • 9 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 index 2d856b577e53..965b66031999 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 @@ -214,6 +214,38 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ ├── • Stage 1 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 2 elements transitioning toward PUBLIC + │ │ │ + │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ │ │ VALIDATED → PUBLIC + │ │ │ │ + │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} + │ │ │ │ rule: "primary index swap" + │ │ │ │ + │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} + │ │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ │ + │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ rule: "index dependents exist before index becomes public" + │ │ │ rule: "index named right before index becomes public" + │ │ │ + │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} + │ │ │ ABSENT → PUBLIC + │ │ │ + │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} + │ │ rule: "index existence precedes index dependents" + │ │ + │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ │ PUBLIC → TRANSIENT_ABSENT + │ │ │ │ + │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations + │ │ │ rule: "skip index-column removal ops on index removal" + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY + │ │ │ ├── • 14 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 3} @@ -318,38 +350,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ │ └── • skip PUBLIC → ABSENT operations │ │ rule: "skip index-column removal ops on index removal" │ │ - │ ├── • 2 elements transitioning toward PUBLIC - │ │ │ - │ │ ├── • PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ │ │ VALIDATED → PUBLIC - │ │ │ │ - │ │ │ ├── • SameStagePrecedence dependency from VALIDATED PrimaryIndex:{DescID: 104, IndexID: 1, ConstraintID: 1} - │ │ │ │ rule: "primary index swap" - │ │ │ │ - │ │ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 3} - │ │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ │ - │ │ │ └── • SameStagePrecedence dependency from PUBLIC IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ rule: "index dependents exist before index becomes public" - │ │ │ rule: "index named right before index becomes public" - │ │ │ - │ │ └── • IndexName:{DescID: 104, Name: t_pkey, IndexID: 3} - │ │ │ ABSENT → PUBLIC - │ │ │ - │ │ └── • Precedence dependency from BACKFILL_ONLY PrimaryIndex:{DescID: 104, IndexID: 3, ConstraintID: 2, TemporaryIndexID: 4, SourceIndexID: 1} - │ │ rule: "index existence precedes index dependents" - │ │ - │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ ├── • IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ │ PUBLIC → TRANSIENT_ABSENT - │ │ │ │ - │ │ │ └── • skip PUBLIC → TRANSIENT_ABSENT operations - │ │ │ rule: "skip index-column removal ops on index removal" - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ WRITE_ONLY → TRANSIENT_DELETE_ONLY - │ │ │ └── • 12 Mutation operations │ │ │ ├── • MakeDroppedColumnDeleteOnly @@ -414,6 +414,17 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ ├── • Stage 2 of 3 in PostCommitNonRevertiblePhase │ │ + │ ├── • 1 element transitioning toward TRANSIENT_ABSENT + │ │ │ + │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} + │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT + │ │ │ + │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} + │ │ │ rule: "dependents removed before index" + │ │ │ + │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} + │ │ rule: "dependents removed before index" + │ │ │ ├── • 4 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104, ColumnID: 4} @@ -456,17 +467,6 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 104, Name: t_expr_k_idx, IndexID: 2} │ │ rule: "dependents removed before index" │ │ - │ ├── • 1 element transitioning toward TRANSIENT_ABSENT - │ │ │ - │ │ └── • TemporaryIndex:{DescID: 104, IndexID: 4, ConstraintID: 3, SourceIndexID: 1} - │ │ │ TRANSIENT_DELETE_ONLY → TRANSIENT_ABSENT - │ │ │ - │ │ ├── • Precedence dependency from TRANSIENT_ABSENT IndexColumn:{DescID: 104, ColumnID: 1, IndexID: 4} - │ │ │ rule: "dependents removed before index" - │ │ │ - │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 104, ColumnID: 3, IndexID: 4} - │ │ rule: "dependents removed before index" - │ │ │ └── • 9 Mutation operations │ │ │ ├── • MakeDroppedIndexDeleteOnly From 30d124d77a3969148ecdf1c464453b5fea8876bd Mon Sep 17 00:00:00 2001 From: Chengxiong Ruan Date: Tue, 16 Aug 2022 22:39:54 -0400 Subject: [PATCH 6/9] sql: udf logic tests not to skip dropping databases Now that we support drop functions in legacy schema changer and declarative schema changer falls back to legacy when seeing any function descriptor, we can move udf logic tests back to normal configs. Release note: None. Release justification: test only change. --- pkg/BUILD.bazel | 6 -- .../tests/3node-tenant/generated_test.go | 7 ++ pkg/sql/distsql_physical_planner.go | 4 + pkg/sql/logictest/logic.go | 3 - .../logictest/logictestbase/logictestbase.go | 16 ---- pkg/sql/logictest/testdata/logic_test/udf | 17 ++-- .../tests/fakedist-disk/generated_test.go | 7 ++ .../tests/fakedist-vec-off/generated_test.go | 7 ++ .../tests/fakedist/generated_test.go | 7 ++ pkg/sql/logictest/tests/local-udf/BUILD.bazel | 28 ------ .../tests/local-udf/generated_test.go | 80 ----------------- .../tests/local-vec-off/generated_test.go | 7 ++ .../logictest/tests/local/generated_test.go | 7 ++ pkg/sql/opt/exec/execbuilder/testdata/udf | 2 +- .../execbuilder/tests/local-udf/BUILD.bazel | 29 ------ .../tests/local-udf/generated_test.go | 89 ------------------- .../execbuilder/tests/local/generated_test.go | 7 ++ 17 files changed, 63 insertions(+), 260 deletions(-) delete mode 100644 pkg/sql/logictest/tests/local-udf/BUILD.bazel delete mode 100644 pkg/sql/logictest/tests/local-udf/generated_test.go delete mode 100644 pkg/sql/opt/exec/execbuilder/tests/local-udf/BUILD.bazel delete mode 100644 pkg/sql/opt/exec/execbuilder/tests/local-udf/generated_test.go diff --git a/pkg/BUILD.bazel b/pkg/BUILD.bazel index c8320fc23196..238b77a13235 100644 --- a/pkg/BUILD.bazel +++ b/pkg/BUILD.bazel @@ -359,7 +359,6 @@ ALL_TESTS = [ "//pkg/sql/logictest/tests/fakedist:fakedist_test", "//pkg/sql/logictest/tests/local-mixed-21.2-22.1:local-mixed-21_2-22_1_test", "//pkg/sql/logictest/tests/local-mixed-22.1-22.2:local-mixed-22_1-22_2_test", - "//pkg/sql/logictest/tests/local-udf:local-udf_test", "//pkg/sql/logictest/tests/local-v1.1-at-v1.0-noupgrade:local-v1_1-at-v1_0-noupgrade_test", "//pkg/sql/logictest/tests/local-vec-off:local-vec-off_test", "//pkg/sql/logictest/tests/local:local_test", @@ -376,7 +375,6 @@ ALL_TESTS = [ "//pkg/sql/opt/exec/execbuilder/tests/fakedist-disk:fakedist-disk_test", "//pkg/sql/opt/exec/execbuilder/tests/fakedist-vec-off:fakedist-vec-off_test", "//pkg/sql/opt/exec/execbuilder/tests/fakedist:fakedist_test", - "//pkg/sql/opt/exec/execbuilder/tests/local-udf:local-udf_test", "//pkg/sql/opt/exec/execbuilder/tests/local-vec-off:local-vec-off_test", "//pkg/sql/opt/exec/execbuilder/tests/local:local_test", "//pkg/sql/opt/exec/execbuilder:execbuilder_test", @@ -1450,7 +1448,6 @@ GO_TARGETS = [ "//pkg/sql/logictest/tests/fakedist:fakedist_test", "//pkg/sql/logictest/tests/local-mixed-21.2-22.1:local-mixed-21_2-22_1_test", "//pkg/sql/logictest/tests/local-mixed-22.1-22.2:local-mixed-22_1-22_2_test", - "//pkg/sql/logictest/tests/local-udf:local-udf_test", "//pkg/sql/logictest/tests/local-v1.1-at-v1.0-noupgrade:local-v1_1-at-v1_0-noupgrade_test", "//pkg/sql/logictest/tests/local-vec-off:local-vec-off_test", "//pkg/sql/logictest/tests/local:local_test", @@ -1476,7 +1473,6 @@ GO_TARGETS = [ "//pkg/sql/opt/exec/execbuilder/tests/fakedist-disk:fakedist-disk_test", "//pkg/sql/opt/exec/execbuilder/tests/fakedist-vec-off:fakedist-vec-off_test", "//pkg/sql/opt/exec/execbuilder/tests/fakedist:fakedist_test", - "//pkg/sql/opt/exec/execbuilder/tests/local-udf:local-udf_test", "//pkg/sql/opt/exec/execbuilder/tests/local-vec-off:local-vec-off_test", "//pkg/sql/opt/exec/execbuilder/tests/local:local_test", "//pkg/sql/opt/exec/execbuilder:execbuilder", @@ -2565,7 +2561,6 @@ GET_X_DATA_TARGETS = [ "//pkg/sql/logictest/tests/local:get_x_data", "//pkg/sql/logictest/tests/local-mixed-21.2-22.1:get_x_data", "//pkg/sql/logictest/tests/local-mixed-22.1-22.2:get_x_data", - "//pkg/sql/logictest/tests/local-udf:get_x_data", "//pkg/sql/logictest/tests/local-v1.1-at-v1.0-noupgrade:get_x_data", "//pkg/sql/logictest/tests/local-vec-off:get_x_data", "//pkg/sql/logictest/tests/multiregion-9node-3region-3azs:get_x_data", @@ -2586,7 +2581,6 @@ GET_X_DATA_TARGETS = [ "//pkg/sql/opt/exec/execbuilder/tests/fakedist-disk:get_x_data", "//pkg/sql/opt/exec/execbuilder/tests/fakedist-vec-off:get_x_data", "//pkg/sql/opt/exec/execbuilder/tests/local:get_x_data", - "//pkg/sql/opt/exec/execbuilder/tests/local-udf:get_x_data", "//pkg/sql/opt/exec/execbuilder/tests/local-vec-off:get_x_data", "//pkg/sql/opt/exec/explain:get_x_data", "//pkg/sql/opt/idxconstraint:get_x_data", diff --git a/pkg/ccl/logictestccl/tests/3node-tenant/generated_test.go b/pkg/ccl/logictestccl/tests/3node-tenant/generated_test.go index 0406dbb84292..eb18c16bbe79 100644 --- a/pkg/ccl/logictestccl/tests/3node-tenant/generated_test.go +++ b/pkg/ccl/logictestccl/tests/3node-tenant/generated_test.go @@ -1926,6 +1926,13 @@ func TestTenantLogic_typing( runLogicTest(t, "typing") } +func TestTenantLogic_udf( + t *testing.T, +) { + defer leaktest.AfterTest(t)() + runLogicTest(t, "udf") +} + func TestTenantLogic_union( t *testing.T, ) { diff --git a/pkg/sql/distsql_physical_planner.go b/pkg/sql/distsql_physical_planner.go index e6fc9287070d..306432298241 100644 --- a/pkg/sql/distsql_physical_planner.go +++ b/pkg/sql/distsql_physical_planner.go @@ -270,6 +270,10 @@ func (v *distSQLExprCheckVisitor) VisitPre(expr tree.Expr) (recurse bool, newExp v.err = newQueryNotSupportedErrorf("function %s cannot be executed with distsql", t) return false, expr } + case *tree.RoutineExpr: + // TODO(86310): enable UDFs in DistSQL. + v.err = newQueryNotSupportedErrorf("user-defined routine %s cannot be executed with distsql", t) + return false, expr case *tree.DOid: v.err = newQueryNotSupportedError("OID expressions are not supported by distsql") return false, expr diff --git a/pkg/sql/logictest/logic.go b/pkg/sql/logictest/logic.go index 65a961947ca1..b70f810deae0 100644 --- a/pkg/sql/logictest/logic.go +++ b/pkg/sql/logictest/logic.go @@ -3644,9 +3644,6 @@ SELECT encode(descriptor, 'hex') AS descriptor } func (t *logicTest) maybeDropDatabases() error { - if t.cfg.SkipDropDatabases { - return nil - } var dbNames pq.StringArray if err := t.db.QueryRow( `SELECT array_agg(database_name) FROM [SHOW DATABASES] WHERE database_name NOT IN ('system', 'postgres')`, diff --git a/pkg/sql/logictest/logictestbase/logictestbase.go b/pkg/sql/logictest/logictestbase/logictestbase.go index 202b9dcb9967..cf8808cfe969 100644 --- a/pkg/sql/logictest/logictestbase/logictestbase.go +++ b/pkg/sql/logictest/logictestbase/logictestbase.go @@ -82,12 +82,6 @@ type TestClusterConfig struct { // disableLocalityOptimizedSearch disables the cluster setting // locality_optimized_partitioned_index_scan, which is enabled by default. DisableLocalityOptimizedSearch bool - // SkipDropDatabases allows a configuration to skip dropping of the database. - // This exists to enable development while DROP DATABASE for a feature is - // broken. - // - // TODO(ajwerner,chengxiong-ruan): Remove this before 22.2 is released. - SkipDropDatabases bool // DeclarativeCorpusCollection enables support for collecting corpuses // for the declarative schema changer. DeclarativeCorpusCollection bool @@ -468,16 +462,6 @@ var LogicTestConfigs = []TestClusterConfig{ DisableUpgrade: true, DeclarativeCorpusCollection: true, }, - { - Name: "local-udf", - NumNodes: 1, - // local is the configuration where we run all tests which have bad - // interactions with the default test tenant. - DisableDefaultTestTenant: true, - // Set SkipDropDatabases to true for now to enable development on UDFs. - // TODO(ajwerner,chengxiong-ruan): Remove this before the 22.2 release. - SkipDropDatabases: true, - }, } // ConfigIdx is an index in the above slice. diff --git a/pkg/sql/logictest/testdata/logic_test/udf b/pkg/sql/logictest/testdata/logic_test/udf index a460330f9e7f..fa662480abe7 100644 --- a/pkg/sql/logictest/testdata/logic_test/udf +++ b/pkg/sql/logictest/testdata/logic_test/udf @@ -1,5 +1,3 @@ -# LogicTest: local-udf - statement ok CREATE TABLE ab ( a INT PRIMARY KEY, @@ -1222,8 +1220,9 @@ query TT $test_alter_sc_f_test_sc ) ) -SELECT fn->'id', fn->'parentSchemaId' - FROM fns; +SELECT fn->>'id' AS id, fn->'parentSchemaId' + FROM fns + ORDER BY id; ---- 170 105 171 105 @@ -1254,8 +1253,9 @@ query TT $test_alter_sc_f_test_sc ) ) -SELECT fn->'id', fn->'parentSchemaId' - FROM fns; +SELECT fn->>'id' AS id, fn->'parentSchemaId' + FROM fns + ORDER BY id; ---- 170 105 171 105 @@ -1303,8 +1303,9 @@ query TT $test_alter_sc_f_test_sc ) ) -SELECT fn->'id', fn->'parentSchemaId' - FROM fns; +SELECT fn->>'id' AS id, fn->'parentSchemaId' + FROM fns + ORDER BY id; ---- 170 105 171 172 diff --git a/pkg/sql/logictest/tests/fakedist-disk/generated_test.go b/pkg/sql/logictest/tests/fakedist-disk/generated_test.go index e1763831d1f9..2479f5054d10 100644 --- a/pkg/sql/logictest/tests/fakedist-disk/generated_test.go +++ b/pkg/sql/logictest/tests/fakedist-disk/generated_test.go @@ -1913,6 +1913,13 @@ func TestLogic_typing( runLogicTest(t, "typing") } +func TestLogic_udf( + t *testing.T, +) { + defer leaktest.AfterTest(t)() + runLogicTest(t, "udf") +} + func TestLogic_union( t *testing.T, ) { diff --git a/pkg/sql/logictest/tests/fakedist-vec-off/generated_test.go b/pkg/sql/logictest/tests/fakedist-vec-off/generated_test.go index 07978fc2c415..ed01a5772178 100644 --- a/pkg/sql/logictest/tests/fakedist-vec-off/generated_test.go +++ b/pkg/sql/logictest/tests/fakedist-vec-off/generated_test.go @@ -1913,6 +1913,13 @@ func TestLogic_typing( runLogicTest(t, "typing") } +func TestLogic_udf( + t *testing.T, +) { + defer leaktest.AfterTest(t)() + runLogicTest(t, "udf") +} + func TestLogic_union( t *testing.T, ) { diff --git a/pkg/sql/logictest/tests/fakedist/generated_test.go b/pkg/sql/logictest/tests/fakedist/generated_test.go index da4a2422fc46..4906e5585551 100644 --- a/pkg/sql/logictest/tests/fakedist/generated_test.go +++ b/pkg/sql/logictest/tests/fakedist/generated_test.go @@ -1927,6 +1927,13 @@ func TestLogic_typing( runLogicTest(t, "typing") } +func TestLogic_udf( + t *testing.T, +) { + defer leaktest.AfterTest(t)() + runLogicTest(t, "udf") +} + func TestLogic_union( t *testing.T, ) { diff --git a/pkg/sql/logictest/tests/local-udf/BUILD.bazel b/pkg/sql/logictest/tests/local-udf/BUILD.bazel deleted file mode 100644 index cfc125a38078..000000000000 --- a/pkg/sql/logictest/tests/local-udf/BUILD.bazel +++ /dev/null @@ -1,28 +0,0 @@ -load("//build/bazelutil/unused_checker:unused.bzl", "get_x_data") -load("@io_bazel_rules_go//go:def.bzl", "go_test") - -go_test( - name = "local-udf_test", - size = "enormous", - srcs = ["generated_test.go"], - data = [ - "//c-deps:libgeos", # keep - "//pkg/sql/logictest:testdata", # keep - ], - shard_count = 1, - tags = ["cpu:1"], - deps = [ - "//pkg/build/bazel", - "//pkg/security/securityassets", - "//pkg/security/securitytest", - "//pkg/server", - "//pkg/sql/logictest", - "//pkg/testutils/serverutils", - "//pkg/testutils/skip", - "//pkg/testutils/testcluster", - "//pkg/util/leaktest", - "//pkg/util/randutil", - ], -) - -get_x_data(name = "get_x_data") diff --git a/pkg/sql/logictest/tests/local-udf/generated_test.go b/pkg/sql/logictest/tests/local-udf/generated_test.go deleted file mode 100644 index 1b29026394d2..000000000000 --- a/pkg/sql/logictest/tests/local-udf/generated_test.go +++ /dev/null @@ -1,80 +0,0 @@ -// Copyright 2022 The Cockroach Authors. -// -// Use of this software is governed by the Business Source License -// included in the file licenses/BSL.txt. -// -// As of the Change Date specified in that file, in accordance with -// the Business Source License, use of this software will be governed -// by the Apache License, Version 2.0, included in the file -// licenses/APL.txt. - -// Code generated by generate-logictest, DO NOT EDIT. - -package testlocal_udf - -import ( - "os" - "path/filepath" - "testing" - - "github.com/cockroachdb/cockroach/pkg/build/bazel" - "github.com/cockroachdb/cockroach/pkg/security/securityassets" - "github.com/cockroachdb/cockroach/pkg/security/securitytest" - "github.com/cockroachdb/cockroach/pkg/server" - "github.com/cockroachdb/cockroach/pkg/sql/logictest" - "github.com/cockroachdb/cockroach/pkg/testutils/serverutils" - "github.com/cockroachdb/cockroach/pkg/testutils/skip" - "github.com/cockroachdb/cockroach/pkg/testutils/testcluster" - "github.com/cockroachdb/cockroach/pkg/util/leaktest" - "github.com/cockroachdb/cockroach/pkg/util/randutil" -) - -const configIdx = 20 - -var logicTestDir string - -func init() { - if bazel.BuiltWithBazel() { - var err error - logicTestDir, err = bazel.Runfile("pkg/sql/logictest/testdata/logic_test") - if err != nil { - panic(err) - } - } else { - logicTestDir = "../../../../sql/logictest/testdata/logic_test" - } -} - -func TestMain(m *testing.M) { - securityassets.SetLoader(securitytest.EmbeddedAssets) - randutil.SeedForTests() - serverutils.InitTestServerFactory(server.TestServerFactory) - serverutils.InitTestClusterFactory(testcluster.TestClusterFactory) - os.Exit(m.Run()) -} - -func runLogicTest(t *testing.T, file string) { - skip.UnderDeadlock(t, "times out and/or hangs") - logictest.RunLogicTest(t, logictest.TestServerArgs{}, configIdx, filepath.Join(logicTestDir, file)) -} - -// TestLogic_tmp runs any tests that are prefixed with "_", in which a dedicated -// test is not generated for. This allows developers to create and run temporary -// test files that are not checked into the repository, without repeatedly -// regenerating and reverting changes to this file, generated_test.go. -// -// TODO(mgartner): Add file filtering so that individual files can be run, -// instead of all files with the "_" prefix. -func TestLogic_tmp(t *testing.T) { - defer leaktest.AfterTest(t)() - var glob string - glob = filepath.Join(logicTestDir, "_*") - logictest.RunLogicTests(t, logictest.TestServerArgs{}, configIdx, glob) -} - -func TestLogic_udf( - t *testing.T, -) { - defer leaktest.AfterTest(t)() - runLogicTest(t, "udf") -} diff --git a/pkg/sql/logictest/tests/local-vec-off/generated_test.go b/pkg/sql/logictest/tests/local-vec-off/generated_test.go index 3879a14d2f4f..f6791f2bd8c9 100644 --- a/pkg/sql/logictest/tests/local-vec-off/generated_test.go +++ b/pkg/sql/logictest/tests/local-vec-off/generated_test.go @@ -1920,6 +1920,13 @@ func TestLogic_typing( runLogicTest(t, "typing") } +func TestLogic_udf( + t *testing.T, +) { + defer leaktest.AfterTest(t)() + runLogicTest(t, "udf") +} + func TestLogic_union( t *testing.T, ) { diff --git a/pkg/sql/logictest/tests/local/generated_test.go b/pkg/sql/logictest/tests/local/generated_test.go index d66e4286fcce..4b225f118be6 100644 --- a/pkg/sql/logictest/tests/local/generated_test.go +++ b/pkg/sql/logictest/tests/local/generated_test.go @@ -2074,6 +2074,13 @@ func TestLogic_typing( runLogicTest(t, "typing") } +func TestLogic_udf( + t *testing.T, +) { + defer leaktest.AfterTest(t)() + runLogicTest(t, "udf") +} + func TestLogic_union( t *testing.T, ) { diff --git a/pkg/sql/opt/exec/execbuilder/testdata/udf b/pkg/sql/opt/exec/execbuilder/testdata/udf index 4d855af35967..ba6cc4827b5d 100644 --- a/pkg/sql/opt/exec/execbuilder/testdata/udf +++ b/pkg/sql/opt/exec/execbuilder/testdata/udf @@ -1,4 +1,4 @@ -# LogicTest: local-udf +# LogicTest: local statement ok CREATE TABLE t ( diff --git a/pkg/sql/opt/exec/execbuilder/tests/local-udf/BUILD.bazel b/pkg/sql/opt/exec/execbuilder/tests/local-udf/BUILD.bazel deleted file mode 100644 index 017113b56bf9..000000000000 --- a/pkg/sql/opt/exec/execbuilder/tests/local-udf/BUILD.bazel +++ /dev/null @@ -1,29 +0,0 @@ -load("//build/bazelutil/unused_checker:unused.bzl", "get_x_data") -load("@io_bazel_rules_go//go:def.bzl", "go_test") - -go_test( - name = "local-udf_test", - size = "enormous", - srcs = ["generated_test.go"], - data = [ - "//c-deps:libgeos", # keep - "//pkg/sql/opt/exec/execbuilder:testdata", # keep - ], - shard_count = 1, - tags = ["cpu:1"], - deps = [ - "//pkg/build/bazel", - "//pkg/security/securityassets", - "//pkg/security/securitytest", - "//pkg/server", - "//pkg/sql", - "//pkg/sql/logictest", - "//pkg/testutils/serverutils", - "//pkg/testutils/skip", - "//pkg/testutils/testcluster", - "//pkg/util/leaktest", - "//pkg/util/randutil", - ], -) - -get_x_data(name = "get_x_data") diff --git a/pkg/sql/opt/exec/execbuilder/tests/local-udf/generated_test.go b/pkg/sql/opt/exec/execbuilder/tests/local-udf/generated_test.go deleted file mode 100644 index 491c01a326c3..000000000000 --- a/pkg/sql/opt/exec/execbuilder/tests/local-udf/generated_test.go +++ /dev/null @@ -1,89 +0,0 @@ -// Copyright 2022 The Cockroach Authors. -// -// Use of this software is governed by the Business Source License -// included in the file licenses/BSL.txt. -// -// As of the Change Date specified in that file, in accordance with -// the Business Source License, use of this software will be governed -// by the Apache License, Version 2.0, included in the file -// licenses/APL.txt. - -// Code generated by generate-logictest, DO NOT EDIT. - -package testlocal_udf - -import ( - "os" - "path/filepath" - "testing" - - "github.com/cockroachdb/cockroach/pkg/build/bazel" - "github.com/cockroachdb/cockroach/pkg/security/securityassets" - "github.com/cockroachdb/cockroach/pkg/security/securitytest" - "github.com/cockroachdb/cockroach/pkg/server" - "github.com/cockroachdb/cockroach/pkg/sql" - "github.com/cockroachdb/cockroach/pkg/sql/logictest" - "github.com/cockroachdb/cockroach/pkg/testutils/serverutils" - "github.com/cockroachdb/cockroach/pkg/testutils/skip" - "github.com/cockroachdb/cockroach/pkg/testutils/testcluster" - "github.com/cockroachdb/cockroach/pkg/util/leaktest" - "github.com/cockroachdb/cockroach/pkg/util/randutil" -) - -const configIdx = 20 - -var execBuildLogicTestDir string - -func init() { - if bazel.BuiltWithBazel() { - var err error - execBuildLogicTestDir, err = bazel.Runfile("pkg/sql/opt/exec/execbuilder/testdata") - if err != nil { - panic(err) - } - } else { - execBuildLogicTestDir = "../../../../../../sql/opt/exec/execbuilder/testdata" - } -} - -func TestMain(m *testing.M) { - securityassets.SetLoader(securitytest.EmbeddedAssets) - randutil.SeedForTests() - serverutils.InitTestServerFactory(server.TestServerFactory) - serverutils.InitTestClusterFactory(testcluster.TestClusterFactory) - os.Exit(m.Run()) -} - -func runExecBuildLogicTest(t *testing.T, file string) { - defer sql.TestingOverrideExplainEnvVersion("CockroachDB execbuilder test version")() - skip.UnderDeadlock(t, "times out and/or hangs") - serverArgs := logictest.TestServerArgs{ - DisableWorkmemRandomization: true, - ForceProductionValues: true, - } - logictest.RunLogicTest(t, serverArgs, configIdx, filepath.Join(execBuildLogicTestDir, file)) -} - -// TestLogic_tmp runs any tests that are prefixed with "_", in which a dedicated -// test is not generated for. This allows developers to create and run temporary -// test files that are not checked into the repository, without repeatedly -// regenerating and reverting changes to this file, generated_test.go. -// -// TODO(mgartner): Add file filtering so that individual files can be run, -// instead of all files with the "_" prefix. -func TestLogic_tmp(t *testing.T) { - defer leaktest.AfterTest(t)() - var glob string - glob = filepath.Join(execBuildLogicTestDir, "_*") - serverArgs := logictest.TestServerArgs{ - DisableWorkmemRandomization: true, - } - logictest.RunLogicTests(t, serverArgs, configIdx, glob) -} - -func TestExecBuild_udf( - t *testing.T, -) { - defer leaktest.AfterTest(t)() - runExecBuildLogicTest(t, "udf") -} diff --git a/pkg/sql/opt/exec/execbuilder/tests/local/generated_test.go b/pkg/sql/opt/exec/execbuilder/tests/local/generated_test.go index 349ee1d25a79..923f7fdbf574 100644 --- a/pkg/sql/opt/exec/execbuilder/tests/local/generated_test.go +++ b/pkg/sql/opt/exec/execbuilder/tests/local/generated_test.go @@ -536,6 +536,13 @@ func TestExecBuild_tuple( runExecBuildLogicTest(t, "tuple") } +func TestExecBuild_udf( + t *testing.T, +) { + defer leaktest.AfterTest(t)() + runExecBuildLogicTest(t, "udf") +} + func TestExecBuild_union( t *testing.T, ) { From 70e681395674a31e889555a896941e57b6a6078f Mon Sep 17 00:00:00 2001 From: richardjcai Date: Tue, 16 Aug 2022 12:14:06 -0400 Subject: [PATCH 7/9] sql: remove super regions version and gates Release justification: Only removing old version. Release note: None --- pkg/BUILD.bazel | 3 - pkg/clusterversion/cockroach_versions.go | 6 -- pkg/clusterversion/key_string.go | 67 ++++++++-------- pkg/sql/alter_database.go | 11 --- .../logic_test/super_regions_mixed_version | 10 --- .../tests/local-mixed-21.2-22.1/BUILD.bazel | 28 ------- .../local-mixed-21.2-22.1/generated_test.go | 80 ------------------- 7 files changed, 33 insertions(+), 172 deletions(-) delete mode 100644 pkg/sql/logictest/testdata/logic_test/super_regions_mixed_version delete mode 100644 pkg/sql/logictest/tests/local-mixed-21.2-22.1/BUILD.bazel delete mode 100644 pkg/sql/logictest/tests/local-mixed-21.2-22.1/generated_test.go diff --git a/pkg/BUILD.bazel b/pkg/BUILD.bazel index c8320fc23196..80a83151f32c 100644 --- a/pkg/BUILD.bazel +++ b/pkg/BUILD.bazel @@ -357,7 +357,6 @@ ALL_TESTS = [ "//pkg/sql/logictest/tests/fakedist-disk:fakedist-disk_test", "//pkg/sql/logictest/tests/fakedist-vec-off:fakedist-vec-off_test", "//pkg/sql/logictest/tests/fakedist:fakedist_test", - "//pkg/sql/logictest/tests/local-mixed-21.2-22.1:local-mixed-21_2-22_1_test", "//pkg/sql/logictest/tests/local-mixed-22.1-22.2:local-mixed-22_1-22_2_test", "//pkg/sql/logictest/tests/local-udf:local-udf_test", "//pkg/sql/logictest/tests/local-v1.1-at-v1.0-noupgrade:local-v1_1-at-v1_0-noupgrade_test", @@ -1448,7 +1447,6 @@ GO_TARGETS = [ "//pkg/sql/logictest/tests/fakedist-disk:fakedist-disk_test", "//pkg/sql/logictest/tests/fakedist-vec-off:fakedist-vec-off_test", "//pkg/sql/logictest/tests/fakedist:fakedist_test", - "//pkg/sql/logictest/tests/local-mixed-21.2-22.1:local-mixed-21_2-22_1_test", "//pkg/sql/logictest/tests/local-mixed-22.1-22.2:local-mixed-22_1-22_2_test", "//pkg/sql/logictest/tests/local-udf:local-udf_test", "//pkg/sql/logictest/tests/local-v1.1-at-v1.0-noupgrade:local-v1_1-at-v1_0-noupgrade_test", @@ -2563,7 +2561,6 @@ GET_X_DATA_TARGETS = [ "//pkg/sql/logictest/tests/fakedist-disk:get_x_data", "//pkg/sql/logictest/tests/fakedist-vec-off:get_x_data", "//pkg/sql/logictest/tests/local:get_x_data", - "//pkg/sql/logictest/tests/local-mixed-21.2-22.1:get_x_data", "//pkg/sql/logictest/tests/local-mixed-22.1-22.2:get_x_data", "//pkg/sql/logictest/tests/local-udf:get_x_data", "//pkg/sql/logictest/tests/local-v1.1-at-v1.0-noupgrade:get_x_data", diff --git a/pkg/clusterversion/cockroach_versions.go b/pkg/clusterversion/cockroach_versions.go index bdf601eb613f..7bafd825f66d 100644 --- a/pkg/clusterversion/cockroach_versions.go +++ b/pkg/clusterversion/cockroach_versions.go @@ -205,8 +205,6 @@ const ( // AutoStatsTableSettings is the version where we allow auto stats related // table settings. AutoStatsTableSettings - // SuperRegions enables the usage on super regions. - SuperRegions // EnableNewChangefeedOptions enables the usage of new changefeed options // such as end_time, initial_scan_only, and setting the value of initial_scan // to 'yes|no|only' @@ -406,10 +404,6 @@ var versionsSingleton = keyedVersions{ Key: AutoStatsTableSettings, Version: roachpb.Version{Major: 21, Minor: 2, Internal: 100}, }, - { - Key: SuperRegions, - Version: roachpb.Version{Major: 21, Minor: 2, Internal: 104}, - }, { Key: EnableNewChangefeedOptions, Version: roachpb.Version{Major: 21, Minor: 2, Internal: 106}, diff --git a/pkg/clusterversion/key_string.go b/pkg/clusterversion/key_string.go index bd20edcef8ea..0ca285cfc113 100644 --- a/pkg/clusterversion/key_string.go +++ b/pkg/clusterversion/key_string.go @@ -21,43 +21,42 @@ func _() { _ = x[EnableNewStoreRebalancer-10] _ = x[ClusterLocksVirtualTable-11] _ = x[AutoStatsTableSettings-12] - _ = x[SuperRegions-13] - _ = x[EnableNewChangefeedOptions-14] - _ = x[V22_1-15] - _ = x[Start22_2-16] - _ = x[LocalTimestamps-17] - _ = x[PebbleFormatSplitUserKeysMarkedCompacted-18] - _ = x[EnsurePebbleFormatVersionRangeKeys-19] - _ = x[EnablePebbleFormatVersionRangeKeys-20] - _ = x[TrigramInvertedIndexes-21] - _ = x[RemoveGrantPrivilege-22] - _ = x[MVCCRangeTombstones-23] - _ = x[UpgradeSequenceToBeReferencedByID-24] - _ = x[SampledStmtDiagReqs-25] - _ = x[AddSSTableTombstones-26] - _ = x[SystemPrivilegesTable-27] - _ = x[EnablePredicateProjectionChangefeed-28] - _ = x[AlterSystemSQLInstancesAddLocality-29] - _ = x[SystemExternalConnectionsTable-30] - _ = x[AlterSystemStatementStatisticsAddIndexRecommendations-31] - _ = x[RoleIDSequence-32] - _ = x[AddSystemUserIDColumn-33] - _ = x[SystemUsersIDColumnIsBackfilled-34] - _ = x[SetSystemUsersUserIDColumnNotNull-35] - _ = x[SQLSchemaTelemetryScheduledJobs-36] - _ = x[SchemaChangeSupportsCreateFunction-37] - _ = x[DeleteRequestReturnKey-38] - _ = x[PebbleFormatPrePebblev1Marked-39] - _ = x[RoleOptionsTableHasIDColumn-40] - _ = x[RoleOptionsIDColumnIsBackfilled-41] - _ = x[SetRoleOptionsUserIDColumnNotNull-42] - _ = x[UseDelRangeInGCJob-43] - _ = x[WaitedForDelRangeInGCJob-44] + _ = x[EnableNewChangefeedOptions-13] + _ = x[V22_1-14] + _ = x[Start22_2-15] + _ = x[LocalTimestamps-16] + _ = x[PebbleFormatSplitUserKeysMarkedCompacted-17] + _ = x[EnsurePebbleFormatVersionRangeKeys-18] + _ = x[EnablePebbleFormatVersionRangeKeys-19] + _ = x[TrigramInvertedIndexes-20] + _ = x[RemoveGrantPrivilege-21] + _ = x[MVCCRangeTombstones-22] + _ = x[UpgradeSequenceToBeReferencedByID-23] + _ = x[SampledStmtDiagReqs-24] + _ = x[AddSSTableTombstones-25] + _ = x[SystemPrivilegesTable-26] + _ = x[EnablePredicateProjectionChangefeed-27] + _ = x[AlterSystemSQLInstancesAddLocality-28] + _ = x[SystemExternalConnectionsTable-29] + _ = x[AlterSystemStatementStatisticsAddIndexRecommendations-30] + _ = x[RoleIDSequence-31] + _ = x[AddSystemUserIDColumn-32] + _ = x[SystemUsersIDColumnIsBackfilled-33] + _ = x[SetSystemUsersUserIDColumnNotNull-34] + _ = x[SQLSchemaTelemetryScheduledJobs-35] + _ = x[SchemaChangeSupportsCreateFunction-36] + _ = x[DeleteRequestReturnKey-37] + _ = x[PebbleFormatPrePebblev1Marked-38] + _ = x[RoleOptionsTableHasIDColumn-39] + _ = x[RoleOptionsIDColumnIsBackfilled-40] + _ = x[SetRoleOptionsUserIDColumnNotNull-41] + _ = x[UseDelRangeInGCJob-42] + _ = x[WaitedForDelRangeInGCJob-43] } -const _Key_name = "V21_2Start22_1ProbeRequestPublicSchemasWithDescriptorsEnsureSpanConfigReconciliationEnsureSpanConfigSubscriptionEnableSpanConfigStoreEnablePebbleFormatVersionBlockPropertiesEnableLeaseHolderRemovalChangefeedIdlenessEnableNewStoreRebalancerClusterLocksVirtualTableAutoStatsTableSettingsSuperRegionsEnableNewChangefeedOptionsV22_1Start22_2LocalTimestampsPebbleFormatSplitUserKeysMarkedCompactedEnsurePebbleFormatVersionRangeKeysEnablePebbleFormatVersionRangeKeysTrigramInvertedIndexesRemoveGrantPrivilegeMVCCRangeTombstonesUpgradeSequenceToBeReferencedByIDSampledStmtDiagReqsAddSSTableTombstonesSystemPrivilegesTableEnablePredicateProjectionChangefeedAlterSystemSQLInstancesAddLocalitySystemExternalConnectionsTableAlterSystemStatementStatisticsAddIndexRecommendationsRoleIDSequenceAddSystemUserIDColumnSystemUsersIDColumnIsBackfilledSetSystemUsersUserIDColumnNotNullSQLSchemaTelemetryScheduledJobsSchemaChangeSupportsCreateFunctionDeleteRequestReturnKeyPebbleFormatPrePebblev1MarkedRoleOptionsTableHasIDColumnRoleOptionsIDColumnIsBackfilledSetRoleOptionsUserIDColumnNotNullUseDelRangeInGCJobWaitedForDelRangeInGCJob" +const _Key_name = "V21_2Start22_1ProbeRequestPublicSchemasWithDescriptorsEnsureSpanConfigReconciliationEnsureSpanConfigSubscriptionEnableSpanConfigStoreEnablePebbleFormatVersionBlockPropertiesEnableLeaseHolderRemovalChangefeedIdlenessEnableNewStoreRebalancerClusterLocksVirtualTableAutoStatsTableSettingsEnableNewChangefeedOptionsV22_1Start22_2LocalTimestampsPebbleFormatSplitUserKeysMarkedCompactedEnsurePebbleFormatVersionRangeKeysEnablePebbleFormatVersionRangeKeysTrigramInvertedIndexesRemoveGrantPrivilegeMVCCRangeTombstonesUpgradeSequenceToBeReferencedByIDSampledStmtDiagReqsAddSSTableTombstonesSystemPrivilegesTableEnablePredicateProjectionChangefeedAlterSystemSQLInstancesAddLocalitySystemExternalConnectionsTableAlterSystemStatementStatisticsAddIndexRecommendationsRoleIDSequenceAddSystemUserIDColumnSystemUsersIDColumnIsBackfilledSetSystemUsersUserIDColumnNotNullSQLSchemaTelemetryScheduledJobsSchemaChangeSupportsCreateFunctionDeleteRequestReturnKeyPebbleFormatPrePebblev1MarkedRoleOptionsTableHasIDColumnRoleOptionsIDColumnIsBackfilledSetRoleOptionsUserIDColumnNotNullUseDelRangeInGCJobWaitedForDelRangeInGCJob" -var _Key_index = [...]uint16{0, 5, 14, 26, 54, 84, 112, 133, 173, 197, 215, 239, 263, 285, 297, 323, 328, 337, 352, 392, 426, 460, 482, 502, 521, 554, 573, 593, 614, 649, 683, 713, 766, 780, 801, 832, 865, 896, 930, 952, 981, 1008, 1039, 1072, 1090, 1114} +var _Key_index = [...]uint16{0, 5, 14, 26, 54, 84, 112, 133, 173, 197, 215, 239, 263, 285, 311, 316, 325, 340, 380, 414, 448, 470, 490, 509, 542, 561, 581, 602, 637, 671, 701, 754, 768, 789, 820, 853, 884, 918, 940, 969, 996, 1027, 1060, 1078, 1102} func (i Key) String() string { if i < 0 || i >= Key(len(_Key_index)-1) { diff --git a/pkg/sql/alter_database.go b/pkg/sql/alter_database.go index 043225db4ba5..87c3d63347d0 100644 --- a/pkg/sql/alter_database.go +++ b/pkg/sql/alter_database.go @@ -16,7 +16,6 @@ import ( "sort" "strings" - "github.com/cockroachdb/cockroach/pkg/clusterversion" "github.com/cockroachdb/cockroach/pkg/config/zonepb" "github.com/cockroachdb/cockroach/pkg/keys" "github.com/cockroachdb/cockroach/pkg/security/username" @@ -1330,9 +1329,6 @@ type alterDatabaseAddSuperRegion struct { func (p *planner) AlterDatabaseAddSuperRegion( ctx context.Context, n *tree.AlterDatabaseAddSuperRegion, ) (planNode, error) { - if !p.ExecCfg().Settings.Version.IsActive(ctx, clusterversion.SuperRegions) { - return nil, errors.Newf("super regions are not supported until upgrade to version %s is finalized", clusterversion.SuperRegions.String()) - } if err := p.isSuperRegionEnabled(); err != nil { return nil, err } @@ -1429,10 +1425,6 @@ type alterDatabaseDropSuperRegion struct { func (p *planner) AlterDatabaseDropSuperRegion( ctx context.Context, n *tree.AlterDatabaseDropSuperRegion, ) (planNode, error) { - if !p.ExecCfg().Settings.Version.IsActive(ctx, clusterversion.SuperRegions) { - return nil, errors.Newf("super regions are not supported until upgrade to version %s is finalized", clusterversion.SuperRegions.String()) - } - if err := p.isSuperRegionEnabled(); err != nil { return nil, err } @@ -1561,9 +1553,6 @@ func (n *alterDatabaseAlterSuperRegion) Close(context.Context) {} func (p *planner) AlterDatabaseAlterSuperRegion( ctx context.Context, n *tree.AlterDatabaseAlterSuperRegion, ) (planNode, error) { - if !p.ExecCfg().Settings.Version.IsActive(ctx, clusterversion.SuperRegions) { - return nil, errors.Newf("super regions are not supported until upgrade to version %s is finalized", clusterversion.SuperRegions.String()) - } if err := p.isSuperRegionEnabled(); err != nil { return nil, err } diff --git a/pkg/sql/logictest/testdata/logic_test/super_regions_mixed_version b/pkg/sql/logictest/testdata/logic_test/super_regions_mixed_version deleted file mode 100644 index a7197836456f..000000000000 --- a/pkg/sql/logictest/testdata/logic_test/super_regions_mixed_version +++ /dev/null @@ -1,10 +0,0 @@ -# LogicTest: local-mixed-21.2-22.1 - -statement error pq: super regions are not supported until upgrade to version SuperRegions is finalized -ALTER DATABASE test ADD SUPER REGION "test" VALUES "hello" - -statement error pq: super regions are not supported until upgrade to version SuperRegions is finalized -ALTER DATABASE test DROP SUPER REGION "test" - -statement error pq: super regions are not supported until upgrade to version SuperRegions is finalized -ALTER DATABASE test ALTER SUPER REGION "test" VALUES "hello" diff --git a/pkg/sql/logictest/tests/local-mixed-21.2-22.1/BUILD.bazel b/pkg/sql/logictest/tests/local-mixed-21.2-22.1/BUILD.bazel deleted file mode 100644 index 39bad3f094e1..000000000000 --- a/pkg/sql/logictest/tests/local-mixed-21.2-22.1/BUILD.bazel +++ /dev/null @@ -1,28 +0,0 @@ -load("//build/bazelutil/unused_checker:unused.bzl", "get_x_data") -load("@io_bazel_rules_go//go:def.bzl", "go_test") - -go_test( - name = "local-mixed-21_2-22_1_test", - size = "enormous", - srcs = ["generated_test.go"], - data = [ - "//c-deps:libgeos", # keep - "//pkg/sql/logictest:testdata", # keep - ], - shard_count = 1, - tags = ["cpu:1"], - deps = [ - "//pkg/build/bazel", - "//pkg/security/securityassets", - "//pkg/security/securitytest", - "//pkg/server", - "//pkg/sql/logictest", - "//pkg/testutils/serverutils", - "//pkg/testutils/skip", - "//pkg/testutils/testcluster", - "//pkg/util/leaktest", - "//pkg/util/randutil", - ], -) - -get_x_data(name = "get_x_data") diff --git a/pkg/sql/logictest/tests/local-mixed-21.2-22.1/generated_test.go b/pkg/sql/logictest/tests/local-mixed-21.2-22.1/generated_test.go deleted file mode 100644 index 134b9518798e..000000000000 --- a/pkg/sql/logictest/tests/local-mixed-21.2-22.1/generated_test.go +++ /dev/null @@ -1,80 +0,0 @@ -// Copyright 2022 The Cockroach Authors. -// -// Use of this software is governed by the Business Source License -// included in the file licenses/BSL.txt. -// -// As of the Change Date specified in that file, in accordance with -// the Business Source License, use of this software will be governed -// by the Apache License, Version 2.0, included in the file -// licenses/APL.txt. - -// Code generated by generate-logictest, DO NOT EDIT. - -package testlocal_mixed_212_221 - -import ( - "os" - "path/filepath" - "testing" - - "github.com/cockroachdb/cockroach/pkg/build/bazel" - "github.com/cockroachdb/cockroach/pkg/security/securityassets" - "github.com/cockroachdb/cockroach/pkg/security/securitytest" - "github.com/cockroachdb/cockroach/pkg/server" - "github.com/cockroachdb/cockroach/pkg/sql/logictest" - "github.com/cockroachdb/cockroach/pkg/testutils/serverutils" - "github.com/cockroachdb/cockroach/pkg/testutils/skip" - "github.com/cockroachdb/cockroach/pkg/testutils/testcluster" - "github.com/cockroachdb/cockroach/pkg/util/leaktest" - "github.com/cockroachdb/cockroach/pkg/util/randutil" -) - -const configIdx = 18 - -var logicTestDir string - -func init() { - if bazel.BuiltWithBazel() { - var err error - logicTestDir, err = bazel.Runfile("pkg/sql/logictest/testdata/logic_test") - if err != nil { - panic(err) - } - } else { - logicTestDir = "../../../../sql/logictest/testdata/logic_test" - } -} - -func TestMain(m *testing.M) { - securityassets.SetLoader(securitytest.EmbeddedAssets) - randutil.SeedForTests() - serverutils.InitTestServerFactory(server.TestServerFactory) - serverutils.InitTestClusterFactory(testcluster.TestClusterFactory) - os.Exit(m.Run()) -} - -func runLogicTest(t *testing.T, file string) { - skip.UnderDeadlock(t, "times out and/or hangs") - logictest.RunLogicTest(t, logictest.TestServerArgs{}, configIdx, filepath.Join(logicTestDir, file)) -} - -// TestLogic_tmp runs any tests that are prefixed with "_", in which a dedicated -// test is not generated for. This allows developers to create and run temporary -// test files that are not checked into the repository, without repeatedly -// regenerating and reverting changes to this file, generated_test.go. -// -// TODO(mgartner): Add file filtering so that individual files can be run, -// instead of all files with the "_" prefix. -func TestLogic_tmp(t *testing.T) { - defer leaktest.AfterTest(t)() - var glob string - glob = filepath.Join(logicTestDir, "_*") - logictest.RunLogicTests(t, logictest.TestServerArgs{}, configIdx, glob) -} - -func TestLogic_super_regions_mixed_version( - t *testing.T, -) { - defer leaktest.AfterTest(t)() - runLogicTest(t, "super_regions_mixed_version") -} From 3525705b50b74c208df5d99228d9975cfac5e87a Mon Sep 17 00:00:00 2001 From: Renato Costa Date: Wed, 17 Aug 2022 15:12:36 -0400 Subject: [PATCH 8/9] roachtest: add mixed-version testing for CDC This commits adds the `cdc/mixed-versions` roachtest. It builds on top of the existing infrastructure for mixed version testing in order to create a test scenario that reproduces the issue observed by DoorDash when upgrading from 21.2 to 22.1.0. Following the pattern present in other mixed version tests, this test starts the cluster at the previous version, upgrades the binaries to the current version, rolls it back, and then finally performs the binary upgrade again and allowing the upgrade to finalize. This roachtest uses the `FingerprintValidator` infrastructure used in CDC unit tests (and also in the currently skipped `cdc/bank` roachtest). This validator gives us strong guarantees that the events produced by a changefeed are correct even in the face of ongoing upgrades. This test fails roachtest on v22.1.0; once the upgrade to v22.1 is finalized, the Kafka consumer won't see further updates, and the test eventually times out. Release justification: test-only change. Release note: None. --- pkg/ccl/changefeedccl/cdctest/BUILD.bazel | 1 + pkg/ccl/changefeedccl/cdctest/nemeses.go | 2 +- pkg/ccl/changefeedccl/cdctest/validator.go | 78 +++- .../changefeedccl/cdctest/validator_test.go | 22 +- pkg/cmd/roachtest/tests/BUILD.bazel | 2 + pkg/cmd/roachtest/tests/cdc.go | 46 ++- pkg/cmd/roachtest/tests/mixed_version_cdc.go | 344 ++++++++++++++++++ pkg/cmd/roachtest/tests/mixed_version_jobs.go | 4 +- pkg/cmd/roachtest/tests/registry.go | 1 + pkg/cmd/roachtest/tests/versionupgrade.go | 9 +- 10 files changed, 467 insertions(+), 42 deletions(-) create mode 100644 pkg/cmd/roachtest/tests/mixed_version_cdc.go diff --git a/pkg/ccl/changefeedccl/cdctest/BUILD.bazel b/pkg/ccl/changefeedccl/cdctest/BUILD.bazel index cc8bdcb36ba4..d1d78541f380 100644 --- a/pkg/ccl/changefeedccl/cdctest/BUILD.bazel +++ b/pkg/ccl/changefeedccl/cdctest/BUILD.bazel @@ -31,6 +31,7 @@ go_library( "//pkg/util/hlc", "//pkg/util/log", "//pkg/util/randutil", + "//pkg/util/retry", "//pkg/util/syncutil", "//pkg/util/timeutil", "@com_github_cockroachdb_errors//:errors", diff --git a/pkg/ccl/changefeedccl/cdctest/nemeses.go b/pkg/ccl/changefeedccl/cdctest/nemeses.go index bb1612fcd2fb..ca36ce99b908 100644 --- a/pkg/ccl/changefeedccl/cdctest/nemeses.go +++ b/pkg/ccl/changefeedccl/cdctest/nemeses.go @@ -173,7 +173,7 @@ func RunNemesis(f TestFeedFactory, db *gosql.DB, isSinkless bool) (Validator, er if err != nil { return nil, err } - fprintV, err := NewFingerprintValidator(db, `foo`, scratchTableName, foo.Partitions(), ns.maxTestColumnCount) + fprintV, err := NewFingerprintValidator(db, `foo`, scratchTableName, foo.Partitions(), ns.maxTestColumnCount, false) if err != nil { return nil, err } diff --git a/pkg/ccl/changefeedccl/cdctest/validator.go b/pkg/ccl/changefeedccl/cdctest/validator.go index f0b705837663..09c584f2f2c1 100644 --- a/pkg/ccl/changefeedccl/cdctest/validator.go +++ b/pkg/ccl/changefeedccl/cdctest/validator.go @@ -15,9 +15,11 @@ import ( "fmt" "sort" "strings" + "time" "github.com/cockroachdb/cockroach/pkg/roachpb" "github.com/cockroachdb/cockroach/pkg/util/hlc" + "github.com/cockroachdb/cockroach/pkg/util/retry" "github.com/cockroachdb/errors" ) @@ -63,6 +65,8 @@ var _ Validator = &orderValidator{} var _ Validator = &noOpValidator{} var _ StreamValidator = &orderValidator{} +var retryDuration = 2 * time.Minute + type noOpValidator struct{} // NoteRow accepts a changed row entry. @@ -343,6 +347,11 @@ type fingerprintValidator struct { fprintTestColumns int buffer []validatorRow + // shouldRetry indicates whether row updates should be retried (for + // a fixed duration). Typically used when the transient errors are + // expected (e.g., if performing an upgrade) + shouldRetry bool + failures []string } @@ -353,7 +362,11 @@ type fingerprintValidator struct { // will modify `fprint`'s schema to add `maxTestColumnCount` columns to avoid having to // accommodate schema changes on the fly. func NewFingerprintValidator( - sqlDB *gosql.DB, origTable, fprintTable string, partitions []string, maxTestColumnCount int, + sqlDB *gosql.DB, + origTable, fprintTable string, + partitions []string, + maxTestColumnCount int, + shouldRetry bool, ) (Validator, error) { // Fetch the primary keys though information_schema schema inspections so we // can use them to construct the SQL for DELETEs and also so we can verify @@ -395,6 +408,7 @@ func NewFingerprintValidator( primaryKeyCols: primaryKeyCols, fprintOrigColumns: fprintOrigColumns, fprintTestColumns: maxTestColumnCount, + shouldRetry: shouldRetry, } v.partitionResolved = make(map[string]hlc.Timestamp) for _, partition := range partitions { @@ -475,10 +489,16 @@ func (v *fingerprintValidator) applyRowUpdate(row validatorRow) (_err error) { return err } - if string(primaryKeyJSON) != row.key { + rowKey := row.key + if len(primaryKeyDatums) > 1 { + // format the key using the Go marshaller; otherwise, differences + // in formatting could lead to the comparison below failing + rowKey = asGoJSON(row.key) + } + if string(primaryKeyJSON) != rowKey { v.failures = append(v.failures, fmt.Sprintf(`key %s did not match expected key %s for value %s`, - row.key, primaryKeyJSON, row.value)) + rowKey, primaryKeyJSON, row.value)) } } else { // DELETE @@ -491,8 +511,11 @@ func (v *fingerprintValidator) applyRowUpdate(row validatorRow) (_err error) { args = append(args, datum) } } - _, err := v.sqlDB.Exec(stmtBuf.String(), args...) - return err + + return v.maybeRetry(func() error { + _, err := v.sqlDB.Exec(stmtBuf.String(), args...) + return err + }) } // NoteResolved implements the Validator interface. @@ -533,6 +556,9 @@ func (v *fingerprintValidator) NoteResolved(partition string, resolved hlc.Times break } row := v.buffer[0] + // NOTE: changes to the validator's state before `applyRowUpdate` + // are safe because, if the operation can fail, the caller should + // be setting the `shouldRetry` field accordingly v.buffer = v.buffer[1:] // If we've processed all row updates belonging to the previous row's timestamp, @@ -568,15 +594,19 @@ func (v *fingerprintValidator) NoteResolved(partition string, resolved hlc.Times func (v *fingerprintValidator) fingerprint(ts hlc.Timestamp) error { var orig string - if err := v.sqlDB.QueryRow(`SELECT IFNULL(fingerprint, 'EMPTY') FROM [ + if err := v.maybeRetry(func() error { + return v.sqlDB.QueryRow(`SELECT IFNULL(fingerprint, 'EMPTY') FROM [ SHOW EXPERIMENTAL_FINGERPRINTS FROM TABLE ` + v.origTable + ` - ] AS OF SYSTEM TIME '` + ts.AsOfSystemTime() + `'`).Scan(&orig); err != nil { + ] AS OF SYSTEM TIME '` + ts.AsOfSystemTime() + `'`).Scan(&orig) + }); err != nil { return err } var check string - if err := v.sqlDB.QueryRow(`SELECT IFNULL(fingerprint, 'EMPTY') FROM [ + if err := v.maybeRetry(func() error { + return v.sqlDB.QueryRow(`SELECT IFNULL(fingerprint, 'EMPTY') FROM [ SHOW EXPERIMENTAL_FINGERPRINTS FROM TABLE ` + v.fprintTable + ` - ]`).Scan(&check); err != nil { + ]`).Scan(&check) + }); err != nil { return err } if orig != check { @@ -591,6 +621,17 @@ func (v *fingerprintValidator) Failures() []string { return v.failures } +// maybeRetry will retry the function passed if the fingerprint was +// created with `shouldRetry` set to `true`. Every access to `sqlDB` +// should be made my closures passed to this function +func (v *fingerprintValidator) maybeRetry(f func() error) error { + if v.shouldRetry { + return retry.ForDuration(retryDuration, f) + } + + return f() +} + // Validators abstracts over running multiple `Validator`s at once on the same // feed. type Validators []Validator @@ -731,3 +772,22 @@ func fetchPrimaryKeyCols(sqlDB *gosql.DB, tableStr string) ([]string, error) { } return primaryKeyCols, nil } + +// asGoJSON tries to unmarshal the given string as JSON; if +// successful, the struct is marshalled back to JSON. This is to +// enforce the default formatting of the standard library marshaller, +// allowing comparisons of JSON strings when we don't control the +// formatting of the strings. +func asGoJSON(s string) string { + var obj interface{} + if err := gojson.Unmarshal([]byte(s), &obj); err != nil { + return s + } + + blob, err := gojson.Marshal(obj) + if err != nil { + return s + } + + return string(blob) +} diff --git a/pkg/ccl/changefeedccl/cdctest/validator_test.go b/pkg/ccl/changefeedccl/cdctest/validator_test.go index 4589518b96da..f70617c197ea 100644 --- a/pkg/ccl/changefeedccl/cdctest/validator_test.go +++ b/pkg/ccl/changefeedccl/cdctest/validator_test.go @@ -292,14 +292,14 @@ func TestFingerprintValidator(t *testing.T) { t.Run(`empty`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`empty`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `empty`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `empty`, []string{`p`}, testColumns, false) require.NoError(t, err) noteResolved(t, v, `p`, ts[0]) assertValidatorFailures(t, v) }) t.Run(`wrong data`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`wrong_data`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `wrong_data`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `wrong_data`, []string{`p`}, testColumns, false) require.NoError(t, err) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":10}}`, ts[1]) noteResolved(t, v, `p`, ts[1]) @@ -310,7 +310,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`all resolved`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`all_resolved`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `all_resolved`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `all_resolved`, []string{`p`}, testColumns, false) require.NoError(t, err) if err := v.NoteResolved(`p`, ts[0]); err != nil { t.Fatal(err) @@ -329,7 +329,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`rows unsorted`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`rows_unsorted`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `rows_unsorted`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `rows_unsorted`, []string{`p`}, testColumns, false) require.NoError(t, err) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":3}}`, ts[3]) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":2}}`, ts[2]) @@ -341,7 +341,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`missed initial`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`missed_initial`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `missed_initial`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `missed_initial`, []string{`p`}, testColumns, false) require.NoError(t, err) noteResolved(t, v, `p`, ts[0]) // Intentionally missing {"k":1,"v":1} at ts[1]. @@ -357,7 +357,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`missed middle`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`missed_middle`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `missed_middle`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `missed_middle`, []string{`p`}, testColumns, false) require.NoError(t, err) noteResolved(t, v, `p`, ts[0]) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":1}}`, ts[1]) @@ -375,7 +375,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`missed end`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`missed_end`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `missed_end`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `missed_end`, []string{`p`}, testColumns, false) require.NoError(t, err) noteResolved(t, v, `p`, ts[0]) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":1}}`, ts[1]) @@ -390,7 +390,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`initial scan`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`initial_scan`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `initial_scan`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `initial_scan`, []string{`p`}, testColumns, false) require.NoError(t, err) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":3}}`, ts[3]) noteRow(t, v, ignored, `[2]`, `{"after": {"k":2,"v":2}}`, ts[3]) @@ -399,7 +399,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`unknown partition`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`unknown_partition`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `unknown_partition`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `unknown_partition`, []string{`p`}, testColumns, false) require.NoError(t, err) if err := v.NoteResolved(`nope`, ts[1]); !testutils.IsError(err, `unknown partition`) { t.Fatalf(`expected "unknown partition" error got: %+v`, err) @@ -407,7 +407,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`resolved unsorted`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`resolved_unsorted`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `resolved_unsorted`, []string{`p`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `resolved_unsorted`, []string{`p`}, testColumns, false) require.NoError(t, err) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":1}}`, ts[1]) noteResolved(t, v, `p`, ts[1]) @@ -417,7 +417,7 @@ func TestFingerprintValidator(t *testing.T) { }) t.Run(`two partitions`, func(t *testing.T) { sqlDB.Exec(t, createTableStmt(`two_partitions`)) - v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `two_partitions`, []string{`p0`, `p1`}, testColumns) + v, err := NewFingerprintValidator(sqlDBRaw, `foo`, `two_partitions`, []string{`p0`, `p1`}, testColumns, false) require.NoError(t, err) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":1}}`, ts[1]) noteRow(t, v, ignored, `[1]`, `{"after": {"k":1,"v":2}}`, ts[2]) diff --git a/pkg/cmd/roachtest/tests/BUILD.bazel b/pkg/cmd/roachtest/tests/BUILD.bazel index 46115cb88105..2629db8d1d93 100644 --- a/pkg/cmd/roachtest/tests/BUILD.bazel +++ b/pkg/cmd/roachtest/tests/BUILD.bazel @@ -74,6 +74,7 @@ go_library( "liquibase_blocklist.go", "loss_of_quorum_recovery.go", "many_splits.go", + "mixed_version_cdc.go", "mixed_version_decommission.go", "mixed_version_jobs.go", "mixed_version_schemachange.go", @@ -199,6 +200,7 @@ go_library( "//pkg/util/randutil", "//pkg/util/retry", "//pkg/util/search", + "//pkg/util/syncutil", "//pkg/util/timeutil", "//pkg/util/version", "//pkg/workload/histogram", diff --git a/pkg/cmd/roachtest/tests/cdc.go b/pkg/cmd/roachtest/tests/cdc.go index 73ac113acf74..c86f35d25cea 100644 --- a/pkg/cmd/roachtest/tests/cdc.go +++ b/pkg/cmd/roachtest/tests/cdc.go @@ -296,7 +296,6 @@ func cdcBasicTest(ctx context.Context, t test.Test, c cluster.Cluster, args cdcT } func runCDCBank(ctx context.Context, t test.Test, c cluster.Cluster) { - // Make the logs dir on every node to work around the `roachprod get logs` // spam. c.Run(ctx, c.All(), `mkdir -p logs`) @@ -305,21 +304,9 @@ func runCDCBank(ctx context.Context, t test.Test, c cluster.Cluster) { c.Put(ctx, t.Cockroach(), "./cockroach", crdbNodes) c.Put(ctx, t.DeprecatedWorkload(), "./workload", workloadNode) c.Start(ctx, t.L(), option.DefaultStartOpts(), install.MakeClusterSettings(), crdbNodes) - kafka := kafkaManager{ - t: t, - c: c, - nodes: kafkaNode, - } - kafka.install(ctx) - if !c.IsLocal() { - // TODO(dan): This test currently connects to kafka from the test - // runner, so kafka needs to advertise the external address. Better - // would be a binary we could run on one of the roachprod machines. - c.Run(ctx, kafka.nodes, `echo "advertised.listeners=PLAINTEXT://`+kafka.consumerURL(ctx)+`" >> `+ - filepath.Join(kafka.configDir(), "server.properties")) - } - kafka.start(ctx, "kafka") - defer kafka.stop(ctx) + + kafka, cleanup := setupKafka(ctx, t, c, kafkaNode) + defer cleanup() t.Status("creating kafka topic") if err := kafka.createTopic(ctx, "bank"); err != nil { @@ -417,7 +404,7 @@ func runCDCBank(ctx context.Context, t test.Test, c cluster.Cluster) { return errors.Wrap(err, "CREATE TABLE failed") } - fprintV, err := cdctest.NewFingerprintValidator(db, `bank.bank`, `fprint`, tc.partitions, 0) + fprintV, err := cdctest.NewFingerprintValidator(db, `bank.bank`, `fprint`, tc.partitions, 0, false) if err != nil { return errors.Wrap(err, "error creating validator") } @@ -1834,6 +1821,31 @@ func stopFeeds(db *gosql.DB) { )`) } +// setupKafka installs Kafka on the cluster and configures it so that +// the test runner can connect to it. Returns a function to be called +// at the end of the test for stopping Kafka. +func setupKafka( + ctx context.Context, t test.Test, c cluster.Cluster, nodes option.NodeListOption, +) (kafkaManager, func()) { + kafka := kafkaManager{ + t: t, + c: c, + nodes: nodes, + } + + kafka.install(ctx) + if !c.IsLocal() { + // TODO(dan): This test currently connects to kafka from the test + // runner, so kafka needs to advertise the external address. Better + // would be a binary we could run on one of the roachprod machines. + c.Run(ctx, kafka.nodes, `echo "advertised.listeners=PLAINTEXT://`+kafka.consumerURL(ctx)+`" >> `+ + filepath.Join(kafka.configDir(), "server.properties")) + } + + kafka.start(ctx, "kafka") + return kafka, func() { kafka.stop(ctx) } +} + type topicConsumer struct { sarama.Consumer diff --git a/pkg/cmd/roachtest/tests/mixed_version_cdc.go b/pkg/cmd/roachtest/tests/mixed_version_cdc.go new file mode 100644 index 000000000000..ec8ed3e674da --- /dev/null +++ b/pkg/cmd/roachtest/tests/mixed_version_cdc.go @@ -0,0 +1,344 @@ +// Copyright 2022 The Cockroach Authors. +// +// Use of this software is governed by the Business Source License +// included in the file licenses/BSL.txt. +// +// As of the Change Date specified in that file, in accordance with +// the Business Source License, use of this software will be governed +// by the Apache License, Version 2.0, included in the file +// licenses/APL.txt. + +package tests + +import ( + "context" + "fmt" + "strconv" + "strings" + "time" + + "github.com/cockroachdb/cockroach/pkg/ccl/changefeedccl/cdctest" + "github.com/cockroachdb/cockroach/pkg/cmd/roachtest/cluster" + "github.com/cockroachdb/cockroach/pkg/cmd/roachtest/option" + "github.com/cockroachdb/cockroach/pkg/cmd/roachtest/registry" + "github.com/cockroachdb/cockroach/pkg/cmd/roachtest/test" + "github.com/cockroachdb/cockroach/pkg/testutils/sqlutils" + "github.com/cockroachdb/cockroach/pkg/util/randutil" + "github.com/cockroachdb/cockroach/pkg/util/retry" + "github.com/cockroachdb/cockroach/pkg/util/syncutil" + "github.com/cockroachdb/cockroach/pkg/util/timeutil" + "github.com/cockroachdb/cockroach/pkg/util/version" +) + +const ( + // how many resolved timestamps to wait for before considering the + // system to be working as intended at a specific version state + resolvedTimestampsPerState = 5 + + // resolvedInterval is the value passed to the `resolved` option + // when creating the changefeed + resolvedInterval = "10s" +) + +var ( + // the CDC target, DB and table. We're running the bank workload in + // this test. + targetDB = "bank" + targetTable = "bank" + + timeout = 30 * time.Minute +) + +func registerCDCMixedVersions(r registry.Registry) { + r.Add(registry.TestSpec{ + Name: "cdc/mixed-versions", + Owner: registry.OwnerTestEng, + Cluster: r.MakeClusterSpec(5), + Timeout: timeout, + RequiresLicense: true, + Run: func(ctx context.Context, t test.Test, c cluster.Cluster) { + runCDCMixedVersions(ctx, t, c, *t.BuildVersion()) + }, + }) +} + +// cdcMixedVersionTester implements mixed-version/upgrade testing for +// CDC. It knows how to set up the cluster to run Kafka, monitor +// events, and run validations that ensure changefeeds work during and +// after upgrade. +type cdcMixedVersionTester struct { + ctx context.Context + crdbNodes option.NodeListOption + workloadNodes option.NodeListOption + kafkaNodes option.NodeListOption + monitor cluster.Monitor + timestampsResolved struct { + syncutil.Mutex + C chan struct{} + } + kafka kafkaManager + validator *cdctest.CountValidator + cleanup func() +} + +func newCDCMixedVersionTester( + ctx context.Context, t test.Test, c cluster.Cluster, +) cdcMixedVersionTester { + crdbNodes := c.Range(1, c.Spec().NodeCount-1) + lastNode := c.Node(c.Spec().NodeCount) + + c.Put(ctx, t.Cockroach(), "./cockroach", lastNode) + c.Put(ctx, t.DeprecatedWorkload(), "./workload", lastNode) + + return cdcMixedVersionTester{ + ctx: ctx, + crdbNodes: crdbNodes, + workloadNodes: lastNode, + kafkaNodes: lastNode, + monitor: c.NewMonitor(ctx, crdbNodes), + } +} + +// StartKafka will install and start Kafka on the configured node. It +// will also create the topic where changefeed events will be sent. +func (cmvt *cdcMixedVersionTester) StartKafka(t test.Test, c cluster.Cluster) { + t.Status("starting Kafka node") + cmvt.kafka, cmvt.cleanup = setupKafka(cmvt.ctx, t, c, cmvt.kafkaNodes) + + // try to create a Kafka topic for some time. Without waiting, a + // `kafka controller not available` error is seen with 1-5% + // probability + if err := retry.ForDuration(1*time.Minute, func() error { + return cmvt.kafka.createTopic(cmvt.ctx, targetTable) + }); err != nil { + t.Fatal(fmt.Errorf("timed out trying to create kafka topic: %w", err)) + } +} + +// Cleanup is supposed to be called at the end of tests that use +// `cdcMixedVersionTester` +func (cmvt *cdcMixedVersionTester) Cleanup() { + if cmvt.cleanup != nil { + cmvt.cleanup() + } +} + +// installAndStartWorkload starts a bank workload asynchronously +func (cmvt *cdcMixedVersionTester) installAndStartWorkload() versionStep { + return func(ctx context.Context, t test.Test, u *versionUpgradeTest) { + t.Status("installing and running workload") + u.c.Run(ctx, cmvt.workloadNodes, "./workload init bank {pgurl:1}") + cmvt.monitor.Go(func(ctx context.Context) error { + return u.c.RunE( + ctx, + cmvt.workloadNodes, + fmt.Sprintf("./workload run bank {pgurl%s} --max-rate=10 --tolerate-errors", cmvt.crdbNodes), + ) + }) + } +} + +// waitForResolvedTimestamps waits for the underlying CDC verifier to +// resolve `resolvedTimestampsPerState` +func (cmvt *cdcMixedVersionTester) waitForResolvedTimestamps() versionStep { + return func(ctx context.Context, t test.Test, u *versionUpgradeTest) { + t.Status(fmt.Sprintf("waiting for %d resolved timestamps", resolvedTimestampsPerState)) + // create a new channel for the resolved timestamps, allowing any + // new resolved timestamps to be captured and account for in the + // loop below + func() { + cmvt.timestampsResolved.Lock() + defer cmvt.timestampsResolved.Unlock() + + cmvt.timestampsResolved.C = make(chan struct{}) + }() + + var resolved int + for range cmvt.timestampsResolved.C { + resolved++ + t.L().Printf("%d of %d timestamps resolved", resolved, resolvedTimestampsPerState) + if resolved == resolvedTimestampsPerState { + break + } + } + + // set the resolved timestamps channel back to `nil`; while in + // this state, any new resolved timestamps will be ignored + func() { + cmvt.timestampsResolved.Lock() + defer cmvt.timestampsResolved.Unlock() + + cmvt.timestampsResolved.C = nil + }() + } +} + +// setupVerifier creates a CDC validator to validate that a changefeed +// created on the `target` table is able to re-create the table +// somewhere else. It also verifies CDC's ordering guarantees. This +// step will not block, but will start the verifier in a separate Go +// routine. Use `waitForVerifier` to wait for the verifier to finish. +func (cmvt *cdcMixedVersionTester) setupVerifier(node int) versionStep { + return func(ctx context.Context, t test.Test, u *versionUpgradeTest) { + tableName := targetDB + "." + targetTable + t.Status(fmt.Sprintf("setting up changefeed verifier for table %s", tableName)) + + // we could just return the error here and let `Wait` return the + // error. However, calling t.Fatal directly lets us stop the test + // earlier + cmvt.monitor.Go(func(ctx context.Context) error { + consumer, err := cmvt.kafka.consumer(ctx, targetTable) + if err != nil { + t.Fatal(err) + } + defer consumer.Close() + + db := u.conn(ctx, t, node) + if _, err := db.Exec( + "CREATE TABLE fprint (id INT PRIMARY KEY, balance INT, payload STRING)", + ); err != nil { + t.Fatal(err) + } + + fprintV, err := cdctest.NewFingerprintValidator(db, tableName, `fprint`, consumer.partitions, 0, true) + if err != nil { + t.Fatal(err) + } + validators := cdctest.Validators{ + cdctest.NewOrderValidator(tableName), + fprintV, + } + cmvt.validator = cdctest.MakeCountValidator(validators) + + for { + m := consumer.Next(ctx) + if m == nil { + t.L().Printf("end of changefeed") + return nil + } + + updated, resolved, err := cdctest.ParseJSONValueTimestamps(m.Value) + if err != nil { + t.Fatal(err) + } + + partitionStr := strconv.Itoa(int(m.Partition)) + if len(m.Key) > 0 { + if err := cmvt.validator.NoteRow(partitionStr, string(m.Key), string(m.Value), updated); err != nil { + t.Fatal(err) + } + } else { + if err := cmvt.validator.NoteResolved(partitionStr, resolved); err != nil { + t.Fatal(err) + } + + t.L().Printf("%d resolved timestamps validated, latest is %s behind realtime", + cmvt.validator.NumResolvedWithRows, timeutil.Since(resolved.GoTime())) + cmvt.timestampResolved() + } + } + }) + } +} + +// timestampsResolved updates the underlying channel if set (i.e., if +// we are waiting for resolved timestamps events) +func (cmvt *cdcMixedVersionTester) timestampResolved() { + cmvt.timestampsResolved.Lock() + defer cmvt.timestampsResolved.Unlock() + + if cmvt.timestampsResolved.C != nil { + cmvt.timestampsResolved.C <- struct{}{} + } +} + +// assertValid checks if the validator has found any issues at the +// time the function is called. +func (cmvt *cdcMixedVersionTester) assertValid() versionStep { + return func(ctx context.Context, t test.Test, u *versionUpgradeTest) { + if failures := cmvt.validator.Failures(); len(failures) > 0 { + t.Fatalf("validator failures:\n%s", strings.Join(failures, "\n")) + } + } +} + +// createChangeFeed issues a call to the given node to create a change +// feed for the target table. +func (cmvt *cdcMixedVersionTester) createChangeFeed(node int) versionStep { + return func(ctx context.Context, t test.Test, u *versionUpgradeTest) { + t.Status("creating changefeed") + db := u.conn(ctx, t, node) + cdcClusterSettings(t, sqlutils.MakeSQLRunner(db)) + + opts := []string{"updated", fmt.Sprintf("resolved='%s'", resolvedInterval)} + if _, err := db.Exec( + fmt.Sprintf("CREATE CHANGEFEED FOR %s.%s INTO $1 WITH %s", targetDB, targetTable, strings.Join(opts, ", ")), + cmvt.kafka.sinkURL(ctx), + ); err != nil { + t.Fatal(err) + } + } +} + +func runCDCMixedVersions( + ctx context.Context, t test.Test, c cluster.Cluster, buildVersion version.Version, +) { + predecessorVersion, err := PredecessorVersion(buildVersion) + if err != nil { + t.Fatal(err) + } + + tester := newCDCMixedVersionTester(ctx, t, c) + tester.StartKafka(t, c) + defer tester.Cleanup() + + rng, seed := randutil.NewPseudoRand() + t.L().Printf("random seed: %d", seed) + + // sqlNode returns the node to be used when sending SQL statements + // during this test. It is randomized, but the random seed is logged + // above. + sqlNode := func() int { + return tester.crdbNodes[rng.Intn(len(tester.crdbNodes))] + } + + // An empty string will lead to the cockroach binary specified by flag + // `cockroach` to be used. + const mainVersion = "" + newVersionUpgradeTest(c, + uploadAndStartFromCheckpointFixture(tester.crdbNodes, predecessorVersion), + tester.setupVerifier(sqlNode()), + tester.installAndStartWorkload(), + waitForUpgradeStep(tester.crdbNodes), + + // NB: at this point, cluster and binary version equal predecessorVersion, + // and auto-upgrades are on. + preventAutoUpgradeStep(sqlNode()), + tester.createChangeFeed(sqlNode()), + + tester.waitForResolvedTimestamps(), + // Roll the nodes into the new version one by one in random order + binaryUpgradeStep(tester.crdbNodes, mainVersion), + // let the workload run in the new version for a while + tester.waitForResolvedTimestamps(), + + tester.assertValid(), + + // Roll back again, which ought to be fine because the cluster upgrade was + // not finalized. + binaryUpgradeStep(tester.crdbNodes, predecessorVersion), + tester.waitForResolvedTimestamps(), + + tester.assertValid(), + + // Roll nodes forward and finalize upgrade. + binaryUpgradeStep(tester.crdbNodes, mainVersion), + + // allow cluster version to update + allowAutoUpgradeStep(sqlNode()), + waitForUpgradeStep(tester.crdbNodes), + + tester.waitForResolvedTimestamps(), + tester.assertValid(), + ).run(ctx, t) +} diff --git a/pkg/cmd/roachtest/tests/mixed_version_jobs.go b/pkg/cmd/roachtest/tests/mixed_version_jobs.go index 944c3603cc0a..0d8834959604 100644 --- a/pkg/cmd/roachtest/tests/mixed_version_jobs.go +++ b/pkg/cmd/roachtest/tests/mixed_version_jobs.go @@ -242,9 +242,7 @@ func runJobsMixedVersions( preventAutoUpgradeStep(1), backgroundTPCC.launch, - func(ctx context.Context, _ test.Test, u *versionUpgradeTest) { - time.Sleep(10 * time.Second) - }, + sleepStep(10*time.Second), checkForFailedJobsStep, pauseAllJobsStep(), diff --git a/pkg/cmd/roachtest/tests/registry.go b/pkg/cmd/roachtest/tests/registry.go index fa83a3605418..9acdea1be865 100644 --- a/pkg/cmd/roachtest/tests/registry.go +++ b/pkg/cmd/roachtest/tests/registry.go @@ -101,6 +101,7 @@ func RegisterTests(r registry.Registry) { registerSchemaChangeInvertedIndex(r) registerSchemaChangeMixedVersions(r) registerSchemaChangeRandomLoad(r) + registerCDCMixedVersions(r) registerScrubAllChecksTPCC(r) registerScrubIndexOnlyTPCC(r) registerSecondaryIndexesMultiVersionCluster(r) diff --git a/pkg/cmd/roachtest/tests/versionupgrade.go b/pkg/cmd/roachtest/tests/versionupgrade.go index 995c8e36c123..ccae65f35faa 100644 --- a/pkg/cmd/roachtest/tests/versionupgrade.go +++ b/pkg/cmd/roachtest/tests/versionupgrade.go @@ -183,8 +183,9 @@ func (u *versionUpgradeTest) run(ctx context.Context, t test.Test) { } }() - for _, step := range u.steps { + for i, step := range u.steps { if step != nil { + t.Status(fmt.Sprintf("versionUpgrateTest: starting step %d", i+1)) step(ctx, t, u) } } @@ -696,3 +697,9 @@ func importLargeBankStep(oldV string, rows int, crdbNodes option.NodeListOption) m.Wait() } } + +func sleepStep(d time.Duration) versionStep { + return func(ctx context.Context, t test.Test, u *versionUpgradeTest) { + time.Sleep(d) + } +} From 576a03ff9eaba9d6c7e7cd46a9e38c2039f7e06b Mon Sep 17 00:00:00 2001 From: Aayush Shah Date: Wed, 17 Aug 2022 15:54:56 -0400 Subject: [PATCH 9/9] roachtest: enable better vmodules for drain/quit roachtests This should help in debugging failures like #85203 when they happen again. Release note: None Release justification: testing only --- pkg/cmd/roachtest/tests/quit.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/cmd/roachtest/tests/quit.go b/pkg/cmd/roachtest/tests/quit.go index c0eb8f3a07b7..6df4084aba17 100644 --- a/pkg/cmd/roachtest/tests/quit.go +++ b/pkg/cmd/roachtest/tests/quit.go @@ -55,7 +55,7 @@ func runQuitTransfersLeases( } func (q *quitTest) init(ctx context.Context) { - q.args = []string{"--vmodule=store=1,replica=1,replica_proposal=1"} + q.args = []string{"--vmodule=replica_proposal=1,allocator=3,allocator_scorer=3"} q.env = []string{"COCKROACH_SCAN_MAX_IDLE_TIME=5ms"} q.c.Put(ctx, q.t.Cockroach(), "./cockroach") settings := install.MakeClusterSettings(install.EnvOption(q.env))