refactor(healthcheck): streamline health check configuration and defaults

- Moved health check constants from common package alongside type definition.
- Updated health check configuration to use struct directly instead of pointers.
- Introduced global default health check config
This commit is contained in:
yusing
2025-12-04 15:19:10 +08:00
parent 48627753d6
commit 55a42b81de
15 changed files with 66 additions and 51 deletions

View File

@@ -82,7 +82,7 @@ func BenchmarkEntrypointReal(b *testing.B) {
Scheme: routeTypes.SchemeHTTP,
Host: host,
Port: route.Port{Proxy: portInt},
HealthCheck: &types.HealthCheckConfig{Disable: true},
HealthCheck: types.HealthCheckConfig{Disable: true},
}
err = r.Validate()
@@ -125,7 +125,7 @@ func BenchmarkEntrypoint(b *testing.B) {
Port: route.Port{
Proxy: 8080,
},
HealthCheck: &types.HealthCheckConfig{
HealthCheck: types.HealthCheckConfig{
Disable: true,
},
}