generated: refactor

This commit is contained in:
Clayton Coleman
2016-11-20 21:55:31 -05:00
parent a43960da3b
commit 35a6bfbcee
626 changed files with 4220 additions and 3890 deletions

View File

@@ -35,6 +35,7 @@ import (
"k8s.io/kubernetes/pkg/conversion"
"k8s.io/kubernetes/pkg/labels"
"k8s.io/kubernetes/pkg/runtime"
"k8s.io/kubernetes/pkg/runtime/schema"
"k8s.io/kubernetes/pkg/util/clock"
"k8s.io/kubernetes/pkg/util/integer"
"k8s.io/kubernetes/pkg/util/sets"
@@ -411,7 +412,7 @@ func getPodsAnnotationSet(template *v1.PodTemplateSpec, object runtime.Object) (
// TODO: this code was not safe previously - as soon as new code came along that switched to v2, old clients
// would be broken upon reading it. This is explicitly hardcoded to v1 to guarantee predictable deployment.
// We need to consistently handle this case of annotation versioning.
codec := api.Codecs.LegacyCodec(unversioned.GroupVersion{Group: v1.GroupName, Version: "v1"})
codec := api.Codecs.LegacyCodec(schema.GroupVersion{Group: v1.GroupName, Version: "v1"})
createdByRefJson, err := runtime.Encode(codec, &v1.SerializedReference{
Reference: *createdByRef,