Skip to content

Commit

Permalink
fix: allow changing the replica count for a v2 volume
Browse files Browse the repository at this point in the history
Signed-off-by: jinhong.kim0 <[email protected]>
  • Loading branch information
hookak authored and derekbit committed Nov 14, 2024
1 parent 70ac3bc commit 470b53c
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions webhook/resources/volume/validator.go
Original file line number Diff line number Diff line change
Expand Up @@ -251,12 +251,6 @@ func (v *volumeValidator) Update(request *admission.Request, oldObj runtime.Obje
return werror.NewInvalidError(err.Error(), "")
}

if oldVolume.Spec.NumberOfReplicas != newVolume.Spec.NumberOfReplicas {
err := fmt.Errorf("changing number of replicas for volume %v is not supported for data engine %v",
newVolume.Name, newVolume.Spec.DataEngine)
return werror.NewInvalidError(err.Error(), "")
}

if oldVolume.Spec.BackingImage != newVolume.Spec.BackingImage {
err := fmt.Errorf("changing backing image for volume %v is not supported for data engine %v",
newVolume.Name, newVolume.Spec.DataEngine)
Expand Down

0 comments on commit 470b53c

Please sign in to comment.