remove metrics.port

This commit is contained in:
DullJZ
2025-09-13 22:41:00 +08:00
parent f214b003fd
commit cfc0a734bf
6 changed files with 4 additions and 9 deletions

View File

@@ -125,7 +125,6 @@ balancer:
metrics:
enabled: true
path: "/metrics"
port: 9090
# S3兼容API配置
s3api:

View File

@@ -52,7 +52,6 @@ balancer:
metrics:
enabled: true
path: "/metrics"
port: 9090
s3api:
access_key: "AKIAIOSFODNN7EXAMPLE"

View File

@@ -83,10 +83,10 @@ config:
health_check_period: 30s
update_stats_period: 60s
# 监控指标配置(与主服务共享端口)
metrics:
enabled: true
path: "/metrics"
port: 8080
s3api:
access_key: "your-access-key"

View File

@@ -121,10 +121,10 @@ config:
health_check_period: 30s
update_stats_period: 60s
# 监控指标配置(与主服务共享端口)
metrics:
enabled: true
path: "/metrics"
port: 8080
s3api:
access_key: "AKIAIOSFODNN7EXAMPLE"

View File

@@ -43,10 +43,10 @@ data:
health_check_period: 30s
update_stats_period: 60s
# 监控指标配置(与主服务共享端口)
metrics:
enabled: true
path: "/metrics"
port: 8080
s3api:
access_key: "AKIAIOSFODNN7EXAMPLE"

View File

@@ -56,7 +56,7 @@ type BalancerConfig struct {
type MetricsConfig struct {
Enabled bool `yaml:"enabled"`
Path string `yaml:"path"`
Port int `yaml:"port"`
// Port int `yaml:"port"` // 目前未使用,与主服务共享端口
}
// S3APIConfig S3兼容API配置
@@ -144,9 +144,6 @@ func (c *Config) SetDefaults() {
if c.Metrics.Path == "" {
c.Metrics.Path = "/metrics"
}
if c.Metrics.Port == 0 {
c.Metrics.Port = 9090
}
// 数据库默认值
if c.Database.Type == "" {