Skip to content

Commit

Permalink
fix: remove the logic that sets datalocality to disable when v2 volum…
Browse files Browse the repository at this point in the history
…e is created

Signed-off-by: jinhong.kim0 <jinhong.kim0@navercorp.com>
  • Loading branch information
hookak authored and derekbit committed Sep 7, 2024
1 parent 3afc8d3 commit cf68998
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions webhook/resources/volume/mutator.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,6 @@ func (v *volumeMutator) Create(request *admission.Request, newObj runtime.Object

// TODO: Remove the mutations below after they are implemented for SPDK volumes
if types.IsDataEngineV2(volume.Spec.DataEngine) {
if volume.Spec.DataLocality != longhorn.DataLocalityDisabled {
patchOps = append(patchOps, fmt.Sprintf(`{"op": "replace", "path": "/spec/dataLocality", "value": "%s"}`, longhorn.DataLocalityDisabled))
}
if volume.Spec.SnapshotDataIntegrity != longhorn.SnapshotDataIntegrityDisabled {
patchOps = append(patchOps, fmt.Sprintf(`{"op": "replace", "path": "/spec/snapshotDataIntegrity", "value": "%s"}`, longhorn.SnapshotDataIntegrityDisabled))
}
Expand Down

0 comments on commit cf68998

Please sign in to comment.