From 6d74122481b2ebb58716e88df24ab47d94775c56 Mon Sep 17 00:00:00 2001 From: Dimitris Gkanatsios Date: Mon, 24 Jan 2022 19:22:41 -0800 Subject: [PATCH] replacing patch with update during allocation --- pkg/operator/http/allocate.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkg/operator/http/allocate.go b/pkg/operator/http/allocate.go index 81e30f8e..9838079d 100644 --- a/pkg/operator/http/allocate.go +++ b/pkg/operator/http/allocate.go @@ -127,12 +127,11 @@ func (h *allocateHandler) handle(w http.ResponseWriter, r *http.Request) { } // set the relevant status fields - patch := client.MergeFrom(gs.DeepCopy()) gs.Status.State = mpsv1alpha1.GameServerStateActive gs.Status.SessionID = args.SessionID gs.Status.SessionCookie = args.SessionCookie - err = h.client.Status().Patch(r.Context(), &gs, patch) + err = h.client.Status().Update(r.Context(), &gs) if err != nil { internalServerError(ctx, w, err, "cannot update game server") return