apisix icon indicating copy to clipboard operation
apisix copied to clipboard

request help: Health Checks can support customized PORT ?

Open souzens opened this issue 6 years ago • 3 comments

sometimes http work and health check listen on different ports ,

like spring boot cloud http api request works on 8080, but actuator health works on 8888 port

so a router config like :

            "active": {
                "http_path": "/actuator/health",
                "port": "8888",
                "host": "test",
                "healthy": {
                    "interval": 2,
                    "successes": 1
                },
                "unhealthy": {
                    "interval": 1,
                    "http_failures": 2
                }
            },
            "passive": {
                "healthy": {
                    "http_statuses": [200],
                    "successes": 3
                },
                "unhealthy": {
                    "http_statuses": [503,404],
                    "http_failures": 3,
                    "tcp_failures": 3
                }
            }

i did not find any health port define in https://github.com/apache/incubator-apisix/blob/master/apisix/schema_def.lua#L81

is it supported now ?

Originally posted by @souzens in https://github.com/apache/incubator-apisix/issues/1809#issuecomment-654671064

souzens avatar Jul 07 '20 09:07 souzens

yes, we can support this feature. it seems useful.

membphis avatar Jul 07 '20 09:07 membphis

welcome PR

membphis avatar Jul 07 '20 13:07 membphis

I will deal with this problem.

shuaijinchao avatar Jul 19 '20 16:07 shuaijinchao