Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[release-21.0] Flaky test fix: TestMoveTablesSharded and TestMoveTablesUnsharded (#17343) #17363

Merged
merged 2 commits into from
Dec 22, 2024
Merged
Changes from 1 commit
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
6 changes: 4 additions & 2 deletions go/vt/vttablet/tabletmanager/rpc_vreplication_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,6 @@
// results returned. Followed by ensuring that SwitchTraffic
// and ReverseTraffic also work as expected.
func TestMoveTablesUnsharded(t *testing.T) {
t.Skip("Skipping test temporarily as it is flaky on CI, pending investigation")
ctx, cancel := context.WithCancel(context.Background())
defer cancel()
sourceKs := "sourceks"
Expand Down Expand Up @@ -400,6 +399,9 @@
ftc.vrdbClient.AddInvariant(getCopyStateQuery, &sqltypes.Result{})
tenv.tmc.setVReplicationExecResults(ftc.tablet, getCopyState, &sqltypes.Result{})
ftc.vrdbClient.ExpectRequest(fmt.Sprintf(readAllWorkflows, tenv.dbName, ""), &sqltypes.Result{}, nil)
for _, table := range defaultSchema.TableDefinitions {
tenv.db.AddQuery(fmt.Sprintf(getNonEmptyTableQuery, table.Name), &sqltypes.Result{})

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Code Coverage

tenv.db undefined (type *testEnv has no field or method db)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Code Coverage

undefined: getNonEmptyTableQuery

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (mysql57)

tenv.db undefined (type *testEnv has no field or method db)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (mysql57)

undefined: getNonEmptyTableQuery

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Static Code Checks Etc

tenv.db undefined (type *testEnv has no field or method db)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Static Code Checks Etc

undefined: getNonEmptyTableQuery (typecheck)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (Race)

tenv.db undefined (type *testEnv has no field or method db)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (Race)

undefined: getNonEmptyTableQuery

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (mysql80)

tenv.db undefined (type *testEnv has no field or method db)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (mysql80)

undefined: getNonEmptyTableQuery

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (mysql84)

tenv.db undefined (type *testEnv has no field or method db)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Unit Test (mysql84)

undefined: getNonEmptyTableQuery

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Code Coverage

tenv.db undefined (type *testEnv has no field or method db)

Check failure on line 403 in go/vt/vttablet/tabletmanager/rpc_vreplication_test.go

View workflow job for this annotation

GitHub Actions / Code Coverage

undefined: getNonEmptyTableQuery
}
insert := fmt.Sprintf(`%s values ('%s', 'keyspace:"%s" shard:"%s" filter:{rules:{match:"t1" filter:"select * from t1"}}', '', 0, 0, '%s', 'primary,replica,rdonly', now(), 0, 'Stopped', '%s', %d, 0, 0, '{}')`,
insertVReplicationPrefix, wf, sourceKs, sourceShard, tenv.cells[0], tenv.dbName, vreplID)
ftc.vrdbClient.ExpectRequest(insert, &sqltypes.Result{InsertID: 1}, nil)
Expand Down Expand Up @@ -1764,7 +1766,7 @@
"0",
))
dbClient.AddInvariant(fmt.Sprintf(updatePickedSourceTablet, cell, sourceTabletUID, vreplID), &sqltypes.Result{})

dbClient.AddInvariant("update _vt.vreplication set state='Running', message='' where id=1", &sqltypes.Result{})
}

func addMaterializeSettingsTablesToSchema(ms *vtctldatapb.MaterializeSettings, tenv *testEnv, venv *vtenv.Environment) {
Expand Down
Loading