solo-io / gloo

The Cloud-Native API Gateway and AI Gateway
https://docs.solo.io/
Apache License 2.0
4.1k stars 446 forks source link

Exposing retriable_statuses is required to define unhealthyThreshold in the Envoy cluster health checks #9776

Open sadieleob opened 3 months ago

sadieleob commented 3 months ago

Gloo Edge Product

Enterprise

Gloo Edge Version

1.16.8

Is your feature request related to a problem? Please describe.

No

Describe the solution you'd like

unhealthy_threshold seems to require retriable_statuses which as of now is not exposed in Gloo Edge

https://docs.solo.io/gloo-edge/latest/reference/api/github.com/solo-io/gloo/projects/gloo/api/external/envoy/config/core/v3/health_check.proto.sk/

https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/core/v3/health_check.proto#envoy-v3-api-field-config-core-v3-healthcheck-httphealthcheck-retriable-statuses

otherwise, any HTTP response code outside the expected_statuses will consider the host unhealthy

"health_checks": [
       {
        "timeout": "10s",
        "interval": "20s",
        "unhealthy_threshold": 3,
        "healthy_threshold": 2,
        "custom_health_check": {
         "name": "io.solo.health_checkers.advanced_http",
         "typed_config": {
          "@type": "type.googleapis.com/envoy.config.health_checker.advanced_http.v2.AdvancedHttp",
          "http_health_check": {
           "path": "/actuator/health",
           "expected_statuses": [
            {
             "start": "200",
             "end": "227"
            }
           ]
          }
         }
        }
       }
      ]

Describe alternatives you've considered

No alternatives

Additional Context

No response

soloio-bot commented 3 months ago

Zendesk ticket #4127 has been linked to this issue.