Skip to content

Commit

Permalink
Updated current swf instead of setting a new one
Browse files Browse the repository at this point in the history
Signed-off-by: Helber Belmiro <[email protected]>
  • Loading branch information
hbelmiro committed Jan 2, 2025
1 parent f9c30ca commit 9d96762
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions backend/src/apiserver/resource/resource_manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -604,9 +604,8 @@ func (r *ResourceManager) ReconcileSwfCrs(ctx context.Context) error {
}

if !reflect.DeepEqual(currentScheduledWorkflow.Spec, newScheduledWorkflow.Spec) {
newScheduledWorkflow.Name = currentScheduledWorkflow.Name
newScheduledWorkflow.ResourceVersion = currentScheduledWorkflow.ResourceVersion
err = r.updateSwfCrSpec(ctx, jobs[i].Namespace, newScheduledWorkflow)
currentScheduledWorkflow.Spec = newScheduledWorkflow.Spec
err = r.updateSwfCrSpec(ctx, jobs[i].Namespace, currentScheduledWorkflow)
if err != nil {
if apierrors.IsConflict(errors.Unwrap(err)) {
continue
Expand Down

0 comments on commit 9d96762

Please sign in to comment.