Files
kubernetes/hack
Kubernetes Submit Queue 4425841ce2 Merge pull request #53158 from liggitt/update-pod-spec-versioned
Automatic merge from submit-queue (batch tested with PRs 53101, 53158, 52165). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Calculate patches for  commands using input version

Fixes #53040

the encoder used for encoding these objects while calculating patches does not have sufficient information to select a correct version when the object does not exist in all versions of a target group (like replicasets not existing in apps/v1beta1)

this PR wraps the encoder to first convert to the same version used to read the object (based on the mapping's GroupVersion)

long-term, we should switch UpdatePodSpecForObject to work on versioned objects and v1.PodSpec and avoid conversion altogether

```release-note
Fixes an issue with `kubectl set` commands encountering conversion errors for ReplicaSet and DaemonSet objects
```
2017-09-29 14:36:19 -07:00
..
2017-02-01 15:18:32 -05:00
2017-07-05 14:24:25 -07:00
2017-09-19 18:10:21 +05:30
2017-07-31 15:10:56 -07:00
2017-07-25 12:11:07 -07:00
2017-08-27 22:20:04 -04:00
2017-08-02 10:39:26 -07:00
2017-06-05 13:18:07 -07:00
2017-05-19 10:17:37 -06:00