Upgrade to Pro — share decks privately, control downloads, hide ads and more …

SG Innovate : Auto-scaling containers with KEDA

SG Innovate : Auto-scaling containers with KEDA

Slidedeck used during the session for SGInnovate / Serverless SG meetup https://www.sginnovate.com/events/serverless-singapore-–-august-meetup
Demonstrated KEDA with Azure Functions for Azure Storage Queues with ACI.
Also demonstrated scaling of .Net Core RabbitMQ consumer deployed to an AKS cluster.

Nilesh Gule

August 22, 2019
Tweet

More Decks by Nilesh Gule

Other Decks in Technology

Transcript

  1. $whoami { “name” : “Nilesh Gule”, “website” : “https://www.HandsOnArchitect.com", “github”

    : “https://github.com/NileshGule" “twitter” : “@nileshgule”, “linkedin” : “https://www.linkedin.com/in/nileshgule”, “email” : “[email protected]", “likes” : “Technical Evangelism, Cricket” }
  2. Pros Cons Scale k8s objects: Kubectl scale –replicas=3 processor-deployment.yml Kubectl

    scale –replicas=3 deployment/rabbitmq-consumer Scale AKS cluster: az aks scale --resource-group myResourceGroup \ --name myAKSCluster \ --node-count 1 \ --nodepool-name <your node pool name>
  3. apiVersion: keda.k8s.io/v1alpha1 kind: ScaledObject metadata: name: hello-keda namespace: default labels:

    deploymentName: hello-keda spec: scaleTargetRef: deploymentName: hello-keda pollingInterval: 5 # Optional. Default: 30 seconds maxReplicaCount: 15 # Optional. Default: 100 triggers: - type: azure-queue metadata: name: myQueueItem type: queueTrigger direction: in queueName: js-queue-items connection: AzureWebJobsStorage
  4. apiVersion: keda.k8s.io/v1alpha1 kind: ScaledObject metadata: name: rabbitmq-consumer namespace: default labels:

    deploymentName: rabbitmq-consumer spec: scaleTargetRef: deploymentName: rabbitmq-consumer pollingInterval: 5 # Optional. Default: 30 seconds cooldownPeriod: 30 # Optional. Default: 300 seconds minReplicaCount: 1 # Optional. Default: 0 maxReplicaCount: 30 # Optional. Default: 100 triggers: - type: rabbitmq metadata: queueName: hello host: 'amqp://user:[email protected]:5672’ queueLength : '5'
  5. Thank you very much Code with Passion and Strive for

    Excellence https://github.com/NileshGule/AKS-learning-series https://github.com/NileshGule/pd-tech-fest-2019 https://github.com/NileshGule/sample-dotnet-core-rabbitmq-keda https://www.slideshare.net/nileshgule/presentations https://speakerdeck.com/nileshgule/
  6. Q&A