Skip to content

Commit

Permalink
workload/schemachange: disable recently added DDL
Browse files Browse the repository at this point in the history
This commit disables a handful of recently added operations in the RSW.
Despite numerous test and stress runs there are still plenty of flakes
floating around. Known flakes have been documented as issues and linked
to from `optype.go`

Unfortunately, #116799 may not correlate to a specific DDL and could
still pop up during stress runs. This commit includes some speculative
`WithStack` wrappings to help track down the cause.

Epic: none
Release note: None
  • Loading branch information
chrisseto committed Dec 20, 2023
1 parent 5cf8a2e commit 6bf526e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
7 changes: 5 additions & 2 deletions pkg/workload/schemachange/operation_generator.go
Original file line number Diff line number Diff line change
Expand Up @@ -882,6 +882,9 @@ func (og *operationGenerator) addForeignKeyConstraint(
stmt.potentialExecErrors.add(pgcode.ForeignKeyViolation)
og.potentialCommitErrors.add(pgcode.ForeignKeyViolation)

// TODO why did I add this??
stmt.potentialExecErrors.add(pgcode.FeatureNotSupported)

// It's possible for the table to be dropped concurrently, while we are running
// validation. In which case a potential commit error is an undefined table
// error.
Expand Down Expand Up @@ -3401,12 +3404,12 @@ func (og *operationGenerator) randParentColumnForFkRelation(
)`, subQuery.String())).Scan(&tableSchema, &tableName, &columnName, &typName, &nullable)
if err != nil {
if rbErr := nestedTxn.Rollback(ctx); rbErr != nil {
err = errors.CombineErrors(err, rbErr)
err = errors.CombineErrors(err, errors.WithStack(rbErr))
}
return nil, nil, err
}
if err = nestedTxn.Commit(ctx); err != nil {
return nil, nil, err
return nil, nil, errors.WithStack(err)
}

columnToReturn := column{
Expand Down
10 changes: 5 additions & 5 deletions pkg/workload/schemachange/optype.go
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,8 @@ var opWeights = []int{
alterDatabaseDropSuperRegion: 0, // Disabled and tracked with #111299
alterDatabasePrimaryRegion: 0, // Disabled and tracked with #83831
alterDatabaseSurvivalGoal: 0, // Disabled and tracked with #83831
alterFunctionRename: 1,
alterFunctionSetSchema: 1,
alterFunctionRename: 0, // Disabled and tracked with #116794.
alterFunctionSetSchema: 0, // Disabled and tracked with #116794.
alterTableAddColumn: 1,
alterTableAddConstraintForeignKey: 1, // Tentatively re-enabled, see #91195.
alterTableAddConstraintUnique: 0,
Expand All @@ -279,7 +279,7 @@ var opWeights = []int{
alterTableSetColumnDefault: 1,
alterTableSetColumnNotNull: 1,
alterTypeDropValue: 0, // Disabled and tracked with #114844, #113859, and #115612.
commentOn: 0,
commentOn: 0, // Disabled and tracked with #116795.
createFunction: 1,
createIndex: 1,
createSchema: 1,
Expand All @@ -288,9 +288,9 @@ var opWeights = []int{
createTableAs: 1,
createTypeEnum: 1,
createView: 1,
dropFunction: 1,
dropFunction: 0, // Disabled and tracked with #116794.
dropIndex: 1,
dropSchema: 0, // TODO Make a tracking issue
dropSchema: 0, // Disabled and tracked with 116792.
dropSequence: 1,
dropTable: 1,
dropView: 1,
Expand Down

0 comments on commit 6bf526e

Please sign in to comment.