AmerDwight opened a new issue, #10602:
URL: https://github.com/apache/apisix/issues/10602

   ### Description
   
   Dear Team of APISIX
   I'm learning to use APISIX, and I face an issue about health-checking 
mechanism is not working.
   Since I have a test upstream of nginx as a backend, and I already built a 
endpoint like /health
   
followed:[monitor-api-health-check](https://apisix.apache.org/docs/apisix/next/tutorials/monitor-api-health-check/)
   
   But I cannot trace any health-check request in whether access.log / 
error.log / prometheus record
   
   upstream in apisix:
   `{
     "nodes": [
       {
         "host": "nginx_web1",
         "port": 80,
         "weight": 1
       }
     ],
     "timeout": {
       "connect": 6,
       "send": 6,
       "read": 6
     },
     "type": "roundrobin",
     "checks": {
       "active": {
         "concurrency": 2,
         "healthy": {
           "http_statuses": [
             200,
             302
           ],
           "interval": 2,
           "successes": 1
         },
         "http_path": "/health",
         "timeout": 2,
         "type": "http",
         "unhealthy": {
           "http_failures": 2,
           "http_statuses": [
             429,
             404,
             500,
             501,
             502,
             503,
             504,
             505
           ],
           "interval": 1,
           "tcp_failures": 2,
           "timeouts": 3
         }
       }
     },
     "scheme": "http",
     "pass_host": "pass",
     "name": "Nginx",
     "keepalive_pool": {
       "idle_timeout": 60,
       "requests": 1000,
       "size": 320
     }
   }`
   
   nginx conf:
   `worker_processes 1;
   error_log stderr notice;
   events {
       worker_connections 1024;
   }
   
   http {
       variables_hash_max_size 1024;
       access_log  /var/log/nginx/access.log;
       real_ip_header X-Real-IP;
       charset utf-8;
   
       server {
           listen 80;
           
           location / {
               return 200 "It's a backend web server, built with nginx \n";
           }
   
           location /health {
               return 200 "OK";
           }
   
           access_log  /var/log/nginx/domain1.access.log;
       }
   }
   `
   
   I'm pretty sure the connection and gateway function is fine.
   Did I do something dumb?
   
   ### Environment
   
   - APISIX version (run `apisix version`):3.6.0
   - Operating system (run `uname -a`):docker
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl 
http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`):
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to