m-lab / ndt-server

docker native ndt5 and ndt7 server with prometheus integration
https://www.measurementlab.net/
Apache License 2.0
101 stars 41 forks source link

Add /health endpoint for ndt-server #376

Closed cristinaleonr closed 2 years ago

cristinaleonr commented 2 years ago

This PR adds a new /health endpoint for ndt-server, which writes out a 200 status code if the server is healthy (i.e., not in lame duck) and an error code otherwise.

This will be queried by the Heartbeat Service and incorporated into the local health assessment for the instance.

This change is Reviewable

coveralls commented 2 years ago

Pull Request Test Coverage Report for Build 1633


Files with Coverage Reduction New Missed Lines %
ndt5/ndt5.go 1 89.5%
ndt5/protocol/protocol.go 2 83.86%
ndt5/web100/web100_linux.go 2 94.44%
ndt5/c2s/c2s.go 3 72.32%
<!-- Total: 8 -->
Totals Coverage Status
Change from base Build 1623: 0.03%
Covered Lines: 1819
Relevant Lines: 2228

💛 - Coveralls