-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path14-startup-boost.yaml
More file actions
52 lines (52 loc) · 1.64 KB
/
14-startup-boost.yaml
File metadata and controls
52 lines (52 loc) · 1.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
---
# Startup Boost: temporary CPU boost for cold-start workloads.
#
# Some applications (JVMs, ML model loaders, interpreted runtimes) need
# significantly more CPU during startup than at steady state. Rather than
# over-provisioning permanently, startupBoost applies a temporary CPU
# multiplier that expires after a configurable duration.
#
# How it works:
# 1. When the operator detects a new pod (within the boost duration
# window), it resizes the pod's CPU request to
# `recommended_cpu * multiplier`.
# 2. Once the duration expires, the operator resizes back to the
# steady-state recommendation.
# 3. If the boosted CPU would exceed the container's CPU limit or the
# node's allocatable CPU, the boost is capped automatically.
#
# Prerequisites:
# - Kubernetes 1.32+ with In-Place Pod Resize enabled (1.32 requires InPlacePodVerticalScaling feature gate)
# - Prometheus reachable at the address below
# - attune operator installed
#
# Apply:
# kubectl apply -f examples/14-startup-boost.yaml
apiVersion: attune.io/v1alpha1
kind: AttunePolicy
metadata:
name: jvm-api
namespace: production
spec:
targetRef:
kind: Deployment
name: jvm-api
metricsSource:
prometheus:
address: http://prometheus-server.monitoring:80
cpu:
percentile: 95
overhead: "20"
startupBoost:
multiplier: "3.0" # 3x the steady-state recommendation during startup
duration: 2m # boost expires 2 minutes after pod creation
minAllowed: "100m"
maxAllowed: "8000m"
memory:
percentile: 99
overhead: "30"
minAllowed: "256Mi"
maxAllowed: "16Gi"
updateStrategy:
type: Auto
cooldown: 1h