From f62a3bc5bd5f6e7879591ad35932972843742d7c Mon Sep 17 00:00:00 2001 From: Weston McNamee Date: Fri, 14 Aug 2020 10:37:12 -0700 Subject: [PATCH 1/3] =?UTF-8?q?docs(api):=20=F0=9F=93=9D=20=20Fix=20HPA=20?= =?UTF-8?q?docs=20with=20addition=20of=20"External"=20type?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- staging/src/k8s.io/api/autoscaling/v2beta1/types.go | 2 +- staging/src/k8s.io/api/autoscaling/v2beta2/types.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/staging/src/k8s.io/api/autoscaling/v2beta1/types.go b/staging/src/k8s.io/api/autoscaling/v2beta1/types.go index d76e879678a..f5fe9f2acfe 100644 --- a/staging/src/k8s.io/api/autoscaling/v2beta1/types.go +++ b/staging/src/k8s.io/api/autoscaling/v2beta1/types.go @@ -88,7 +88,7 @@ const ( // (only `type` and one other matching field should be set at once). type MetricSpec struct { // type is the type of metric source. It should be one of "Object", - // "Pods" or "Resource", each mapping to a matching field in the object. + // "Pods", "Resource" or "External", each mapping to a matching field in the object. Type MetricSourceType `json:"type" protobuf:"bytes,1,name=type"` // object refers to a metric describing a single kubernetes object diff --git a/staging/src/k8s.io/api/autoscaling/v2beta2/types.go b/staging/src/k8s.io/api/autoscaling/v2beta2/types.go index 6e5b8f68c11..f155d9d846f 100644 --- a/staging/src/k8s.io/api/autoscaling/v2beta2/types.go +++ b/staging/src/k8s.io/api/autoscaling/v2beta2/types.go @@ -97,7 +97,7 @@ type CrossVersionObjectReference struct { // (only `type` and one other matching field should be set at once). type MetricSpec struct { // type is the type of metric source. It should be one of "Object", - // "Pods" or "Resource", each mapping to a matching field in the object. + // "Pods", "Resource" or "External", each mapping to a matching field in the object. Type MetricSourceType `json:"type" protobuf:"bytes,1,name=type"` // object refers to a metric describing a single kubernetes object From b9e5f5cbed15bce81581ca99137f4916a1f24b8d Mon Sep 17 00:00:00 2001 From: Weston McNamee Date: Fri, 28 Aug 2020 10:13:10 -0700 Subject: [PATCH 2/3] =?UTF-8?q?chore(openapi-spec):=20=F0=9F=93=A6=20=20re?= =?UTF-8?q?generate?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/openapi-spec/swagger.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/openapi-spec/swagger.json b/api/openapi-spec/swagger.json index 13e8d591858..fdf7ae161e3 100644 --- a/api/openapi-spec/swagger.json +++ b/api/openapi-spec/swagger.json @@ -3126,7 +3126,7 @@ "description": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source." }, "type": { - "description": "type is the type of metric source. It should be one of \"Object\", \"Pods\" or \"Resource\", each mapping to a matching field in the object.", + "description": "type is the type of metric source. It should be one of \"Object\", \"Pods\", \"Resource\" or \"External\", each mapping to a matching field in the object.", "type": "string" } }, @@ -3648,7 +3648,7 @@ "description": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source." }, "type": { - "description": "type is the type of metric source. It should be one of \"Object\", \"Pods\" or \"Resource\", each mapping to a matching field in the object.", + "description": "type is the type of metric source. It should be one of \"Object\", \"Pods\", \"Resource\" or \"External\", each mapping to a matching field in the object.", "type": "string" } }, From 92ef2aa3581e1b633d322c5aec644b29eeb56747 Mon Sep 17 00:00:00 2001 From: Weston McNamee Date: Sun, 30 Aug 2020 12:58:39 -0700 Subject: [PATCH 3/3] =?UTF-8?q?chore:=20=F0=9F=93=A6=20=20update=20generat?= =?UTF-8?q?ed=20files?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- staging/src/k8s.io/api/autoscaling/v2beta1/generated.proto | 2 +- .../api/autoscaling/v2beta1/types_swagger_doc_generated.go | 2 +- staging/src/k8s.io/api/autoscaling/v2beta2/generated.proto | 2 +- .../api/autoscaling/v2beta2/types_swagger_doc_generated.go | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/staging/src/k8s.io/api/autoscaling/v2beta1/generated.proto b/staging/src/k8s.io/api/autoscaling/v2beta1/generated.proto index f90f93f9f40..e763d3fa53f 100644 --- a/staging/src/k8s.io/api/autoscaling/v2beta1/generated.proto +++ b/staging/src/k8s.io/api/autoscaling/v2beta1/generated.proto @@ -201,7 +201,7 @@ message HorizontalPodAutoscalerStatus { // (only `type` and one other matching field should be set at once). message MetricSpec { // type is the type of metric source. It should be one of "Object", - // "Pods" or "Resource", each mapping to a matching field in the object. + // "Pods", "Resource" or "External", each mapping to a matching field in the object. optional string type = 1; // object refers to a metric describing a single kubernetes object diff --git a/staging/src/k8s.io/api/autoscaling/v2beta1/types_swagger_doc_generated.go b/staging/src/k8s.io/api/autoscaling/v2beta1/types_swagger_doc_generated.go index a0d5f533758..d945a9f08ae 100644 --- a/staging/src/k8s.io/api/autoscaling/v2beta1/types_swagger_doc_generated.go +++ b/staging/src/k8s.io/api/autoscaling/v2beta1/types_swagger_doc_generated.go @@ -124,7 +124,7 @@ func (HorizontalPodAutoscalerStatus) SwaggerDoc() map[string]string { var map_MetricSpec = map[string]string{ "": "MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).", - "type": "type is the type of metric source. It should be one of \"Object\", \"Pods\" or \"Resource\", each mapping to a matching field in the object.", + "type": "type is the type of metric source. It should be one of \"Object\", \"Pods\", \"Resource\" or \"External\", each mapping to a matching field in the object.", "object": "object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).", "pods": "pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", "resource": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.", diff --git a/staging/src/k8s.io/api/autoscaling/v2beta2/generated.proto b/staging/src/k8s.io/api/autoscaling/v2beta2/generated.proto index 24dc5882e75..d78d768e069 100644 --- a/staging/src/k8s.io/api/autoscaling/v2beta2/generated.proto +++ b/staging/src/k8s.io/api/autoscaling/v2beta2/generated.proto @@ -257,7 +257,7 @@ message MetricIdentifier { // (only `type` and one other matching field should be set at once). message MetricSpec { // type is the type of metric source. It should be one of "Object", - // "Pods" or "Resource", each mapping to a matching field in the object. + // "Pods", "Resource" or "External", each mapping to a matching field in the object. optional string type = 1; // object refers to a metric describing a single kubernetes object diff --git a/staging/src/k8s.io/api/autoscaling/v2beta2/types_swagger_doc_generated.go b/staging/src/k8s.io/api/autoscaling/v2beta2/types_swagger_doc_generated.go index 3f38880f952..1c1b229f873 100644 --- a/staging/src/k8s.io/api/autoscaling/v2beta2/types_swagger_doc_generated.go +++ b/staging/src/k8s.io/api/autoscaling/v2beta2/types_swagger_doc_generated.go @@ -163,7 +163,7 @@ func (MetricIdentifier) SwaggerDoc() map[string]string { var map_MetricSpec = map[string]string{ "": "MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).", - "type": "type is the type of metric source. It should be one of \"Object\", \"Pods\" or \"Resource\", each mapping to a matching field in the object.", + "type": "type is the type of metric source. It should be one of \"Object\", \"Pods\", \"Resource\" or \"External\", each mapping to a matching field in the object.", "object": "object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).", "pods": "pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", "resource": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.",