Skip to content

Commit 4bbbacf

Browse files
Merge pull request #534 from planetscale/create-pull-request/patch
Upgrade Vitess Dependency to Latest
2 parents df52a75 + e75084c commit 4bbbacf

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ require (
2121
sigs.k8s.io/controller-runtime v0.16.3
2222
sigs.k8s.io/controller-tools v0.11.3
2323
sigs.k8s.io/kustomize v2.0.3+incompatible
24-
vitess.io/vitess v0.10.3-0.20240216180501-54c6dfc05c5c
24+
vitess.io/vitess v0.10.3-0.20240223204815-d8f771c695b5
2525
)
2626

2727
require (

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -817,5 +817,5 @@ sigs.k8s.io/structured-merge-diff/v4 v4.2.3/go.mod h1:qjx8mGObPmV2aSZepjQjbmb2ih
817817
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
818818
sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E=
819819
sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY=
820-
vitess.io/vitess v0.10.3-0.20240216180501-54c6dfc05c5c h1:4yYHzHcEUIfUlikSaLt+sBZBDyc92qWGgPK2HE32TP4=
821-
vitess.io/vitess v0.10.3-0.20240216180501-54c6dfc05c5c/go.mod h1:IsIXgK8exqVYJoIoAIKG9aW688K8skqzN4wde9zXnZ4=
820+
vitess.io/vitess v0.10.3-0.20240223204815-d8f771c695b5 h1:lAUn/qeJKiLGWhVzFuJsnh0ZzIuSdHxkw63rd/yWa0U=
821+
vitess.io/vitess v0.10.3-0.20240223204815-d8f771c695b5/go.mod h1:IsIXgK8exqVYJoIoAIKG9aW688K8skqzN4wde9zXnZ4=

pkg/controller/vitessshardreplication/reconcile_drain.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import (
2828
topodatapb "vitess.io/vitess/go/vt/proto/topodata"
2929
"vitess.io/vitess/go/vt/topo"
3030
"vitess.io/vitess/go/vt/topo/topoproto"
31+
"vitess.io/vitess/go/vt/vtctl/reparentutil"
3132
"vitess.io/vitess/go/vt/wrangler"
3233

3334
corev1 "k8s.io/api/core/v1"
@@ -312,7 +313,12 @@ func (r *ReconcileVitessShard) reconcileDrain(ctx context.Context, vts *planetsc
312313
if vts.Spec.UsingExternalDatastore() {
313314
reparentErr = r.handleExternalReparent(ctx, vts, wr, newPrimary.Alias, shard.PrimaryAlias)
314315
} else {
315-
reparentErr = wr.PlannedReparentShard(reparentCtx, keyspaceName, vts.Spec.Name, newPrimary.Alias, nil, plannedReparentTimeout, tolerableReplicationLag)
316+
reparentErr = wr.PlannedReparentShard(reparentCtx, keyspaceName, vts.Spec.Name, reparentutil.PlannedReparentOptions{
317+
NewPrimaryAlias: newPrimary.Alias,
318+
AvoidPrimaryAlias: nil,
319+
WaitReplicasTimeout: plannedReparentTimeout,
320+
TolerableReplLag: tolerableReplicationLag,
321+
})
316322
}
317323

318324
if reparentErr != nil {

0 commit comments

Comments
 (0)