From ef7fbd20d9554744679bec0f50bf3978267f4550 Mon Sep 17 00:00:00 2001 From: Matt Lord Date: Wed, 27 Dec 2023 14:57:58 -0500 Subject: [PATCH] Fix breakage from concurrent merge We merged these two PRs concurrently and thus ended up with a breakage: - https://github.com/vitessio/vitess/pull/14735 - https://github.com/vitessio/vitess/pull/14786 This PR addresses that issue by using a locally scoped vtgate connection according to the newly established model. Signed-off-by: Matt Lord --- go/test/endtoend/vreplication/vdiff2_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/go/test/endtoend/vreplication/vdiff2_test.go b/go/test/endtoend/vreplication/vdiff2_test.go index 268526e8680..79c9e0c15db 100644 --- a/go/test/endtoend/vreplication/vdiff2_test.go +++ b/go/test/endtoend/vreplication/vdiff2_test.go @@ -172,6 +172,8 @@ func TestVDiff2(t *testing.T) { } func testWorkflow(t *testing.T, vc *VitessCluster, tc *testCase, tks *Keyspace, cells []*Cell) { + vtgateConn := vc.GetVTGateConn(t) + defer vtgateConn.Close() arrTargetShards := strings.Split(tc.targetShards, ",") if tc.typ == "Reshard" { require.NoError(t, vc.AddShards(t, cells, tks, tc.targetShards, 0, 0, tc.tabletBaseID, targetKsOpts))