Skip to content

Commit

Permalink
Add MSSQLServer Autoscaling Doc (#706)
Browse files Browse the repository at this point in the history
Signed-off-by: Neaj Morshad <[email protected]>
  • Loading branch information
Neaj-Morshad-101 authored Nov 4, 2024
1 parent 1b408f7 commit 37890d2
Show file tree
Hide file tree
Showing 14 changed files with 1,437 additions and 0 deletions.
24 changes: 24 additions & 0 deletions docs/examples/mssqlserver/autoscaler/compute/ms-as-compute.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
apiVersion: autoscaling.kubedb.com/v1alpha1
kind: MSSQLServerAutoscaler
metadata:
name: ms-as-compute
namespace: demo
spec:
databaseRef:
name: mssqlserver-ag-cluster
opsRequestOptions:
timeout: 5m
apply: IfReady
compute:
mssqlserver:
trigger: "On"
podLifeTimeThreshold: 5m
resourceDiffPercentage: 10
minAllowed:
cpu: 800m
memory: 2Gi
maxAllowed:
cpu: 1
memory: 3Gi
containerControlledValues: "RequestsAndLimits"
controlledResources: ["cpu", "memory"]
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
apiVersion: kubedb.com/v1alpha2
kind: MSSQLServer
metadata:
name: mssqlserver-ag-cluster
namespace: demo
spec:
version: "2022-cu12"
replicas: 3
topology:
mode: AvailabilityGroup
availabilityGroup:
databases:
- agdb1
- agdb2
internalAuth:
endpointCert:
issuerRef:
apiGroup: cert-manager.io
name: mssqlserver-ca-issuer
kind: Issuer
tls:
issuerRef:
name: mssqlserver-ca-issuer
kind: Issuer
apiGroup: "cert-manager.io"
clientTLS: false
podTemplate:
spec:
containers:
- name: mssql
resources:
requests:
cpu: "500m"
memory: "1.5Gi"
limits:
cpu: "600m"
memory: "1.6Gi"
storageType: Durable
storage:
storageClassName: "longhorn"
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
deletionPolicy: WipeOut
15 changes: 15 additions & 0 deletions docs/examples/mssqlserver/autoscaler/storage/ms-as-storage.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: autoscaling.kubedb.com/v1alpha1
kind: MSSQLServerAutoscaler
metadata:
name: ms-as-storage
namespace: demo
spec:
databaseRef:
name: mssqlserver-ag-cluster
storage:
mssqlserver:
trigger: "On"
usageThreshold: 60
scalingThreshold: 50
expansionMode: "Offline"
upperBound: "100Gi"
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
apiVersion: kubedb.com/v1alpha2
kind: MSSQLServer
metadata:
name: mssqlserver-ag-cluster
namespace: demo
spec:
version: "2022-cu12"
replicas: 3
topology:
mode: AvailabilityGroup
availabilityGroup:
databases:
- agdb1
- agdb2
internalAuth:
endpointCert:
issuerRef:
apiGroup: cert-manager.io
name: mssqlserver-ca-issuer
kind: Issuer
tls:
issuerRef:
name: mssqlserver-ca-issuer
kind: Issuer
apiGroup: "cert-manager.io"
clientTLS: false
podTemplate:
spec:
containers:
- name: mssql
resources:
requests:
cpu: "500m"
memory: "1.5Gi"
limits:
cpu: "600m"
memory: "1.6Gi"
storageType: Durable
storage:
storageClassName: "longhorn"
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
deletionPolicy: WipeOut
10 changes: 10 additions & 0 deletions docs/guides/mssqlserver/autoscaler/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
title: Autoscaling
menu:
docs_{{ .version }}:
identifier: ms-autoscaling
name: Autoscaling
parent: guides-mssqlserver
weight: 46
menu_name: docs_{{ .version }}
---
10 changes: 10 additions & 0 deletions docs/guides/mssqlserver/autoscaler/compute/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
title: Compute Autoscaling
menu:
docs_{{ .version }}:
identifier: ms-compute-autoscaling
name: Compute Autoscaling
parent: ms-autoscaling
weight: 10
menu_name: docs_{{ .version }}
---
Loading

0 comments on commit 37890d2

Please sign in to comment.