Skip to content
This repository has been archived by the owner on Apr 27, 2023. It is now read-only.

Create http endpoint for preStop hook #1310

Closed
erkannt opened this issue Aug 13, 2020 · 1 comment · Fixed by libero/reviewer-submission#223
Closed

Create http endpoint for preStop hook #1310

erkannt opened this issue Aug 13, 2020 · 1 comment · Fixed by libero/reviewer-submission#223
Assignees
Milestone

Comments

@erkannt
Copy link
Contributor

erkannt commented Aug 13, 2020

We want to keep file uploads alive during rollouts of submission for a certain grace period.

This will partially rely on the k8s feature of preStop hooks. These delay the sending of SIGTERM until the hook(s) have completed. The hooks can be commands executed inside the container or http requests.

Note that if the overall grace period is exceeded during the preStop hook the container will receive a SIGKILL.

To avoid waiting needlessly, say by using sleep, we ideally need an http endpoint that answers with 200 once all or at least the upload connections have been closed.

This is a requirement for #998 and a precursor to the validation on submission in #1306

@norisalsaadie
Copy link
Contributor

After careful consideration, it made more sense to gracefully handle sigterm and wait for the close event to be handled. As reflected in libero/reviewer-submission#223

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

Successfully merging a pull request may close this issue.

2 participants