### profile: groups

--- baseline: upstream UP ---
  GET /actuator/health                     HTTP 503
  GET /actuator/health/liveness            HTTP 200
  GET /actuator/health/readiness           HTTP 200
  GET /actuator/health/startup             HTTP 200

--- upstream DOWN (a third party is having an outage) ---
  GET /actuator/health                     HTTP 503
  GET /actuator/health/liveness            HTTP 200
  GET /actuator/health/readiness           HTTP 503
  GET /actuator/health/startup             HTTP 200

  liveness stayed 200. readiness went 503.
  Kubernetes takes this instance out of the Service and leaves the process alone.
  Wire readiness to /actuator/health and you get a restart loop instead.

--- what each group contains ---
$ curl -s http://localhost:8080/actuator/health/liveness
{
    "components": {
        "diskSpace": {
            "details": {
                "total": 10213466112,
                "free": 3877605376,
                "threshold": 10485760,
                "path": "/tmp/work/spring-boot-demo/.",
                "exists": true
            },
            "status": "UP"
        },
        "livenessState": {
            "status": "UP"
        }
    },
    "status": "UP"
}
$ curl -s http://localhost:8080/actuator/health/readiness
{
    "components": {
        "externalApi": {
            "details": {
                "error": "org.springframework.web.client.HttpServerErrorException$ServiceUnavailable: 503 : \"upstream unavailable\"",
                "url": "http://localhost:8080/stub/upstream/ping",
                "latencyMs": 66,
                "timeoutMs": 750
            },
            "status": "DOWN"
        },
        "ordersDatabase": {
            "details": {
                "orders": 3,
                "queryMs": 0,
                "slowThresholdMs": 250
            },
            "status": "UP"
        },
        "readinessState": {
            "status": "UP"
        }
    },
    "status": "DOWN"
}

