diff --git a/go.mod b/go.mod index 931f85ebab..400054fe48 100644 --- a/go.mod +++ b/go.mod @@ -12,7 +12,7 @@ require ( github.com/google/go-cmp v0.5.2 github.com/google/gofuzz v1.2.0 // indirect github.com/imdario/mergo v0.3.8 - github.com/openshift/api v0.0.0-20210405165116-47be53705a13 + github.com/openshift/api v0.0.0-20210407153912-eab5407a8748 github.com/openshift/build-machinery-go v0.0.0-20210209125900-0da259a2c359 github.com/openshift/client-go v0.0.0-20210331195552-cf6c2669e01f github.com/openshift/library-go v0.0.0-20210406144447-d9cdfbd844ea diff --git a/go.sum b/go.sum index 20d8389d9b..e09ecf396e 100644 --- a/go.sum +++ b/go.sum @@ -419,8 +419,8 @@ github.com/opencontainers/go-digest v1.0.0-rc1/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQ github.com/opencontainers/image-spec v1.0.1/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0= github.com/openshift/api v0.0.0-20210331162552-3e31249e6a55/go.mod h1:dZ4kytOo3svxJHNYd0J55hwe/6IQG5gAUHUE0F3Jkio= github.com/openshift/api v0.0.0-20210331193751-3acddb19d360/go.mod h1:dZ4kytOo3svxJHNYd0J55hwe/6IQG5gAUHUE0F3Jkio= -github.com/openshift/api v0.0.0-20210405165116-47be53705a13 h1:/om0/+5m4SY41YngmEjV53cqeamZ2BE5Qfz7QCXA8BQ= -github.com/openshift/api v0.0.0-20210405165116-47be53705a13/go.mod h1:dZ4kytOo3svxJHNYd0J55hwe/6IQG5gAUHUE0F3Jkio= +github.com/openshift/api v0.0.0-20210407153912-eab5407a8748 h1:xgMrPAdyZP8B1gKaLjLIPWRsIvxWs7MPcYqgKeh2k8c= +github.com/openshift/api v0.0.0-20210407153912-eab5407a8748/go.mod h1:dZ4kytOo3svxJHNYd0J55hwe/6IQG5gAUHUE0F3Jkio= github.com/openshift/build-machinery-go v0.0.0-20210209125900-0da259a2c359 h1:ehSDsWQiUVzJZrSEXMC7ceV9JIPEyTYqrpqu3m4Wa08= github.com/openshift/build-machinery-go v0.0.0-20210209125900-0da259a2c359/go.mod h1:b1BuldmJlbA/xYtdZvKi+7j5YGB44qJUJDZ9zwiNCfE= github.com/openshift/client-go v0.0.0-20210331195552-cf6c2669e01f h1:MAFVN4yW6pPSaTa1i+4Xp6FfVzZRFRETsnPfwz6VBXM= diff --git a/vendor/github.com/openshift/api/Makefile b/vendor/github.com/openshift/api/Makefile index df3697c8d7..d2d15949d5 100644 --- a/vendor/github.com/openshift/api/Makefile +++ b/vendor/github.com/openshift/api/Makefile @@ -20,6 +20,7 @@ CONTROLLER_GEN_VERSION :=v0.2.5 # $3 - manifests # $4 - output $(call add-crd-gen,authorization,./authorization/v1,./authorization/v1,./authorization/v1) +$(call add-crd-gen,apiserver,./apiserver/v1,./apiserver/v1,./apiserver/v1) $(call add-crd-gen,config,./config/v1,./config/v1,./config/v1) $(call add-crd-gen,helm,./helm/v1beta1,./helm/v1beta1,./helm/v1beta1) $(call add-crd-gen,console,./console/v1,./console/v1,./console/v1) diff --git a/vendor/github.com/openshift/api/apiserver/install.go b/vendor/github.com/openshift/api/apiserver/install.go new file mode 100644 index 0000000000..c0cf2ac29c --- /dev/null +++ b/vendor/github.com/openshift/api/apiserver/install.go @@ -0,0 +1,22 @@ +package apiserver + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + + v1 "github.com/openshift/api/apiserver/v1" +) + +var ( + schemeBuilder = runtime.NewSchemeBuilder(v1.Install) + // Install is a function which adds every version of this group to a scheme + Install = schemeBuilder.AddToScheme +) + +func Resource(resource string) schema.GroupResource { + return schema.GroupResource{Group: "apiserver.openshift.io", Resource: resource} +} + +func Kind(kind string) schema.GroupKind { + return schema.GroupKind{Group: "apiserver.openshift.io", Kind: kind} +} diff --git a/vendor/github.com/openshift/api/apiserver/v1/apiserver.openshift.io_deprecatedapirequests.yaml b/vendor/github.com/openshift/api/apiserver/v1/apiserver.openshift.io_deprecatedapirequests.yaml new file mode 100644 index 0000000000..89beaaa9d5 --- /dev/null +++ b/vendor/github.com/openshift/api/apiserver/v1/apiserver.openshift.io_deprecatedapirequests.yaml @@ -0,0 +1,247 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + annotations: + include.release.openshift.io/self-managed-high-availability: "true" + include.release.openshift.io/single-node-developer: "true" + name: deprecatedapirequests.apiserver.openshift.io +spec: + group: apiserver.openshift.io + names: + kind: DeprecatedAPIRequest + listKind: DeprecatedAPIRequestList + plural: deprecatedapirequests + singular: deprecatedapirequest + scope: Cluster + versions: + - name: v1 + schema: + openAPIV3Schema: + description: DeprecatedAPIRequest tracts requests made to a deprecated API. + The instance name should be of the form `resource.version.group`, matching + the deprecated resource. + type: object + required: + - spec + properties: + apiVersion: + description: 'APIVersion defines the versioned schema of this representation + of an object. Servers should convert recognized schemas to the latest + internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' + type: string + kind: + description: 'Kind is a string value representing the REST resource this + object represents. Servers may infer this from the endpoint the client + submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' + type: string + metadata: + type: object + spec: + description: spec defines the characteristics of the resource. + type: object + properties: + removedRelease: + description: removedRelease is when the API will be removed. + type: string + maxLength: 64 + minLength: 3 + pattern: ^[0-9][0-9]*\.[0-9][0-9]*$ + status: + description: status contains the observed state of the resource. + type: object + properties: + conditions: + description: conditions contains details of the current status of + this API Resource. + type: array + items: + description: "Condition contains details for one aspect of the current + state of this API Resource. --- This struct is intended for direct + use as an array at the field path .status.conditions. For example, + type FooStatus struct{ // Represents the observations of a + foo's current state. // Known .status.conditions.type are: + \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type + \ // +patchStrategy=merge // +listType=map // +listMapKey=type + \ Conditions []metav1.Condition `json:\"conditions,omitempty\" + patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` + \n // other fields }" + type: object + required: + - lastTransitionTime + - message + - reason + - status + - type + properties: + lastTransitionTime: + description: lastTransitionTime is the last time the condition + transitioned from one status to another. This should be when + the underlying condition changed. If that is not known, then + using the time when the API field changed is acceptable. + type: string + format: date-time + message: + description: message is a human readable message indicating + details about the transition. This may be an empty string. + type: string + maxLength: 32768 + observedGeneration: + description: observedGeneration represents the .metadata.generation + that the condition was set based upon. For instance, if .metadata.generation + is currently 12, but the .status.conditions[x].observedGeneration + is 9, the condition is out of date with respect to the current + state of the instance. + type: integer + format: int64 + minimum: 0 + reason: + description: reason contains a programmatic identifier indicating + the reason for the condition's last transition. Producers + of specific condition types may define expected values and + meanings for this field, and whether the values are considered + a guaranteed API. The value should be a CamelCase string. + This field may not be empty. + type: string + maxLength: 1024 + minLength: 1 + pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$ + status: + description: status of the condition, one of True, False, Unknown. + type: string + enum: + - "True" + - "False" + - Unknown + type: + description: type of condition in CamelCase or in foo.example.com/CamelCase. + --- Many .condition.type values are consistent across resources + like Available, but because arbitrary conditions can be useful + (see .node.status.conditions), the ability to deconflict is + important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt) + type: string + maxLength: 316 + pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$ + requestsLast24h: + description: requestsLast24h contains request history for the last + 24 hours, indexed by the hour, so 12:00AM-12:59 is in index 0, 6am-6:59am + is index 6, etc. The index of the current hour is updated live and + then duplicated into the requestsLastHour field. + type: array + items: + description: RequestLog logs request for various nodes. + type: object + properties: + nodes: + description: nodes contains logs of requests per node. + type: array + items: + description: NodeRequestLog contains logs of requests to a + certain node. + type: object + properties: + lastUpdate: + description: lastUpdate should *always* being within the + hour this is for. This is a time indicating the last + moment the server is recording for, not the actual update + time. + type: string + format: date-time + nodeName: + description: nodeName where the request are being handled. + type: string + users: + description: users contains request details by top 10 + users. Note that because in the case of an apiserver + restart the list of top 10 users is determined on a + best-effort basis, the list might be imprecise. + type: array + items: + description: RequestUser contains logs of a user's requests. + type: object + properties: + count: + description: count of requests. + type: integer + requests: + description: requests details by verb. + type: array + items: + description: RequestCount counts requests by API + request verb. + type: object + properties: + count: + description: count of requests for verb. + type: integer + verb: + description: verb of API request (get, list, + create, etc...) + type: string + username: + description: userName that made the request. + type: string + requestsLastHour: + description: requestsLastHour contains request history for the current + hour. This is porcelain to make the API easier to read by humans + seeing if they addressed a problem. This field is reset on the hour. + type: object + properties: + nodes: + description: nodes contains logs of requests per node. + type: array + items: + description: NodeRequestLog contains logs of requests to a certain + node. + type: object + properties: + lastUpdate: + description: lastUpdate should *always* being within the + hour this is for. This is a time indicating the last + moment the server is recording for, not the actual update + time. + type: string + format: date-time + nodeName: + description: nodeName where the request are being handled. + type: string + users: + description: users contains request details by top 10 users. + Note that because in the case of an apiserver restart + the list of top 10 users is determined on a best-effort + basis, the list might be imprecise. + type: array + items: + description: RequestUser contains logs of a user's requests. + type: object + properties: + count: + description: count of requests. + type: integer + requests: + description: requests details by verb. + type: array + items: + description: RequestCount counts requests by API + request verb. + type: object + properties: + count: + description: count of requests for verb. + type: integer + verb: + description: verb of API request (get, list, + create, etc...) + type: string + username: + description: userName that made the request. + type: string + served: true + storage: true + subresources: + status: {} +status: + acceptedNames: + kind: "" + plural: "" + conditions: [] + storedVersions: [] diff --git a/vendor/github.com/openshift/api/apiserver/v1/doc.go b/vendor/github.com/openshift/api/apiserver/v1/doc.go new file mode 100644 index 0000000000..cc6a8aa617 --- /dev/null +++ b/vendor/github.com/openshift/api/apiserver/v1/doc.go @@ -0,0 +1,8 @@ +// +k8s:deepcopy-gen=package,register +// +k8s:defaulter-gen=TypeMeta +// +k8s:openapi-gen=true + +// +kubebuilder:validation:Optional +// +groupName=apiserver.openshift.io +// Package v1 is the v1 version of the API. +package v1 diff --git a/vendor/github.com/openshift/api/apiserver/v1/register.go b/vendor/github.com/openshift/api/apiserver/v1/register.go new file mode 100644 index 0000000000..82d3584c41 --- /dev/null +++ b/vendor/github.com/openshift/api/apiserver/v1/register.go @@ -0,0 +1,38 @@ +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +var ( + GroupName = "apiserver.openshift.io" + GroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + schemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) + // Install is a function which adds this version to a scheme + Install = schemeBuilder.AddToScheme + + // SchemeGroupVersion generated code relies on this name + // Deprecated + SchemeGroupVersion = GroupVersion + // AddToScheme exists solely to keep the old generators creating valid code + // DEPRECATED + AddToScheme = schemeBuilder.AddToScheme +) + +// Resource generated code relies on this being here, but it logically belongs to the group +// DEPRECATED +func Resource(resource string) schema.GroupResource { + return schema.GroupResource{Group: GroupName, Resource: resource} +} + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(GroupVersion, + &DeprecatedAPIRequest{}, + &DeprecatedAPIRequestList{}, + ) + metav1.AddToGroupVersion(scheme, GroupVersion) + return nil +} diff --git a/vendor/github.com/openshift/api/apiserver/v1/types_deprecatedapirequest.go b/vendor/github.com/openshift/api/apiserver/v1/types_deprecatedapirequest.go new file mode 100644 index 0000000000..9caf3f6ab4 --- /dev/null +++ b/vendor/github.com/openshift/api/apiserver/v1/types_deprecatedapirequest.go @@ -0,0 +1,114 @@ +// Package v1 is an api version in the apiserver.openshift.io group +package v1 + +import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +// +genclient +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// +kubebuilder:resource:scope="Cluster" +// +kubebuilder:subresource:status +// +genclient:nonNamespaced + +// DeprecatedAPIRequest tracts requests made to a deprecated API. The instance name should +// be of the form `resource.version.group`, matching the deprecated resource. +type DeprecatedAPIRequest struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // spec defines the characteristics of the resource. + // +kubebuilder:validation:Required + // +required + Spec DeprecatedAPIRequestSpec `json:"spec"` + + // status contains the observed state of the resource. + Status DeprecatedAPIRequestStatus `json:"status,omitempty"` +} + +type DeprecatedAPIRequestSpec struct { + // removedRelease is when the API will be removed. + // +kubebuilder:validation:Pattern=^[0-9][0-9]*\.[0-9][0-9]*$ + // +kubebuilder:validation:MinLength=3 + // +kubebuilder:validation:MaxLength=64 + // +required + RemovedRelease string `json:"removedRelease"` +} + +// +k8s:deepcopy-gen=true +type DeprecatedAPIRequestStatus struct { + + // conditions contains details of the current status of this API Resource. + // +patchMergeKey=type + // +patchStrategy=merge + Conditions []metav1.Condition `json:"conditions"` + + // requestsLastHour contains request history for the current hour. This is porcelain to make the API + // easier to read by humans seeing if they addressed a problem. This field is reset on the hour. + RequestsLastHour RequestLog `json:"requestsLastHour"` + + // requestsLast24h contains request history for the last 24 hours, indexed by the hour, so + // 12:00AM-12:59 is in index 0, 6am-6:59am is index 6, etc. The index of the current hour + // is updated live and then duplicated into the requestsLastHour field. + RequestsLast24h []RequestLog `json:"requestsLast24h"` +} + +// RequestLog logs request for various nodes. +type RequestLog struct { + + // nodes contains logs of requests per node. + Nodes []NodeRequestLog `json:"nodes"` +} + +// NodeRequestLog contains logs of requests to a certain node. +type NodeRequestLog struct { + + // nodeName where the request are being handled. + NodeName string `json:"nodeName"` + + // lastUpdate should *always* being within the hour this is for. This is a time indicating + // the last moment the server is recording for, not the actual update time. + LastUpdate metav1.Time `json:"lastUpdate"` + + // users contains request details by top 10 users. Note that because in the case of an apiserver + // restart the list of top 10 users is determined on a best-effort basis, the list might be imprecise. + Users []RequestUser `json:"users"` +} + +type DeprecatedAPIRequestConditionType string + +const ( + // UsedInPastDay condition indicates a request has been made against the deprecated api in the last 24h. + UsedInPastDay DeprecatedAPIRequestConditionType = "UsedInPastDay" +) + +// RequestUser contains logs of a user's requests. +type RequestUser struct { + + // userName that made the request. + UserName string `json:"username"` + + // count of requests. + Count int `json:"count"` + + // requests details by verb. + Requests []RequestCount `json:"requests"` +} + +// RequestCount counts requests by API request verb. +type RequestCount struct { + + // verb of API request (get, list, create, etc...) + Verb string `json:"verb"` + + // count of requests for verb. + Count int `json:"count"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// DeprecatedAPIRequestList is a list of DeprecatedAPIRequest resources. +type DeprecatedAPIRequestList struct { + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata"` + + Items []DeprecatedAPIRequest `json:"items"` +} diff --git a/vendor/github.com/openshift/api/apiserver/v1/zz_generated.deepcopy.go b/vendor/github.com/openshift/api/apiserver/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..3fb611c1bb --- /dev/null +++ b/vendor/github.com/openshift/api/apiserver/v1/zz_generated.deepcopy.go @@ -0,0 +1,202 @@ +// +build !ignore_autogenerated + +// Code generated by deepcopy-gen. DO NOT EDIT. + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeprecatedAPIRequest) DeepCopyInto(out *DeprecatedAPIRequest) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + out.Spec = in.Spec + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeprecatedAPIRequest. +func (in *DeprecatedAPIRequest) DeepCopy() *DeprecatedAPIRequest { + if in == nil { + return nil + } + out := new(DeprecatedAPIRequest) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *DeprecatedAPIRequest) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeprecatedAPIRequestList) DeepCopyInto(out *DeprecatedAPIRequestList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]DeprecatedAPIRequest, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeprecatedAPIRequestList. +func (in *DeprecatedAPIRequestList) DeepCopy() *DeprecatedAPIRequestList { + if in == nil { + return nil + } + out := new(DeprecatedAPIRequestList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *DeprecatedAPIRequestList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeprecatedAPIRequestSpec) DeepCopyInto(out *DeprecatedAPIRequestSpec) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeprecatedAPIRequestSpec. +func (in *DeprecatedAPIRequestSpec) DeepCopy() *DeprecatedAPIRequestSpec { + if in == nil { + return nil + } + out := new(DeprecatedAPIRequestSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *DeprecatedAPIRequestStatus) DeepCopyInto(out *DeprecatedAPIRequestStatus) { + *out = *in + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]metav1.Condition, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + in.RequestsLastHour.DeepCopyInto(&out.RequestsLastHour) + if in.RequestsLast24h != nil { + in, out := &in.RequestsLast24h, &out.RequestsLast24h + *out = make([]RequestLog, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DeprecatedAPIRequestStatus. +func (in *DeprecatedAPIRequestStatus) DeepCopy() *DeprecatedAPIRequestStatus { + if in == nil { + return nil + } + out := new(DeprecatedAPIRequestStatus) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *NodeRequestLog) DeepCopyInto(out *NodeRequestLog) { + *out = *in + in.LastUpdate.DeepCopyInto(&out.LastUpdate) + if in.Users != nil { + in, out := &in.Users, &out.Users + *out = make([]RequestUser, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeRequestLog. +func (in *NodeRequestLog) DeepCopy() *NodeRequestLog { + if in == nil { + return nil + } + out := new(NodeRequestLog) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RequestCount) DeepCopyInto(out *RequestCount) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RequestCount. +func (in *RequestCount) DeepCopy() *RequestCount { + if in == nil { + return nil + } + out := new(RequestCount) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RequestLog) DeepCopyInto(out *RequestLog) { + *out = *in + if in.Nodes != nil { + in, out := &in.Nodes, &out.Nodes + *out = make([]NodeRequestLog, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RequestLog. +func (in *RequestLog) DeepCopy() *RequestLog { + if in == nil { + return nil + } + out := new(RequestLog) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RequestUser) DeepCopyInto(out *RequestUser) { + *out = *in + if in.Requests != nil { + in, out := &in.Requests, &out.Requests + *out = make([]RequestCount, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RequestUser. +func (in *RequestUser) DeepCopy() *RequestUser { + if in == nil { + return nil + } + out := new(RequestUser) + in.DeepCopyInto(out) + return out +} diff --git a/vendor/github.com/openshift/api/apiserver/v1/zz_generated.swagger_doc_generated.go b/vendor/github.com/openshift/api/apiserver/v1/zz_generated.swagger_doc_generated.go new file mode 100644 index 0000000000..66f3dc582a --- /dev/null +++ b/vendor/github.com/openshift/api/apiserver/v1/zz_generated.swagger_doc_generated.go @@ -0,0 +1,91 @@ +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_DeprecatedAPIRequest = map[string]string{ + "": "DeprecatedAPIRequest tracts requests made to a deprecated API. The instance name should be of the form `resource.version.group`, matching the deprecated resource.", + "spec": "spec defines the characteristics of the resource.", + "status": "status contains the observed state of the resource.", +} + +func (DeprecatedAPIRequest) SwaggerDoc() map[string]string { + return map_DeprecatedAPIRequest +} + +var map_DeprecatedAPIRequestList = map[string]string{ + "": "DeprecatedAPIRequestList is a list of DeprecatedAPIRequest resources.", +} + +func (DeprecatedAPIRequestList) SwaggerDoc() map[string]string { + return map_DeprecatedAPIRequestList +} + +var map_DeprecatedAPIRequestSpec = map[string]string{ + "removedRelease": "removedRelease is when the API will be removed.", +} + +func (DeprecatedAPIRequestSpec) SwaggerDoc() map[string]string { + return map_DeprecatedAPIRequestSpec +} + +var map_DeprecatedAPIRequestStatus = map[string]string{ + "conditions": "conditions contains details of the current status of this API Resource.", + "requestsLastHour": "requestsLastHour contains request history for the current hour. This is porcelain to make the API easier to read by humans seeing if they addressed a problem. This field is reset on the hour.", + "requestsLast24h": "requestsLast24h contains request history for the last 24 hours, indexed by the hour, so 12:00AM-12:59 is in index 0, 6am-6:59am is index 6, etc. The index of the current hour is updated live and then duplicated into the requestsLastHour field.", +} + +func (DeprecatedAPIRequestStatus) SwaggerDoc() map[string]string { + return map_DeprecatedAPIRequestStatus +} + +var map_NodeRequestLog = map[string]string{ + "": "NodeRequestLog contains logs of requests to a certain node.", + "nodeName": "nodeName where the request are being handled.", + "lastUpdate": "lastUpdate should *always* being within the hour this is for. This is a time indicating the last moment the server is recording for, not the actual update time.", + "users": "users contains request details by top 10 users. Note that because in the case of an apiserver restart the list of top 10 users is determined on a best-effort basis, the list might be imprecise.", +} + +func (NodeRequestLog) SwaggerDoc() map[string]string { + return map_NodeRequestLog +} + +var map_RequestCount = map[string]string{ + "": "RequestCount counts requests by API request verb.", + "verb": "verb of API request (get, list, create, etc...)", + "count": "count of requests for verb.", +} + +func (RequestCount) SwaggerDoc() map[string]string { + return map_RequestCount +} + +var map_RequestLog = map[string]string{ + "": "RequestLog logs request for various nodes.", + "nodes": "nodes contains logs of requests per node.", +} + +func (RequestLog) SwaggerDoc() map[string]string { + return map_RequestLog +} + +var map_RequestUser = map[string]string{ + "": "RequestUser contains logs of a user's requests.", + "username": "userName that made the request.", + "count": "count of requests.", + "requests": "requests details by verb.", +} + +func (RequestUser) SwaggerDoc() map[string]string { + return map_RequestUser +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/github.com/openshift/api/config/v1/types_feature.go b/vendor/github.com/openshift/api/config/v1/types_feature.go index e4ee3d19f3..b083e6d1f6 100644 --- a/vendor/github.com/openshift/api/config/v1/types_feature.go +++ b/vendor/github.com/openshift/api/config/v1/types_feature.go @@ -106,8 +106,10 @@ var FeatureSets = map[FeatureSet]*FeatureGateEnabledDisabled{ Disabled: []string{}, }, TechPreviewNoUpgrade: newDefaultFeatures(). - with("CSIDriverAzureDisk"). // sig-storage, jsafrane - with("CSIDriverVSphere"). // sig-storage, jsafrane + with("CSIDriverAzureDisk"). // sig-storage, jsafrane, OCP specific + with("CSIDriverVSphere"). // sig-storage, jsafrane, OCP specific + with("CSIMigrationAWS"). // sig-storage, jsafrane, Kubernetes feature gate + with("CSIMigrationOpenStack"). // sig-storage, jsafrane, Kubernetes feature gate toFeatures(), LatencySensitive: newDefaultFeatures(). with( diff --git a/vendor/github.com/openshift/api/install.go b/vendor/github.com/openshift/api/install.go index 9318743e71..6a5658af50 100644 --- a/vendor/github.com/openshift/api/install.go +++ b/vendor/github.com/openshift/api/install.go @@ -31,6 +31,7 @@ import ( kstoragev1beta1 "k8s.io/api/storage/v1beta1" "k8s.io/apimachinery/pkg/runtime" + "github.com/openshift/api/apiserver" "github.com/openshift/api/apps" "github.com/openshift/api/authorization" "github.com/openshift/api/build" @@ -61,6 +62,7 @@ import ( var ( schemeBuilder = runtime.NewSchemeBuilder( + apiserver.Install, apps.Install, authorization.Install, build.Install, diff --git a/vendor/modules.txt b/vendor/modules.txt index 7b898618db..b44cdf87f1 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -130,9 +130,11 @@ github.com/modern-go/concurrent github.com/modern-go/reflect2 # github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 github.com/munnerz/goautoneg -# github.com/openshift/api v0.0.0-20210405165116-47be53705a13 +# github.com/openshift/api v0.0.0-20210407153912-eab5407a8748 ## explicit github.com/openshift/api +github.com/openshift/api/apiserver +github.com/openshift/api/apiserver/v1 github.com/openshift/api/apps github.com/openshift/api/apps/v1 github.com/openshift/api/authorization