I am deploying kong 2.8 in db-less mode. I would like to know how to specify its declarative configuration to enable passive health checks i.e. circuit breaker. It would be great if some one can share an example configuration file.
Thanks.
I am deploying kong 2.8 in db-less mode. I would like to know how to specify its declarative configuration to enable passive health checks i.e. circuit breaker. It would be great if some one can share an example configuration file.
Thanks.
One reading more on this I could move a step further by configuring a upstream and a target object like mentioned below but I don’t understand how to link them with the service object defined above in the config.
Thanks.
_format_version: "2.1"
services:
- name: dev-app
url: http://172.19.0.1:8080/my-service
routes:
- name: dev-app-route
paths:
- /api/v1
strip_path: false
upstreams:
- name: dev-app-upstream
targets:
- target: localhost:8000
weight: 100
healthchecks:
threshold: 3
passive:
unhealthy:
http_statuses: [400,500]
timeouts: 2
tcp_failures: 2
http_failures: 2
healthy:
http_statuses: [200,201,204]
successes: 5
slots: 10000
Playing around with the config I could get the below config working. I have a few questions around its behavior
Any inputs? Thanks.
_format_version: "2.1"
services:
- name: dev-app
host: dev-app-upstream
protocol: http
port: 8000
path: /my-service
routes:
- name: dev-app-route
paths:
- /api/v1
strip_path: false
upstreams:
- name: dev-app-upstream
targets:
- target: 172.19.0.1:8080
weight: 100
healthchecks:
threshold: 3
passive:
unhealthy:
http_statuses: [500]
timeouts: 2
tcp_failures: 2
http_failures: 2
healthy:
http_statuses: [200,201,204]
successes: 5
slots: 10000