Health Checks for Upstream

    The following is a example of health check:

    The configures in are belong to health check, the type of checks contains: active or passive.

    • active: To enable active health checks, you need to specify the configuration items under checks.active in the Upstream object configuration.

      • active.http_path: The HTTP GET request path used to detect if the upstream is healthy.

      • : The HTTP request host used to detect if the upstream is healthy.

      • active.port: The customize health check host port (optional), this will override the port in the upstream node.

      • active.healthy.successes: The number of success times to determine the target is healthy, the minimum is 1.

      The threshold fields of unhealthy are:

      • active.unhealthy.interval: Interval between health checks for unhealthy targets (in seconds), the minimum is 1.
      • active.unhealthy.http_failures: The number of http failures times to determine the target is unhealthy, the minimum is 1.
      • active.req_headers: Additional request headers. Array format, so you can fill in multiple headers.
    • passive: To enable passive health checks, you need to specify the configuration items under checks.passive in the Upstream object configuration.

      The threshold fields of are:

      • passive.healthy.successes: Number of successes in proxied traffic (as defined by passive.healthy.http_statuses) to consider a target healthy, as observed by passive health checks.
      • passive.unhealthy.http_statuses: If the current response code is equal to any of these, set the upstream node to the unhealthy state. Otherwise ignore this request.
      • passive.unhealthy.tcp_failures: Number of TCP failures in proxied traffic to consider a target unhealthy, as observed by passive health checks.
      • passive.unhealthy.timeouts: Number of timeouts in proxied traffic to consider a target unhealthy, as observed by passive health checks.
      • passive.unhealthy.http_failures: Number of HTTP failures in proxied traffic (as defined by passive.unhealthy.http_statuses) to consider a target unhealthy, as observed by passive health checks.