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

feat: New ScalingSet CRD to deploy isolated interceptors+scalers #703

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ $ helm search repo kedacore
NAME CHART VERSION APP VERSION DESCRIPTION
kedacore/external-scaler-azure-cosmos-db 0.1.0 0.1.0 Event-based autoscaler for Azure Cosmos DB chan...
kedacore/keda 2.15.2 2.15.1 Event-based autoscaler for workloads on Kubernetes
kedacore/keda-add-ons-http 0.8.0 0.8.0 Event-based autoscaler for HTTP workloads on Ku...
kedacore/keda-add-ons-http 0.9.0 0.9.0 Event-based autoscaler for HTTP workloads on Ku...
```

## Releases
Expand Down
4 changes: 2 additions & 2 deletions http-add-on/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ kubeVersion: ">=v1.23.0-0"
# to the chart and its templates, including the app version. This is incremented at chart release time and does not need
# to be included in any PRs to main.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.8.0
version: 0.9.0

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
appVersion: 0.8.0
appVersion: 0.9.0
home: https://github.com/kedacore/http-add-on
sources:
- https://github.com/kedacore/http-add-on
Expand Down
362 changes: 362 additions & 0 deletions http-add-on/templates/crds/clusterhttpscalingset.yaml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -99,10 +99,6 @@ spec:
properties:
apiVersion:
type: string
deployment:
description: 'Deprecated: The name of the deployment to scale
according to HTTP traffic'
type: string
kind:
type: string
name:
Expand Down Expand Up @@ -157,6 +153,22 @@ spec:
type: string
type: object
type: object
scalingSet:
description: |-
ScalingSet to be used for this HTTPScaledObject, if empty, default
interceptor and scaler will be used
properties:
kind:
description: Kind of the resource being referred to. Defaults
to HTTPScalingSet.
enum:
- HTTPScalingSet
- ClusterHTTPScalingSet
type: string
name:
description: Name of the scaling set
type: string
type: object
targetPendingRequests:
description: (optional) DEPRECATED (use ScalingMetric instead) Target
metric value
Expand Down
361 changes: 361 additions & 0 deletions http-add-on/templates/crds/httpscalingset.yaml

Large diffs are not rendered by default.

76 changes: 76 additions & 0 deletions http-add-on/templates/operator/rbac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,56 @@ metadata:
{{- include "keda-http-add-on.labels" . | indent 4 }}
name: {{ .Chart.Name }}-role
rules:
- apiGroups:
- ""
resources:
- services
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- apps
resources:
- deployments
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- http.keda.sh
resources:
- clusterhttpscalingsets
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- http.keda.sh
resources:
- clusterhttpscalingsets/finalizers
verbs:
- update
- apiGroups:
- http.keda.sh
resources:
- clusterhttpscalingsets/status
verbs:
- get
- patch
- update
- apiGroups:
- http.keda.sh
resources:
Expand Down Expand Up @@ -77,6 +127,32 @@ rules:
- patch
- update
- watch
- apiGroups:
- http.keda.sh
resources:
- httpscalingsets
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- http.keda.sh
resources:
- httpscalingsets/finalizers
verbs:
- update
- apiGroups:
- http.keda.sh
resources:
- httpscalingsets/status
verbs:
- get
- patch
- update
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
Expand Down
4 changes: 1 addition & 3 deletions http-add-on/templates/scaler/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ spec:
app.kubernetes.io/component: scaler
{{- include "keda-http-add-on.labels" . | indent 8 }}
spec:
imagePullSecrets:
imagePullSecrets:
{{- toYaml .Values.scaler.imagePullSecrets | nindent 8 }}
serviceAccountName: {{ .Chart.Name }}-external-scaler
{{- if .Values.podSecurityContext.scaler }}
Expand All @@ -40,8 +40,6 @@ spec:
- containerPort: {{ .Values.scaler.grpcPort }}
name: grpc
env:
- name: KEDA_HTTP_SCALER_TARGET_ADMIN_DEPLOYMENT
value: "{{ .Chart.Name }}-interceptor"
- name: KEDA_HTTP_SCALER_PORT
value: "{{ .Values.scaler.grpcPort }}"
- name: KEDA_HTTP_SCALER_TARGET_ADMIN_NAMESPACE
Expand Down