Skip to content

Commit

Permalink
fix: Remove the logic that sets dataLocality to disable when an engin…
Browse files Browse the repository at this point in the history
…e v2 volume is created

Signed-off-by: jinhong.kim0 <jinhong.kim0@navercorp.com>
  • Loading branch information
hookak committed Sep 2, 2024
1 parent a1f3e8c commit e26e386
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 @@ -192,9 +192,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 e26e386

Please sign in to comment.