Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Postgres scaler #553

Merged
merged 1 commit into from
Jan 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 32 additions & 16 deletions deploy/crds/keda.k8s.io_scaledobjects_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1087,12 +1087,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand All @@ -1112,12 +1113,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down Expand Up @@ -1192,12 +1194,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand All @@ -1217,12 +1220,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down Expand Up @@ -1291,12 +1295,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand Down Expand Up @@ -1334,12 +1339,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down Expand Up @@ -1464,12 +1470,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand Down Expand Up @@ -1507,12 +1514,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down Expand Up @@ -2173,12 +2181,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand All @@ -2198,12 +2207,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down Expand Up @@ -2278,12 +2288,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand All @@ -2303,12 +2314,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port
to access on the container. Number must
be in the range 1 to 65535. Name must
be an IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down Expand Up @@ -2377,12 +2389,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand Down Expand Up @@ -2420,12 +2433,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down Expand Up @@ -2550,12 +2564,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Name or number of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
scheme:
description: Scheme to use for connecting
to the host. Defaults to HTTP.
Expand Down Expand Up @@ -2593,12 +2608,13 @@ spec:
type: string
port:
anyOf:
- type: string
- type: integer
- type: string
description: Number or name of the port to
access on the container. Number must be
in the range 1 to 65535. Name must be an
IANA_SVC_NAME.
x-kubernetes-int-or-string: true
required:
- port
type: object
Expand Down
1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ require (
github.com/golang/protobuf v1.3.2
github.com/imdario/mergo v0.3.8
github.com/kubernetes-incubator/custom-metrics-apiserver v0.0.0-20190918110929-3d9be26a50eb
github.com/lib/pq v1.3.0
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/operator-framework/operator-sdk v0.0.0-00010101000000-000000000000
github.com/pkg/errors v0.8.1
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -403,6 +403,8 @@ github.com/kylelemons/godebug v0.0.0-20170820004349-d65d576e9348/go.mod h1:B69LE
github.com/leanovate/gopter v0.2.4/go.mod h1:gNcbPWNEWRe4lm+bycKqxUYoH5uoVje5SkOJ3uoLer8=
github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
github.com/lib/pq v1.1.1/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
github.com/lib/pq v1.3.0 h1:/qkRGz8zljWiDcFvgpwUpwIAPu3r07TDvs3Rws+o/pU=
github.com/lib/pq v1.3.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
github.com/lightstep/lightstep-tracer-go v0.15.6/go.mod h1:6AMpwZpsyCFwSovxzM78e+AsYxE8sGwiM6C3TytaWeI=
github.com/lovoo/gcloud-opentracing v0.3.0/go.mod h1:ZFqk2y38kMDDikZPAK7ynTTGuyt17nSPdS3K5e+ZTBY=
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
Expand Down
2 changes: 2 additions & 0 deletions pkg/handler/scale_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,8 @@ func (h *ScaleHandler) getScaler(name, namespace, triggerType string, resolvedEn
return scalers.NewHuaweiCloudeyeScaler(triggerMetadata, authParams)
case "azure-blob":
return scalers.NewAzureBlobScaler(resolvedEnv, triggerMetadata, authParams, podIdentity)
case "postgres":
return scalers.NewPostgresScaler(resolvedEnv, triggerMetadata, authParams)
default:
return nil, fmt.Errorf("no scaler found for type: %s", triggerType)
}
Expand Down
Loading