Merge pull request #68195 from luxas/consolidate_componentconfig_code_standards

Automatic merge from submit-queue (batch tested with PRs 67950, 68195). If you want to cherry-pick this change to another branch, please follow the instructions here: https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md.

Consolidate componentconfig code standards

**What this PR does / why we need it**:

This PR fixes a bunch of very small misalignments in ComponentConfig packages:
 - Add sane comments to all functions/variables in componentconfig `register.go` files
 - Make the `register.go` files of componentconfig pkgs follow the same pattern and not differ from each other like they do today.
 - Register the `openapi-gen` tag in all `doc.go` files where the pkg contains _external_ types.
 - Add the `groupName` tag where missing
 - Fix cases where `addKnownTypes` was registered twice in the `SchemeBuilder`
 - Add `Readme` and `OWNERS` files to `Godeps` directories if missing.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```

/assign @sttts @thockin

Kubernetes-commit: a6eb49f0dc9a6d9fecf7ff4a8edeaa382b55ac50
This commit is contained in:
Kubernetes Publisher 2018-09-07 11:19:40 -07:00
commit 75a03c2d43
2 changed files with 59 additions and 55 deletions

106
Godeps/Godeps.json generated
View File

@ -984,215 +984,215 @@
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/apitesting", "ImportPath": "k8s.io/apimachinery/pkg/api/apitesting",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/apitesting/fuzzer", "ImportPath": "k8s.io/apimachinery/pkg/api/apitesting/fuzzer",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/apitesting/roundtrip", "ImportPath": "k8s.io/apimachinery/pkg/api/apitesting/roundtrip",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/equality", "ImportPath": "k8s.io/apimachinery/pkg/api/equality",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/errors", "ImportPath": "k8s.io/apimachinery/pkg/api/errors",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/meta", "ImportPath": "k8s.io/apimachinery/pkg/api/meta",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/resource", "ImportPath": "k8s.io/apimachinery/pkg/api/resource",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/validation", "ImportPath": "k8s.io/apimachinery/pkg/api/validation",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/api/validation/path", "ImportPath": "k8s.io/apimachinery/pkg/api/validation/path",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/apis/meta/fuzzer", "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/fuzzer",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/apis/meta/internalversion", "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/internalversion",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1", "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured", "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1/validation", "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1/validation",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1beta1", "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1beta1",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/conversion", "ImportPath": "k8s.io/apimachinery/pkg/conversion",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/conversion/queryparams", "ImportPath": "k8s.io/apimachinery/pkg/conversion/queryparams",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/fields", "ImportPath": "k8s.io/apimachinery/pkg/fields",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/labels", "ImportPath": "k8s.io/apimachinery/pkg/labels",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime", "ImportPath": "k8s.io/apimachinery/pkg/runtime",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime/schema", "ImportPath": "k8s.io/apimachinery/pkg/runtime/schema",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer", "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/json", "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/json",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/protobuf", "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/protobuf",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/recognizer", "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/recognizer",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/streaming", "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/streaming",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/versioning", "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/versioning",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/selection", "ImportPath": "k8s.io/apimachinery/pkg/selection",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/types", "ImportPath": "k8s.io/apimachinery/pkg/types",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/cache", "ImportPath": "k8s.io/apimachinery/pkg/util/cache",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/clock", "ImportPath": "k8s.io/apimachinery/pkg/util/clock",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/diff", "ImportPath": "k8s.io/apimachinery/pkg/util/diff",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/errors", "ImportPath": "k8s.io/apimachinery/pkg/util/errors",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/framer", "ImportPath": "k8s.io/apimachinery/pkg/util/framer",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/intstr", "ImportPath": "k8s.io/apimachinery/pkg/util/intstr",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/json", "ImportPath": "k8s.io/apimachinery/pkg/util/json",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/mergepatch", "ImportPath": "k8s.io/apimachinery/pkg/util/mergepatch",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/naming", "ImportPath": "k8s.io/apimachinery/pkg/util/naming",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/net", "ImportPath": "k8s.io/apimachinery/pkg/util/net",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/rand", "ImportPath": "k8s.io/apimachinery/pkg/util/rand",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/runtime", "ImportPath": "k8s.io/apimachinery/pkg/util/runtime",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/sets", "ImportPath": "k8s.io/apimachinery/pkg/util/sets",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/strategicpatch", "ImportPath": "k8s.io/apimachinery/pkg/util/strategicpatch",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/uuid", "ImportPath": "k8s.io/apimachinery/pkg/util/uuid",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/validation", "ImportPath": "k8s.io/apimachinery/pkg/util/validation",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/validation/field", "ImportPath": "k8s.io/apimachinery/pkg/util/validation/field",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/wait", "ImportPath": "k8s.io/apimachinery/pkg/util/wait",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/waitgroup", "ImportPath": "k8s.io/apimachinery/pkg/util/waitgroup",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/util/yaml", "ImportPath": "k8s.io/apimachinery/pkg/util/yaml",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/version", "ImportPath": "k8s.io/apimachinery/pkg/version",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/pkg/watch", "ImportPath": "k8s.io/apimachinery/pkg/watch",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/third_party/forked/golang/json", "ImportPath": "k8s.io/apimachinery/third_party/forked/golang/json",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/apimachinery/third_party/forked/golang/reflect", "ImportPath": "k8s.io/apimachinery/third_party/forked/golang/reflect",
"Rev": "6429050ef506887d121f3e7306e894f8900d8a63" "Rev": "cdac837abb323d610ee074068a16915651f888dd"
}, },
{ {
"ImportPath": "k8s.io/client-go/discovery", "ImportPath": "k8s.io/client-go/discovery",

View File

@ -21,7 +21,11 @@ import (
) )
var ( var (
// SchemeBuilder is the scheme builder with scheme init functions to run for this API package
SchemeBuilder runtime.SchemeBuilder SchemeBuilder runtime.SchemeBuilder
// localSchemeBuilder extends the SchemeBuilder instance with the external types. In this package,
// defaulting and conversion init funcs are registered as well.
localSchemeBuilder = &SchemeBuilder localSchemeBuilder = &SchemeBuilder
// AddToScheme is a global function that registers this API group & version to a scheme
AddToScheme = localSchemeBuilder.AddToScheme AddToScheme = localSchemeBuilder.AddToScheme
) )