-
-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathbasic.kdl
More file actions
66 lines (59 loc) · 1.21 KB
/
basic.kdl
File metadata and controls
66 lines (59 loc) · 1.21 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
// Zentinel Basic Configuration Example
// Minimal configuration for getting started
system {
worker-threads 0 // 0 = auto-detect CPU cores
max-connections 10000
graceful-shutdown-timeout-secs 30
}
listeners {
listener "http" {
address "0.0.0.0:8080"
protocol "http"
request-timeout-secs 60
}
}
routes {
route "default" {
priority "low"
matches {
path-prefix "/"
}
upstream "backend"
policies {
timeout-secs 30
failure-mode "open"
}
}
}
upstreams {
upstream "backend" {
target "127.0.0.1:8081" weight=1
load-balancing "round_robin"
health-check {
type "http" {
path "/health"
expected-status 200
}
interval-secs 10
timeout-secs 5
healthy-threshold 2
unhealthy-threshold 3
}
}
}
limits {
max-header-size-bytes 8192
max-header-count 100
max-body-size-bytes 10485760
}
observability {
metrics {
enabled #true
address "0.0.0.0:9090"
path "/metrics"
}
logging {
level "info"
format "json"
}
}