Skip to content

liveness vs readiness endpoints switched? #31

@mtaron

Description

@mtaron

The implementation of the liveness and readiness health checks are swapped based on my expectations from using Kubernetes liveness and readiness probes.

I expect liveness to mean "are you alive?" and when it fails enough times (configurable), Kubernetes will restart the container. This matches the current "/v1/health/ready" endpoint which just returns.

Readiness on the other hand means "can you serve traffic right now?". If it fails, Kubernetes will avoid routing traffic to that container, but won't restart it. This matches the implementation of "/v1/health/live" which is checking whether a request can be enqueued.

This isn't a blocker or anything since you can configure the route for the probes; just thought I'd mention it.

# wait for the model to respond before considering the container started. 
# 10 minute timeout
startupProbe:
  httpGet:
    path: /v1/health/model
    port: http
  failureThreshold: 600
  periodSeconds: 10
# restart the container if this fails
livenessProbe:
  httpGet:
    path: /v1/health/ready
    port: http
  periodSeconds: 10
# don't serve traffic if this fails
readinessProbe:
  httpGet:
    path: /v1/health/live
    port: http
  initialDelaySeconds: 60
  periodSeconds: 10

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions