Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Mark initial service health check as passing (#138)
* Mark initial service health check as passing Sometimes for few seconds after deployment new service version there is no healthy instances of this service in consul. Currently consul hook registers new service instance into consul right after marathon health check passess. According to tests I performed and consul documentation registered service's health check is in critical state after registration. It stays in this state until first health check invocation (in practice for few seconds). Consul hook ignores this behaviour and removes old service instance from consul immediately. In result there is no healthy service instances in consul for few seconds. The best way to fix this problem is to register new service instance with it's healthcheck status equal to passing. As consul health check is the same as marathon healthcheck and consul registration is triggered by marathon healtcheck status change to passing we can assume consul healtcheck status is also passing.
- Loading branch information