Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a /health endpoint to Federation Extension #522

Open
m-mohr opened this issue Nov 25, 2023 · 4 comments
Open

Add a /health endpoint to Federation Extension #522

m-mohr opened this issue Nov 25, 2023 · 4 comments

Comments

@m-mohr
Copy link
Member

m-mohr commented Nov 25, 2023

In openEO Platform there's a GET /health endpoint used by the aggregator. It would be useful for the federation extension, I think.
It looks like there's no standardized format for the response yet.

Examples:

@soxofaan
Copy link
Member

soxofaan commented Nov 27, 2023

FYI: the aggregator itself also responds to /health:
https://openeocloud.vito.be/openeo/1.1/health

It aggregates the HTTP status code and bodies (if any) of upstream backends: also see https://github.com/Open-EO/openeo-aggregator/blob/e17e9beefb0b787b6be7a97d42beed6a9572822e/src/openeo_aggregator/backend.py#L1357-L1385

@m-mohr
Copy link
Member Author

m-mohr commented Nov 27, 2023

By the way, why did we introduce a new endpoint instead of just checking GET /?

@soxofaan
Copy link
Member

the idea is to do a bit more than just returning a somewhat static capabilities doc. E.g. in geopyspark implementation we do a quick spark operation to verify that the spark basics are working. In the aggregator we also explicitly loop over all upstream back-ends and measure response time.

I think an important aspect here is caching: the capabilities doc is usually very static, so you'll allow heavy caching on that, while a "health" check should be as up to date as possible with as little as caching as possible.

@m-mohr
Copy link
Member Author

m-mohr commented Nov 28, 2023

Makes sense, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants