diff --git a/pkg/sql/row/fetcher.go b/pkg/sql/row/fetcher.go index f0668a81fcef..18d97668d3bf 100644 --- a/pkg/sql/row/fetcher.go +++ b/pkg/sql/row/fetcher.go @@ -1442,7 +1442,7 @@ func (rf *Fetcher) checkPrimaryIndexDatumEncodings(ctx context.Context) error { continue } - if skip, err := rh.skipColumnInPK(colID, rowVal.Datum); err != nil { + if skip, err := rh.skipColumnNotInPrimaryIndexValue(colID, rowVal.Datum); err != nil { return errors.NewAssertionErrorWithWrappedErrf(err, "unable to determine skip") } else if skip { continue diff --git a/pkg/sql/row/helper.go b/pkg/sql/row/helper.go index d7c027077890..73d74594a313 100644 --- a/pkg/sql/row/helper.go +++ b/pkg/sql/row/helper.go @@ -38,7 +38,8 @@ type rowHelper struct { // Computed and cached. primaryIndexKeyPrefix []byte - primaryIndexCols catalog.TableColSet + primaryIndexKeyCols catalog.TableColSet + primaryIndexValueCols catalog.TableColSet sortedColumnFamilies map[descpb.FamilyID][]descpb.ColumnID } @@ -130,20 +131,19 @@ func (rh *rowHelper) encodeSecondaryIndexes( return rh.indexEntries, nil } -// skipColumnInPK returns true if the value at column colID does not need -// to be encoded because it is already part of the primary key. Composite +// skipColumnNotInPrimaryIndexValue returns true if the value at column colID +// does not need to be encoded, either because it is already part of the primary +// key, or because it is not part of the primary index altogether. Composite // datums are considered too, so a composite datum in a PK will return false. -// TODO(dan): This logic is common and being moved into TableDescriptor (see -// #6233). Once it is, use the shared one. -func (rh *rowHelper) skipColumnInPK(colID descpb.ColumnID, value tree.Datum) (bool, error) { - if rh.primaryIndexCols.Empty() { - for i := 0; i < rh.TableDesc.GetPrimaryIndex().NumKeyColumns(); i++ { - pkColID := rh.TableDesc.GetPrimaryIndex().GetKeyColumnID(i) - rh.primaryIndexCols.Add(pkColID) - } +func (rh *rowHelper) skipColumnNotInPrimaryIndexValue( + colID descpb.ColumnID, value tree.Datum, +) (bool, error) { + if rh.primaryIndexKeyCols.Empty() { + rh.primaryIndexKeyCols = rh.TableDesc.GetPrimaryIndex().CollectKeyColumnIDs() + rh.primaryIndexValueCols = rh.TableDesc.GetPrimaryIndex().CollectPrimaryStoredColumnIDs() } - if !rh.primaryIndexCols.Contains(colID) { - return false, nil + if !rh.primaryIndexKeyCols.Contains(colID) { + return !rh.primaryIndexValueCols.Contains(colID), nil } if cdatum, ok := value.(tree.CompositeDatum); ok { // Composite columns are encoded in both the key and the value. diff --git a/pkg/sql/row/writer.go b/pkg/sql/row/writer.go index f3cb820dc909..caeba27a7090 100644 --- a/pkg/sql/row/writer.go +++ b/pkg/sql/row/writer.go @@ -174,7 +174,7 @@ func prepareInsertOrUpdateBatch( continue } - if skip, err := helper.skipColumnInPK(colID, values[idx]); err != nil { + if skip, err := helper.skipColumnNotInPrimaryIndexValue(colID, values[idx]); err != nil { return nil, err } else if skip { continue diff --git a/pkg/sql/schemachanger/scbuild/BUILD.bazel b/pkg/sql/schemachanger/scbuild/BUILD.bazel index 273675c29748..aea99639ac1d 100644 --- a/pkg/sql/schemachanger/scbuild/BUILD.bazel +++ b/pkg/sql/schemachanger/scbuild/BUILD.bazel @@ -28,7 +28,6 @@ go_library( "//pkg/sql/sem/tree", "//pkg/sql/sqlerrors", "//pkg/sql/types", - "//pkg/util/protoutil", "//pkg/util/sequence", "@com_github_cockroachdb_errors//:errors", ], diff --git a/pkg/sql/schemachanger/scbuild/table.go b/pkg/sql/schemachanger/scbuild/table.go index 67297ce7a5a8..99bc66b1891c 100644 --- a/pkg/sql/schemachanger/scbuild/table.go +++ b/pkg/sql/schemachanger/scbuild/table.go @@ -28,7 +28,6 @@ import ( "github.com/cockroachdb/cockroach/pkg/sql/sem/tree" "github.com/cockroachdb/cockroach/pkg/sql/sqlerrors" "github.com/cockroachdb/cockroach/pkg/sql/types" - "github.com/cockroachdb/cockroach/pkg/util/protoutil" "github.com/cockroachdb/cockroach/pkg/util/sequence" "github.com/cockroachdb/errors" ) @@ -370,8 +369,8 @@ func (b *buildContext) addOrUpdatePrimaryIndexTargetsForAddColumn( if t, ok := n.Element().(*scpb.PrimaryIndex); ok && b.outputNodes[i].Target.Direction == scpb.Target_ADD && t.TableID == table.GetID() { - t.StoreColumnIDs = append(t.StoreColumnIDs, colID) - t.StoreColumnNames = append(t.StoreColumnNames, colName) + t.Index.StoreColumnIDs = append(t.Index.StoreColumnIDs, colID) + t.Index.StoreColumnNames = append(t.Index.StoreColumnNames, colName) return t.Index.ID } } @@ -390,28 +389,16 @@ func (b *buildContext) addOrUpdatePrimaryIndexTargetsForAddColumn( ) newIdx.ID = idxID - var storeColIDs []descpb.ColumnID - var storeColNames []string - for _, col := range table.PublicColumns() { - containsCol := false - for _, id := range newIdx.KeyColumnIDs { - if id == col.GetID() { - containsCol = true - break - } - } - if !containsCol { - storeColIDs = append(storeColIDs, col.GetID()) - storeColNames = append(storeColNames, col.GetName()) - } + if !table.GetPrimaryIndex().CollectKeyColumnIDs().Contains(colID) && + !table.GetPrimaryIndex().CollectPrimaryStoredColumnIDs().Contains(colID) { + newIdx.StoreColumnIDs = append(newIdx.StoreColumnIDs, colID) + newIdx.StoreColumnNames = append(newIdx.StoreColumnNames, colName) } b.addNode(scpb.Target_ADD, &scpb.PrimaryIndex{ TableID: table.GetID(), Index: newIdx, OtherPrimaryIndexID: table.GetPrimaryIndexID(), - StoreColumnIDs: append(storeColIDs, colID), - StoreColumnNames: append(storeColNames, colName), }) // Drop the existing primary index. @@ -419,8 +406,6 @@ func (b *buildContext) addOrUpdatePrimaryIndexTargetsForAddColumn( TableID: table.GetID(), Index: table.GetPrimaryIndex().IndexDescDeepCopy(), OtherPrimaryIndexID: newIdx.ID, - StoreColumnIDs: storeColIDs, - StoreColumnNames: storeColNames, }) return idxID @@ -436,10 +421,10 @@ func (b *buildContext) addOrUpdatePrimaryIndexTargetsForDropColumn( if t, ok := n.Element().(*scpb.PrimaryIndex); ok && n.Target.Direction == scpb.Target_ADD && t.TableID == table.GetID() { - for j := range t.StoreColumnIDs { - if t.StoreColumnIDs[j] == colID { - t.StoreColumnIDs = append(t.StoreColumnIDs[:j], t.StoreColumnIDs[j+1:]...) - t.StoreColumnNames = append(t.StoreColumnNames[:j], t.StoreColumnNames[j+1:]...) + for j := range t.Index.StoreColumnIDs { + if t.Index.StoreColumnIDs[j] == colID { + t.Index.StoreColumnIDs = append(t.Index.StoreColumnIDs[:j], t.Index.StoreColumnIDs[j+1:]...) + t.Index.StoreColumnNames = append(t.Index.StoreColumnNames[:j], t.Index.StoreColumnNames[j+1:]...) return t.Index.ID } @@ -451,7 +436,7 @@ func (b *buildContext) addOrUpdatePrimaryIndexTargetsForDropColumn( // Create a new primary index, identical to the existing one except for its // ID and name. idxID = b.nextIndexID(table) - newIdx := protoutil.Clone(table.GetPrimaryIndex().IndexDesc()).(*descpb.IndexDescriptor) + newIdx := table.GetPrimaryIndex().IndexDescDeepCopy() newIdx.Name = tabledesc.GenerateUniqueName( "new_primary_key", func(name string) bool { @@ -461,44 +446,32 @@ func (b *buildContext) addOrUpdatePrimaryIndexTargetsForDropColumn( }, ) newIdx.ID = idxID - - var addStoreColIDs []descpb.ColumnID - var addStoreColNames []string - var dropStoreColIDs []descpb.ColumnID - var dropStoreColNames []string - for _, col := range table.PublicColumns() { - containsCol := false - for _, id := range newIdx.KeyColumnIDs { - if id == col.GetID() { - containsCol = true - break - } + for j, id := range newIdx.KeyColumnIDs { + if id == colID { + newIdx.KeyColumnIDs = append(newIdx.KeyColumnIDs[:j], newIdx.KeyColumnIDs[j+1:]...) + newIdx.KeyColumnNames = append(newIdx.KeyColumnNames[:j], newIdx.KeyColumnNames[j+1:]...) + break } - if !containsCol { - if colID != col.GetID() { - addStoreColIDs = append(addStoreColIDs, col.GetID()) - addStoreColNames = append(addStoreColNames, col.GetName()) - } - dropStoreColIDs = append(dropStoreColIDs, col.GetID()) - dropStoreColNames = append(dropStoreColNames, col.GetName()) + } + for j, id := range newIdx.StoreColumnIDs { + if id == colID { + newIdx.StoreColumnIDs = append(newIdx.StoreColumnIDs[:j], newIdx.StoreColumnIDs[j+1:]...) + newIdx.StoreColumnNames = append(newIdx.StoreColumnNames[:j], newIdx.StoreColumnNames[j+1:]...) + break } } b.addNode(scpb.Target_ADD, &scpb.PrimaryIndex{ TableID: table.GetID(), - Index: *newIdx, + Index: newIdx, OtherPrimaryIndexID: table.GetPrimaryIndexID(), - StoreColumnIDs: addStoreColIDs, - StoreColumnNames: addStoreColNames, }) // Drop the existing primary index. b.addNode(scpb.Target_DROP, &scpb.PrimaryIndex{ TableID: table.GetID(), - Index: *(protoutil.Clone(table.GetPrimaryIndex().IndexDesc()).(*descpb.IndexDescriptor)), + Index: table.GetPrimaryIndex().IndexDescDeepCopy(), OtherPrimaryIndexID: idxID, - StoreColumnIDs: dropStoreColIDs, - StoreColumnNames: dropStoreColNames, }) return idxID } diff --git a/pkg/sql/schemachanger/scbuild/testdata/alter_table b/pkg/sql/schemachanger/scbuild/testdata/alter_table index fa2545c5a560..015871ba1241 100644 --- a/pkg/sql/schemachanger/scbuild/testdata/alter_table +++ b/pkg/sql/schemachanger/scbuild/testdata/alter_table @@ -36,13 +36,13 @@ ALTER TABLE defaultdb.foo ADD COLUMN j INT name: new_primary_key partitioning: {} sharded: {} + storeColumnIds: + - 2 + storeColumnNames: + - j unique: true version: 4 otherPrimaryIndexId: 1 - storeColumnIds: - - 2 - storeColumnNames: - - j tableId: 52 - DROP PrimaryIndex:{DescID: 52, ElementName: "primary", IndexID: 1} state: PUBLIC @@ -102,13 +102,13 @@ ALTER TABLE defaultdb.foo ADD COLUMN j INT DEFAULT 123 name: new_primary_key partitioning: {} sharded: {} + storeColumnIds: + - 2 + storeColumnNames: + - j unique: true version: 4 otherPrimaryIndexId: 1 - storeColumnIds: - - 2 - storeColumnNames: - - j tableId: 52 - DROP PrimaryIndex:{DescID: 52, ElementName: "primary", IndexID: 1} state: PUBLIC @@ -169,15 +169,15 @@ ALTER TABLE defaultdb.foo ADD COLUMN k INT DEFAULT 456; name: new_primary_key partitioning: {} sharded: {} + storeColumnIds: + - 2 + - 3 + storeColumnNames: + - j + - k unique: true version: 4 otherPrimaryIndexId: 1 - storeColumnIds: - - 2 - - 3 - storeColumnNames: - - j - - k tableId: 52 - DROP PrimaryIndex:{DescID: 52, ElementName: "primary", IndexID: 1} state: PUBLIC @@ -251,13 +251,13 @@ ALTER TABLE defaultdb.foo ADD COLUMN a INT AS (i+1) STORED name: new_primary_key partitioning: {} sharded: {} + storeColumnIds: + - 2 + storeColumnNames: + - a unique: true version: 4 otherPrimaryIndexId: 1 - storeColumnIds: - - 2 - storeColumnNames: - - a tableId: 52 - DROP PrimaryIndex:{DescID: 52, ElementName: "primary", IndexID: 1} state: PUBLIC @@ -321,13 +321,13 @@ ALTER TABLE defaultdb.bar ADD COLUMN b INT; name: new_primary_key partitioning: {} sharded: {} + storeColumnIds: + - 2 + storeColumnNames: + - a unique: true version: 4 otherPrimaryIndexId: 1 - storeColumnIds: - - 2 - storeColumnNames: - - a tableId: 52 - DROP PrimaryIndex:{DescID: 52, ElementName: "primary", IndexID: 1} state: PUBLIC @@ -384,17 +384,13 @@ ALTER TABLE defaultdb.bar ADD COLUMN b INT; sharded: {} storeColumnIds: - 1 + - 3 storeColumnNames: - j + - b unique: true version: 4 otherPrimaryIndexId: 1 - storeColumnIds: - - 1 - - 3 - storeColumnNames: - - j - - b tableId: 53 - DROP PrimaryIndex:{DescID: 53, ElementName: "primary", IndexID: 1} state: PUBLIC @@ -421,8 +417,4 @@ ALTER TABLE defaultdb.bar ADD COLUMN b INT; unique: true version: 4 otherPrimaryIndexId: 2 - storeColumnIds: - - 1 - storeColumnNames: - - j tableId: 53 diff --git a/pkg/sql/schemachanger/scexec/executor_external_test.go b/pkg/sql/schemachanger/scexec/executor_external_test.go index c100fd4ecee9..492e0cd42cd1 100644 --- a/pkg/sql/schemachanger/scexec/executor_external_test.go +++ b/pkg/sql/schemachanger/scexec/executor_external_test.go @@ -241,12 +241,12 @@ func TestSchemaChanger(t *testing.T) { KeyColumnIDs: []descpb.ColumnID{1}, KeyColumnNames: []string{"i"}, KeyColumnDirections: []descpb.IndexDescriptor_Direction{descpb.IndexDescriptor_ASC}, + StoreColumnIDs: []descpb.ColumnID{2}, + StoreColumnNames: []string{"j"}, Unique: true, Type: descpb.IndexDescriptor_FORWARD, }, OtherPrimaryIndexID: fooTable.GetPrimaryIndexID(), - StoreColumnIDs: []descpb.ColumnID{2}, - StoreColumnNames: []string{"j"}, }), scpb.NewTarget(scpb.Target_ADD, &scpb.Column{ TableID: fooTable.GetID(), @@ -272,8 +272,6 @@ func TestSchemaChanger(t *testing.T) { Type: descpb.IndexDescriptor_FORWARD, }, OtherPrimaryIndexID: 2, - StoreColumnIDs: []descpb.ColumnID{}, - StoreColumnNames: []string{}, }), } diff --git a/pkg/sql/schemachanger/schemachanger_test.go b/pkg/sql/schemachanger/schemachanger_test.go index 0a1ab538ccdf..5c63b136cb3d 100644 --- a/pkg/sql/schemachanger/schemachanger_test.go +++ b/pkg/sql/schemachanger/schemachanger_test.go @@ -412,3 +412,106 @@ func TestConcurrentOldSchemaChangesCannotStart(t *testing.T) { close(continueNotification) require.NoError(t, g.Wait()) } + +func TestInsertDuringAddColumnNotWritingToCurrentPrimaryIndex(t *testing.T) { + defer leaktest.AfterTest(t)() + defer sqltestutils.SetTestJobsAdoptInterval()() + + ctx := context.Background() + + var doOnce sync.Once + // Closed when we enter the RunBeforeBackfill knob. + beforeBackfillNotification := make(chan struct{}) + // Closed when we're ready to continue with the schema change. + continueNotification := make(chan struct{}) + + var kvDB *kv.DB + params, _ := tests.CreateTestServerParams() + params.Knobs = base.TestingKnobs{ + SQLSchemaChanger: &sql.SchemaChangerTestingKnobs{ + RunBeforeResume: func(jobID jobspb.JobID) error { + // Assert that old schema change jobs never run in this test. + t.Errorf("unexpected old schema change job %d", jobID) + return nil + }, + }, + SQLNewSchemaChanger: &scexec.NewSchemaChangerTestingKnobs{ + BeforeStage: func(ops scop.Ops, m scexec.TestingKnobMetadata) error { + // Verify that we never get a mutation ID not associated with the schema + // change that is running. + if m.Phase != scplan.PostCommitPhase { + return nil + } + table := catalogkv.TestingGetTableDescriptorFromSchema( + kvDB, keys.SystemSQLCodec, "db", "public", "t") + for _, m := range table.AllMutations() { + assert.LessOrEqual(t, int(m.MutationID()), 2) + } + + if ops.Type() != scop.BackfillType { + return nil + } + for _, op := range ops.Slice() { + if _, ok := op.(scop.BackfillIndex); ok { + doOnce.Do(func() { + close(beforeBackfillNotification) + <-continueNotification + }) + } + } + return nil + }, + }, + } + + var s serverutils.TestServerInterface + var sqlDB *gosql.DB + s, sqlDB, kvDB = serverutils.StartServer(t, params) + defer s.Stopper().Stop(ctx) + + tdb := sqlutils.MakeSQLRunner(sqlDB) + tdb.Exec(t, `CREATE DATABASE db`) + tdb.Exec(t, `CREATE TABLE db.t (a INT PRIMARY KEY)`) + desc := catalogkv.TestingGetImmutableTableDescriptor(kvDB, keys.SystemSQLCodec, "db", "t") + + g := ctxgroup.WithContext(ctx) + + g.GoCtx(func(ctx context.Context) error { + conn, err := sqlDB.Conn(ctx) + if err != nil { + return err + } + _, err = conn.ExecContext(ctx, `SET experimental_use_new_schema_changer = 'on'`) + assert.NoError(t, err) + _, err = conn.ExecContext(ctx, `ALTER TABLE db.t ADD COLUMN b INT DEFAULT 100`) + assert.NoError(t, err) + return nil + }) + + <-beforeBackfillNotification + + // At this point the backfill operation is paused as it's about to begin. + // The new column `b` is not yet public, so a concurrent insert should: + // - in the current primary index, only insert a value for `a`, + // - in the new secondary index, which will be the future primary index, + // insert a value both for `a` and the default value for `b`, because that + // new index is delete-and-write-only as it is being backfilled. + tdb.Exec(t, ` + SET tracing = on,kv; + INSERT INTO db.t (a) VALUES (10); + SET tracing = off;`) + + // Trigger the resumption and conclusion of the backfill, + // and hence of the ADD COLUMN transaction. + close(continueNotification) + require.NoError(t, g.Wait()) + + // Check that the expectations set out above are verified. + results := tdb.QueryStr(t, ` + SELECT message + FROM [SHOW KV TRACE FOR SESSION] + WHERE message LIKE 'CPut %' OR message LIKE 'InitPut %'`) + require.GreaterOrEqual(t, len(results), 2) + require.Equal(t, fmt.Sprintf("CPut /Table/%d/1/10/0 -> /TUPLE/", desc.GetID()), results[0][0]) + require.Equal(t, fmt.Sprintf("InitPut /Table/%d/2/10/0 -> /TUPLE/2:2:Int/100", desc.GetID()), results[1][0]) +} diff --git a/pkg/sql/schemachanger/scpb/scpb.pb.go b/pkg/sql/schemachanger/scpb/scpb.pb.go index 0f057b8ff652..d40eb30d534d 100644 --- a/pkg/sql/schemachanger/scpb/scpb.pb.go +++ b/pkg/sql/schemachanger/scpb/scpb.pb.go @@ -239,11 +239,9 @@ func (m *Column) XXX_DiscardUnknown() { var xxx_messageInfo_Column proto.InternalMessageInfo type PrimaryIndex struct { - TableID github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ID `protobuf:"varint,1,opt,name=table_id,json=tableId,proto3,casttype=github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.ID" json:"table_id,omitempty"` - Index descpb.IndexDescriptor `protobuf:"bytes,2,opt,name=index,proto3" json:"index"` - OtherPrimaryIndexID github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.IndexID `protobuf:"varint,3,opt,name=other_primary_index_id,json=otherPrimaryIndexId,proto3,casttype=github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.IndexID" json:"other_primary_index_id,omitempty"` - StoreColumnIDs []github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ColumnID `protobuf:"varint,4,rep,packed,name=store_column_ids,json=storeColumnIds,proto3,casttype=github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.ColumnID" json:"store_column_ids,omitempty"` - StoreColumnNames []string `protobuf:"bytes,5,rep,name=store_column_names,json=storeColumnNames,proto3" json:"store_column_names,omitempty"` + TableID github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ID `protobuf:"varint,1,opt,name=table_id,json=tableId,proto3,casttype=github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.ID" json:"table_id,omitempty"` + Index descpb.IndexDescriptor `protobuf:"bytes,2,opt,name=index,proto3" json:"index"` + OtherPrimaryIndexID github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.IndexID `protobuf:"varint,3,opt,name=other_primary_index_id,json=otherPrimaryIndexId,proto3,casttype=github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.IndexID" json:"other_primary_index_id,omitempty"` } func (m *PrimaryIndex) Reset() { *m = PrimaryIndex{} } @@ -765,110 +763,106 @@ func init() { func init() { proto.RegisterFile("sql/schemachanger/scpb/scpb.proto", fileDescriptor_5413c88842564e28) } var fileDescriptor_5413c88842564e28 = []byte{ - // 1643 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x58, 0xcd, 0x6f, 0xdb, 0x46, - 0x16, 0x37, 0x25, 0x4a, 0x96, 0x9e, 0xbe, 0xe8, 0x89, 0x77, 0xa1, 0x0d, 0x76, 0x45, 0xc7, 0x0b, - 0x24, 0x46, 0x16, 0x90, 0x76, 0x93, 0xc5, 0x02, 0x6b, 0xa0, 0x68, 0x2c, 0x53, 0x46, 0x59, 0x3b, - 0x92, 0x4b, 0xd9, 0x71, 0x13, 0xb4, 0x10, 0x28, 0x72, 0x22, 0xb3, 0x91, 0x48, 0x99, 0xa4, 0xe2, - 0x08, 0x2d, 0xd0, 0x5e, 0x7a, 0x6d, 0x7a, 0x6b, 0x8f, 0x3d, 0xf7, 0xde, 0xff, 0xc1, 0x40, 0x2f, - 0xe9, 0x2d, 0x40, 0x01, 0xa1, 0x55, 0x80, 0xb6, 0xe7, 0x02, 0xed, 0xa1, 0xa7, 0x62, 0x86, 0x9f, - 0x92, 0x5c, 0x48, 0x88, 0x14, 0x03, 0x4d, 0x7b, 0x11, 0xa8, 0x47, 0xbe, 0xdf, 0x9b, 0xf7, 0x31, - 0xbf, 0xf7, 0x66, 0xe0, 0x8a, 0x75, 0xd2, 0x2e, 0x59, 0xca, 0x31, 0xee, 0xc8, 0x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0x79, 0x4f, 0xdc, - 0xe6, 0xe2, 0xe5, 0xab, 0x67, 0xdf, 0x16, 0x96, 0xce, 0x86, 0x05, 0xe6, 0xc9, 0xb0, 0xc0, 0x3c, - 0x1d, 0x16, 0x98, 0x6f, 0x86, 0x05, 0xe6, 0xe3, 0x67, 0x85, 0xa5, 0x27, 0xcf, 0x0a, 0x4b, 0x4f, - 0x9f, 0x15, 0x96, 0xee, 0xb1, 0x64, 0xd5, 0xcd, 0x38, 0xbd, 0xe2, 0xbd, 0xf9, 0x6b, 0x00, 0x00, - 0x00, 0xff, 0xff, 0xdb, 0x3d, 0x03, 0x65, 0x9b, 0x1b, 0x00, 0x00, + // 1579 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x58, 0xcf, 0x6f, 0x1b, 0xd5, + 0x16, 0xce, 0xd8, 0x63, 0xc7, 0x3e, 0xfe, 0x99, 0xdb, 0xbe, 0x27, 0xbf, 0xea, 0x3d, 0x4f, 0x9b, + 0x27, 0xb5, 0x55, 0x9f, 0x64, 0x3f, 0x5a, 0x84, 0x44, 0x24, 0x44, 0xe3, 0x8c, 0x23, 0x86, 0xa4, + 0x76, 0x18, 0x27, 0x0d, 0xad, 0x40, 0xd6, 0x78, 0xe6, 0xd6, 0x19, 0x6a, 0xcf, 0x38, 0x33, 0xe3, + 0xa6, 0x16, 0x48, 0xac, 0xd8, 0x52, 0x96, 0x2c, 0x59, 0xb3, 0xe7, 0x7f, 0x88, 0xc4, 0x26, 0xec, + 0x2a, 0x21, 0x59, 0xe0, 0x4a, 0xc0, 0x1a, 0x09, 0x16, 0xac, 0xd0, 0xbd, 0x77, 0x7e, 0xd9, 0x0e, + 0xb2, 0x55, 0xa7, 0x91, 0x28, 0x6c, 0xa2, 0xf1, 0xc9, 0x9c, 0xef, 0xbb, 0xe7, 0xdc, 0x73, 0xbf, + 0x73, 0xee, 0xc0, 0x15, 0xfb, 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 0xd4, 0x1a, 0x00, 0x00, } func (this *Column) Equal(that interface{}) bool { @@ -932,22 +926,6 @@ func (this *PrimaryIndex) Equal(that interface{}) bool { if this.OtherPrimaryIndexID != that1.OtherPrimaryIndexID { return false } - if len(this.StoreColumnIDs) != len(that1.StoreColumnIDs) { - return false - } - for i := range this.StoreColumnIDs { - if this.StoreColumnIDs[i] != that1.StoreColumnIDs[i] { - return false - } - } - if len(this.StoreColumnNames) != len(that1.StoreColumnNames) { - return false - } - for i := range this.StoreColumnNames { - if this.StoreColumnNames[i] != that1.StoreColumnNames[i] { - return false - } - } return true } func (this *SecondaryIndex) Equal(that interface{}) bool { @@ -1683,33 +1661,6 @@ func (m *PrimaryIndex) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l - if len(m.StoreColumnNames) > 0 { - for iNdEx := len(m.StoreColumnNames) - 1; iNdEx >= 0; iNdEx-- { - i -= len(m.StoreColumnNames[iNdEx]) - copy(dAtA[i:], m.StoreColumnNames[iNdEx]) - i = encodeVarintScpb(dAtA, i, uint64(len(m.StoreColumnNames[iNdEx]))) - i-- - dAtA[i] = 0x2a - } - } - if len(m.StoreColumnIDs) > 0 { - dAtA19 := make([]byte, len(m.StoreColumnIDs)*10) - var j18 int - for _, num := range m.StoreColumnIDs { - for num >= 1<<7 { - dAtA19[j18] = uint8(uint64(num)&0x7f | 0x80) - num >>= 7 - j18++ - } - dAtA19[j18] = uint8(num) - j18++ - } - i -= j18 - copy(dAtA[i:], dAtA19[:j18]) - i = encodeVarintScpb(dAtA, i, uint64(j18)) - i-- - dAtA[i] = 0x22 - } if m.OtherPrimaryIndexID != 0 { i = encodeVarintScpb(dAtA, i, uint64(m.OtherPrimaryIndexID)) i-- @@ -1850,20 +1801,20 @@ func (m *UniqueConstraint) MarshalToSizedBuffer(dAtA []byte) (int, error) { var l int _ = l if len(m.ColumnIDs) > 0 { - dAtA23 := make([]byte, len(m.ColumnIDs)*10) - var j22 int + dAtA21 := make([]byte, len(m.ColumnIDs)*10) + var j20 int for _, num := range m.ColumnIDs { for num >= 1<<7 { - dAtA23[j22] = uint8(uint64(num)&0x7f | 0x80) + dAtA21[j20] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j22++ + j20++ } - dAtA23[j22] = uint8(num) - j22++ + dAtA21[j20] = uint8(num) + j20++ } - i -= j22 - copy(dAtA[i:], dAtA23[:j22]) - i = encodeVarintScpb(dAtA, i, uint64(j22)) + i -= j20 + copy(dAtA[i:], dAtA21[:j20]) + i = encodeVarintScpb(dAtA, i, uint64(j20)) i-- dAtA[i] = 0x1a } @@ -1911,20 +1862,20 @@ func (m *CheckConstraint) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x28 } if len(m.ColumnIDs) > 0 { - dAtA25 := make([]byte, len(m.ColumnIDs)*10) - var j24 int + dAtA23 := make([]byte, len(m.ColumnIDs)*10) + var j22 int for _, num := range m.ColumnIDs { for num >= 1<<7 { - dAtA25[j24] = uint8(uint64(num)&0x7f | 0x80) + dAtA23[j22] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j24++ + j22++ } - dAtA25[j24] = uint8(num) - j24++ + dAtA23[j22] = uint8(num) + j22++ } - i -= j24 - copy(dAtA[i:], dAtA25[:j24]) - i = encodeVarintScpb(dAtA, i, uint64(j24)) + i -= j22 + copy(dAtA[i:], dAtA23[:j22]) + i = encodeVarintScpb(dAtA, i, uint64(j22)) i-- dAtA[i] = 0x22 } @@ -2006,20 +1957,20 @@ func (m *DefaultExpression) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x22 } if len(m.UsesSequenceIDs) > 0 { - dAtA27 := make([]byte, len(m.UsesSequenceIDs)*10) - var j26 int + dAtA25 := make([]byte, len(m.UsesSequenceIDs)*10) + var j24 int for _, num := range m.UsesSequenceIDs { for num >= 1<<7 { - dAtA27[j26] = uint8(uint64(num)&0x7f | 0x80) + dAtA25[j24] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j26++ + j24++ } - dAtA27[j26] = uint8(num) - j26++ + dAtA25[j24] = uint8(num) + j24++ } - i -= j26 - copy(dAtA[i:], dAtA27[:j26]) - i = encodeVarintScpb(dAtA, i, uint64(j26)) + i -= j24 + copy(dAtA[i:], dAtA25[:j24]) + i = encodeVarintScpb(dAtA, i, uint64(j24)) i-- dAtA[i] = 0x1a } @@ -2057,38 +2008,38 @@ func (m *View) MarshalToSizedBuffer(dAtA []byte) (int, error) { var l int _ = l if len(m.DependsOn) > 0 { - dAtA29 := make([]byte, len(m.DependsOn)*10) - var j28 int + dAtA27 := make([]byte, len(m.DependsOn)*10) + var j26 int for _, num := range m.DependsOn { for num >= 1<<7 { - dAtA29[j28] = uint8(uint64(num)&0x7f | 0x80) + dAtA27[j26] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j28++ + j26++ } - dAtA29[j28] = uint8(num) - j28++ + dAtA27[j26] = uint8(num) + j26++ } - i -= j28 - copy(dAtA[i:], dAtA29[:j28]) - i = encodeVarintScpb(dAtA, i, uint64(j28)) + i -= j26 + copy(dAtA[i:], dAtA27[:j26]) + i = encodeVarintScpb(dAtA, i, uint64(j26)) i-- dAtA[i] = 0x1a } if len(m.DependedOnBy) > 0 { - dAtA31 := make([]byte, len(m.DependedOnBy)*10) - var j30 int + dAtA29 := make([]byte, len(m.DependedOnBy)*10) + var j28 int for _, num := range m.DependedOnBy { for num >= 1<<7 { - dAtA31[j30] = uint8(uint64(num)&0x7f | 0x80) + dAtA29[j28] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j30++ + j28++ } - dAtA31[j30] = uint8(num) - j30++ + dAtA29[j28] = uint8(num) + j28++ } - i -= j30 - copy(dAtA[i:], dAtA31[:j30]) - i = encodeVarintScpb(dAtA, i, uint64(j30)) + i -= j28 + copy(dAtA[i:], dAtA29[:j28]) + i = encodeVarintScpb(dAtA, i, uint64(j28)) i-- dAtA[i] = 0x12 } @@ -2121,20 +2072,20 @@ func (m *Table) MarshalToSizedBuffer(dAtA []byte) (int, error) { var l int _ = l if len(m.DependedOnBy) > 0 { - dAtA33 := make([]byte, len(m.DependedOnBy)*10) - var j32 int + dAtA31 := make([]byte, len(m.DependedOnBy)*10) + var j30 int for _, num := range m.DependedOnBy { for num >= 1<<7 { - dAtA33[j32] = uint8(uint64(num)&0x7f | 0x80) + dAtA31[j30] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j32++ + j30++ } - dAtA33[j32] = uint8(num) - j32++ + dAtA31[j30] = uint8(num) + j30++ } - i -= j32 - copy(dAtA[i:], dAtA33[:j32]) - i = encodeVarintScpb(dAtA, i, uint64(j32)) + i -= j30 + copy(dAtA[i:], dAtA31[:j30]) + i = encodeVarintScpb(dAtA, i, uint64(j30)) i-- dAtA[i] = 0x12 } @@ -2207,20 +2158,20 @@ func (m *OutboundForeignKey) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x32 } if len(m.ReferenceColumns) > 0 { - dAtA35 := make([]byte, len(m.ReferenceColumns)*10) - var j34 int + dAtA33 := make([]byte, len(m.ReferenceColumns)*10) + var j32 int for _, num := range m.ReferenceColumns { for num >= 1<<7 { - dAtA35[j34] = uint8(uint64(num)&0x7f | 0x80) + dAtA33[j32] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j34++ + j32++ } - dAtA35[j34] = uint8(num) - j34++ + dAtA33[j32] = uint8(num) + j32++ } - i -= j34 - copy(dAtA[i:], dAtA35[:j34]) - i = encodeVarintScpb(dAtA, i, uint64(j34)) + i -= j32 + copy(dAtA[i:], dAtA33[:j32]) + i = encodeVarintScpb(dAtA, i, uint64(j32)) i-- dAtA[i] = 0x2a } @@ -2230,20 +2181,20 @@ func (m *OutboundForeignKey) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x20 } if len(m.OriginColumns) > 0 { - dAtA37 := make([]byte, len(m.OriginColumns)*10) - var j36 int + dAtA35 := make([]byte, len(m.OriginColumns)*10) + var j34 int for _, num := range m.OriginColumns { for num >= 1<<7 { - dAtA37[j36] = uint8(uint64(num)&0x7f | 0x80) + dAtA35[j34] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j36++ + j34++ } - dAtA37[j36] = uint8(num) - j36++ + dAtA35[j34] = uint8(num) + j34++ } - i -= j36 - copy(dAtA[i:], dAtA37[:j36]) - i = encodeVarintScpb(dAtA, i, uint64(j36)) + i -= j34 + copy(dAtA[i:], dAtA35[:j34]) + i = encodeVarintScpb(dAtA, i, uint64(j34)) i-- dAtA[i] = 0x1a } @@ -2283,20 +2234,20 @@ func (m *InboundForeignKey) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x32 } if len(m.ReferenceColumns) > 0 { - dAtA39 := make([]byte, len(m.ReferenceColumns)*10) - var j38 int + dAtA37 := make([]byte, len(m.ReferenceColumns)*10) + var j36 int for _, num := range m.ReferenceColumns { for num >= 1<<7 { - dAtA39[j38] = uint8(uint64(num)&0x7f | 0x80) + dAtA37[j36] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j38++ + j36++ } - dAtA39[j38] = uint8(num) - j38++ + dAtA37[j36] = uint8(num) + j36++ } - i -= j38 - copy(dAtA[i:], dAtA39[:j38]) - i = encodeVarintScpb(dAtA, i, uint64(j38)) + i -= j36 + copy(dAtA[i:], dAtA37[:j36]) + i = encodeVarintScpb(dAtA, i, uint64(j36)) i-- dAtA[i] = 0x2a } @@ -2306,20 +2257,20 @@ func (m *InboundForeignKey) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x20 } if len(m.OriginColumns) > 0 { - dAtA41 := make([]byte, len(m.OriginColumns)*10) - var j40 int + dAtA39 := make([]byte, len(m.OriginColumns)*10) + var j38 int for _, num := range m.OriginColumns { for num >= 1<<7 { - dAtA41[j40] = uint8(uint64(num)&0x7f | 0x80) + dAtA39[j38] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j40++ + j38++ } - dAtA41[j40] = uint8(num) - j40++ + dAtA39[j38] = uint8(num) + j38++ } - i -= j40 - copy(dAtA[i:], dAtA41[:j40]) - i = encodeVarintScpb(dAtA, i, uint64(j40)) + i -= j38 + copy(dAtA[i:], dAtA39[:j38]) + i = encodeVarintScpb(dAtA, i, uint64(j38)) i-- dAtA[i] = 0x1a } @@ -2526,19 +2477,6 @@ func (m *PrimaryIndex) Size() (n int) { if m.OtherPrimaryIndexID != 0 { n += 1 + sovScpb(uint64(m.OtherPrimaryIndexID)) } - if len(m.StoreColumnIDs) > 0 { - l = 0 - for _, e := range m.StoreColumnIDs { - l += sovScpb(uint64(e)) - } - n += 1 + sovScpb(uint64(l)) + l - } - if len(m.StoreColumnNames) > 0 { - for _, s := range m.StoreColumnNames { - l = len(s) - n += 1 + l + sovScpb(uint64(l)) - } - } return n } @@ -3866,114 +3804,6 @@ func (m *PrimaryIndex) Unmarshal(dAtA []byte) error { break } } - case 4: - if wireType == 0 { - var v github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ColumnID - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowScpb - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ColumnID(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.StoreColumnIDs = append(m.StoreColumnIDs, v) - } else if wireType == 2 { - var packedLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowScpb - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - packedLen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if packedLen < 0 { - return ErrInvalidLengthScpb - } - postIndex := iNdEx + packedLen - if postIndex < 0 { - return ErrInvalidLengthScpb - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - var elementCount int - var count int - for _, integer := range dAtA[iNdEx:postIndex] { - if integer < 128 { - count++ - } - } - elementCount = count - if elementCount != 0 && len(m.StoreColumnIDs) == 0 { - m.StoreColumnIDs = make([]github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ColumnID, 0, elementCount) - } - for iNdEx < postIndex { - var v github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ColumnID - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowScpb - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - v |= github_com_cockroachdb_cockroach_pkg_sql_catalog_descpb.ColumnID(b&0x7F) << shift - if b < 0x80 { - break - } - } - m.StoreColumnIDs = append(m.StoreColumnIDs, v) - } - } else { - return fmt.Errorf("proto: wrong wireType = %d for field StoreColumnIDs", wireType) - } - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field StoreColumnNames", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowScpb - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthScpb - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthScpb - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.StoreColumnNames = append(m.StoreColumnNames, string(dAtA[iNdEx:postIndex])) - iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipScpb(dAtA[iNdEx:]) diff --git a/pkg/sql/schemachanger/scpb/scpb.proto b/pkg/sql/schemachanger/scpb/scpb.proto index 9dd733ad0743..683ae8d2f024 100644 --- a/pkg/sql/schemachanger/scpb/scpb.proto +++ b/pkg/sql/schemachanger/scpb/scpb.proto @@ -68,8 +68,6 @@ message PrimaryIndex { uint32 table_id = 1 [(gogoproto.customname) = "TableID", (gogoproto.casttype) = "github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.ID"]; cockroach.sql.sqlbase.IndexDescriptor index = 2 [(gogoproto.nullable) = false]; uint32 other_primary_index_id = 3 [(gogoproto.customname) = "OtherPrimaryIndexID", (gogoproto.casttype) = "github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.IndexID"]; - repeated uint32 store_column_ids = 4 [(gogoproto.customname) = "StoreColumnIDs", (gogoproto.casttype) = "github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb.ColumnID"]; - repeated string store_column_names = 5 [(gogoproto.customname) = "StoreColumnNames"]; } message SecondaryIndex { diff --git a/pkg/sql/schemachanger/scplan/rules.go b/pkg/sql/schemachanger/scplan/rules.go index 1837677a93d2..2373937a5e71 100644 --- a/pkg/sql/schemachanger/scplan/rules.go +++ b/pkg/sql/schemachanger/scplan/rules.go @@ -11,7 +11,6 @@ package scplan import ( - "github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb" "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scop" "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scpb" ) @@ -24,7 +23,7 @@ func columnInSecondaryIndex(this *scpb.Column, that *scpb.SecondaryIndex) bool { func columnInPrimaryIndex(this *scpb.Column, that *scpb.PrimaryIndex) bool { return this.TableID == that.TableID && indexContainsColumn(&that.Index, this.Column.ID) || - columnsContainsID(that.StoreColumnIDs, this.Column.ID) + columnsContainsID(that.Index.StoreColumnIDs, this.Column.ID) } func primaryIndexContainsColumn(this *scpb.PrimaryIndex, that *scpb.Column) bool { @@ -632,13 +631,9 @@ var rules = map[scpb.Element]targetRules{ { nextState: scpb.State_DELETE_ONLY, op: func(this *scpb.PrimaryIndex) scop.Op { - idx := this.Index - idx.StoreColumnNames = this.StoreColumnNames - idx.StoreColumnIDs = this.StoreColumnIDs - idx.EncodingType = descpb.PrimaryIndexEncoding return &scop.MakeAddedIndexDeleteOnly{ TableID: this.TableID, - Index: idx, + Index: this.Index, } }, }, @@ -724,13 +719,9 @@ var rules = map[scpb.Element]targetRules{ nextState: scpb.State_DELETE_AND_WRITE_ONLY, op: func(this *scpb.PrimaryIndex) scop.Op { // Most of this logic is taken from MakeMutationComplete(). - idx := this.Index - idx.StoreColumnIDs = this.StoreColumnIDs - idx.StoreColumnNames = this.StoreColumnNames - idx.EncodingType = descpb.PrimaryIndexEncoding return &scop.MakeDroppedPrimaryIndexDeleteAndWriteOnly{ TableID: this.TableID, - Index: idx, + Index: this.Index, } }, }, diff --git a/pkg/sql/schemachanger/scplan/testdata/alter_table b/pkg/sql/schemachanger/scplan/testdata/alter_table index 141168c577dd..32fc7bda9b23 100644 --- a/pkg/sql/schemachanger/scplan/testdata/alter_table +++ b/pkg/sql/schemachanger/scplan/testdata/alter_table @@ -66,6 +66,10 @@ Stage 4 KeyColumnNames: - i Name: new_primary_key + StoreColumnIDs: + - 2 + StoreColumnNames: + - j Unique: true Version: 4 TableID: 52 @@ -157,6 +161,10 @@ Stage 4 KeyColumnNames: - i Name: new_primary_key + StoreColumnIDs: + - 2 + StoreColumnNames: + - j Unique: true Version: 4 TableID: 52 @@ -266,6 +274,12 @@ Stage 4 KeyColumnNames: - i Name: new_primary_key + StoreColumnIDs: + - 2 + - 3 + StoreColumnNames: + - j + - k Unique: true Version: 4 TableID: 52 @@ -360,6 +374,10 @@ Stage 4 KeyColumnNames: - i Name: new_primary_key + StoreColumnIDs: + - 2 + StoreColumnNames: + - a Unique: true Version: 4 TableID: 52 @@ -500,6 +518,10 @@ Stage 4 KeyColumnNames: - i Name: new_primary_key + StoreColumnIDs: + - 2 + StoreColumnNames: + - a Unique: true Version: 4 TableID: 52 @@ -533,8 +555,10 @@ Stage 4 Name: new_primary_key StoreColumnIDs: - 1 + - 3 StoreColumnNames: - j + - b Unique: true Version: 4 TableID: 53