vvvvvant commented on issue #12432: URL: https://github.com/apache/apisix/issues/12432#issuecomment-3082716207
1. Create upstream { "nodes": [ { "host": "192.168.8.25", "port": 8001, "weight": 1 }, { "host": "192.168.8.25", "port": 8002, "weight": 1 } ], "timeout": { "connect": 6, "send": 600, "read": 600 }, "type": "roundrobin", "checks": { "active": { "concurrency": 10, "healthy": { "http_statuses": [ 200, 302, four hundred and four ], "interval": 5, "successes": 2 }, "http_path": "/health", "timeout": 3, "type": "http", "unhealthy": { "http_failures": 2, "http_statuses": [ 429, 500, 501, 502, 503, 504, 505, four hundred and ninety-nine ], "interval": 1, "tcp_failures": 2, "timeouts": 2 } } }, "scheme": "http", "pass_host": "pass", "name": "test-health", "keepalive_pool": { "idle_timeout": 60, "requests": 1000, "size": 320 } } 2. Create a route: { "uris": [ "/ping", "/health" ], "name": "rotuer-4-test-healthy", 'desc ':' Temporary testing proactive health check ', "methods": [ "GET", "POST", "PUT", "DELETE", "PATCH", "HEAD", "OPTIONS", "CONNECT", "TRACE" ], "host": "healthcheck.com", "upstream_id": "575513935755608775", #Upstream ID created in the previous step "enable_websocket": true, "status": 1 } 3. Test routing access (both upstream are online) and check health check status: curl http://healthcheck.com/ping Response is normal curl http://APISIX_CONTROL_PORT/v1/healthcheck/upstreams/575513935755608775 Both health count and unhealthy count are 0 4. Disable upstream nodes and test access curl http://healthcheck.com/ping Observing the apisix logs, it was found that some requests arrived at the down node first, responded to 502, and then forwarded to the reachable node curl http://APISIX_CONTROL_PORT/v1/healthcheck/upstreams/575513935755608775 Both health count and unhealthy count are 0, indicating that proactive checking has not been effective in my configuration -- 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. To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org