-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Problem
Balancerd defaults are undersized for production workloads and cannot scale to handle traffic spikes.
Solution
- Provide recommendation in sample config to set balancerd to 2 cores of CPU and 2Gi memory for production workloads.
- Provide ability for balancerd to scale automatically using horizontal pod autoscaler.
# Example Balancerd HPA config
apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: balancer
namespace: mz-balancer
spec:
behavior:
scaleDown:
policies:
- periodSeconds: 15
type: Percent
value: 100
selectPolicy: Max
stabilizationWindowSeconds: 1800
scaleUp:
policies:
- periodSeconds: 15
type: Pods
value: 4
- periodSeconds: 15
type: Percent
value: 100
selectPolicy: Max
stabilizationWindowSeconds: 180
maxReplicas: 10
metrics:
- resource:
name: memory
target:
averageUtilization: 50
type: Utilization
type: Resource
- resource:
name: cpu
target:
averageUtilization: 50
type: Utilization
type: Resource
minReplicas: 1
scaleTargetRef:
apiVersion: apps/v1
kind: Deployment
name: balancer
Metadata
Metadata
Assignees
Labels
No labels