You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2021/04/21 13:41:21 UTC
[GitHub] [apisix] Ben0625 opened a new issue #4102: Passive healthcheck not working when a route has only one upstream
Ben0625 opened a new issue #4102:
URL: https://github.com/apache/apisix/issues/4102
### Environment
* apisix version: 2.0
* OS: 3.10.0-693.el7.x86_64
* OpenResty version: openresty/1.17.8.2
* etcd version: 3.4.13
* apisix-dashboard version: 2.0
### Minimal test code / Steps to reproduce the issue
1. Set a route with only one upstream. Add active and passive healthcheck.
2. Send requests.
### What's the actual result?
Even if this upstream always return 500, the passive healthcheck does not work to set this node to be unhealthy. Every request will still be passed to this upstream.
It seems that the checker is not created at all, even after I set this upstream return 200.
The route config in etcd:
```
{
"id": "route_2050210843",
"create_time": 1618455175,
"update_time": 1619011016,
"uris": ["/test1.do"],
"name": "route-2050210843",
"desc": "health_check_test",
"methods": ["GET", "POST", "PUT", "DELETE", "PATCH", "HEAD", "OPTIONS"],
"vars": [],
"upstream": {
"nodes": [{
"host": "172.25.69.182",
"port": 8080,
"weight": 1
}],
"timeout": {
"connect": 6,
"read": 6,
"send": 6
},
"type": "roundrobin",
"checks": {
"active": {
"healthy": {
"interval": 100,
"successes": 10
},
"host": "172.25.69.182",
"http_path": "/check.do",
"req_headers": [""],
"timeout": 3,
"unhealthy": {
"http_failures": 5,
"interval": 3
}
},
"passive": {
"healthy": {
"http_statuses": [200],
"successes": 2
},
"unhealthy": {
"http_failures": 1,
"http_statuses": [500, 502, 504],
"tcp_failures": 1
}
}
}
},
"labels": {
"serve": "2050210843"
}
}
```
### What's the expected result?
The checker for this upstream is created and can be set to unhealthy state when failures reach passive.unhealthy.http_failures.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] Ben0625 commented on issue #4102: Passive healthcheck not working when a route has only one upstream
Posted by GitBox <gi...@apache.org>.
Ben0625 commented on issue #4102:
URL: https://github.com/apache/apisix/issues/4102#issuecomment-824481903
> It is by design. If you only have one upstream, you don't need to care about which one is healthy. You only have one choice.
OK I got it, Thanks. I think it will be clearer for users if this is mentioned in the healthcheck document.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander closed issue #4102: Passive healthcheck not working when a route has only one upstream
Posted by GitBox <gi...@apache.org>.
spacewander closed issue #4102:
URL: https://github.com/apache/apisix/issues/4102
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #4102: Passive healthcheck not working when a route has only one upstream
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #4102:
URL: https://github.com/apache/apisix/issues/4102#issuecomment-824094029
It is by design. If you only have one upstream, you don't need to care about which one is healthy. You only have one choice.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #4102: Passive healthcheck not working when a route has only one upstream
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #4102:
URL: https://github.com/apache/apisix/issues/4102#issuecomment-824503850
Done: https://github.com/apache/apisix/pull/4105
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org