Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@ func (h *Handle) InitializeTenant(ctx context.Context, tenID roachpb.TenantID) *
SpanConfig: h.scKnobs,
GCJob: &tenantGCJobKnobs,
UpgradeManager: serverUpgradeKnobs,
SQLExecutor: &sql.ExecutorTestingKnobs{
UseTransactionalDescIDGenerator: true,
},
},
}
var err error
Expand Down
4 changes: 4 additions & 0 deletions pkg/sql/planner.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/catalog"
"github.com/cockroachdb/cockroach/pkg/sql/catalog/catsessiondata"
"github.com/cockroachdb/cockroach/pkg/sql/catalog/colinfo"
"github.com/cockroachdb/cockroach/pkg/sql/catalog/descidgen"
"github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb"
"github.com/cockroachdb/cockroach/pkg/sql/catalog/descs"
"github.com/cockroachdb/cockroach/pkg/sql/catalog/lease"
Expand Down Expand Up @@ -462,6 +463,9 @@ func newInternalPlanner(
p.extendedEvalCtx.NodeID = execCfg.NodeInfo.NodeID
p.extendedEvalCtx.Locality = execCfg.Locality
p.extendedEvalCtx.DescIDGenerator = execCfg.DescIDGenerator
if execCfg.TestingKnobs.UseTransactionalDescIDGenerator && txn != nil {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah nice find. this probably would have been affecting other tests too.

p.extendedEvalCtx.DescIDGenerator = descidgen.NewTransactionalGenerator(execCfg.Settings, execCfg.Codec, txn)
}

p.sessionDataMutatorIterator = smi

Expand Down