Skip to content
This repository has been archived by the owner on Sep 4, 2020. It is now read-only.

Autoscaling workloads on other metrics than CPU/Memory #518

Open
tomkerkhove opened this issue Jan 17, 2020 · 0 comments
Open

Autoscaling workloads on other metrics than CPU/Memory #518

tomkerkhove opened this issue Jan 17, 2020 · 0 comments

Comments

@tomkerkhove
Copy link
Contributor

OAM Spec Info

Rudr will always follow OAM spec, if this feature is related with spec definition, please make sure they are consistent.

Is your feature request related to a problem? Please describe.
I'd like to scale workloads on other metrics than CPU/Memory with the Autoscaler trait.

Describe the solution you'd like
Autoscale based on Service Bus queue size

Additional context
I'm translating my KEDA sample (https://github.com/kedacore/sample-dotnet-worker-servicebus-queue) to OAM to give an example of what OAM leverages.

KEDA is already mentioned in the Autoscaler trait but doesn't seem to be supported, is that correct?

https://github.com/oam-dev/rudr/blob/master/docs/concepts/traits.md#autoscaler-trait

Scenario

apiVersion: core.oam.dev/v1alpha1
kind: ComponentSchematic
metadata:
  name: order-worker-component
spec:
  workloadType: core.oam.dev/v1alpha1.Server
  containers:
    - name: order-worker-container
      image: tomkerkhove/keda-sample-dotnet-worker-servicebus-queue
      env:
        - name: KEDA_SERVICEBUS_QUEUE_CONNECTIONSTRING
          fromParam: ServiceBus_Queue_Connectionstring
        - name: PORT
          fromParam: port
      ports:
        - protocol: TCP
          containerPort: 9999
          name: http
  parameters:
    - name: ServiceBus_Queue_Connectionstring
      description: 'Connection string for the Azure Service Bus queue'
      type: string
      required: true
---
apiVersion: core.oam.dev/v1alpha1
kind: ApplicationConfiguration
metadata:
  name: order-worker-config
spec:
  components:
    - componentName: order-worker-component
      instanceName: order-worker-component
      parameterValues:
        - name: ServiceBus_Queue_Connectionstring
          value: "<redacted>"
      traits:
        - name: auto-scaler.core.oam.dev/v1alpha1
          properties:
            maximum: 5
            minimim: 0
@tomkerkhove tomkerkhove changed the title Autoscaling workloads with KEDA Autoscaling workloads on other metrics than CPU/Memory Jan 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant