Skip to content

Commit

Permalink
testing: set UseTransactionalDescIDGenerator testing knob in SQLTrans…
Browse files Browse the repository at this point in the history
…lator tests

Fixes #110242

Set UseTransactionalDescIDGenerator to true to prevent transaction retries from
resulting in different descriptor IDs. Descriptor IDs appear directly in the test
output and must remain stable.

Release note: None
  • Loading branch information
ecwall committed Sep 18, 2023
1 parent 60d895f commit b232ffe
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,11 +111,15 @@ func TestDataDriven(t *testing.T) {
// test cluster).
ManagerDisableJobCreation: true,
}
sqlExecutorKnobs := &sql.ExecutorTestingKnobs{
UseTransactionalDescIDGenerator: true,
}
tsArgs := func(attr string) base.TestServerArgs {
return base.TestServerArgs{
Knobs: base.TestingKnobs{
GCJob: gcTestingKnobs,
SpanConfig: scKnobs,
GCJob: gcTestingKnobs,
SpanConfig: scKnobs,
SQLExecutor: sqlExecutorKnobs,
},
StoreSpecs: []base.StoreSpec{
{InMemory: true, Attributes: roachpb.Attributes{Attrs: []string{attr}}},
Expand Down

0 comments on commit b232ffe

Please sign in to comment.