openHPI / poseidon

Scalable task execution orchestrator for CodeOcean
MIT License
8 stars 1 forks source link

Fix Runner-Meta-Tag "Used" #621

Closed mpass99 closed 3 weeks ago

mpass99 commented 3 months ago

Due to several reasons such as a restart (e.g. due to OOM Kill) or a rescheduling, we consider the runner to be clean and idle again. This is a valid case for an increased prewarming pool.

However, when doing so the ConfigMetaUsed-Value is not adjusted (so it stays marked as used). This is an inaccuracy that in the case of an Environment and Runner Recovery leads to the runner being handled like a used one and a replacement idle runner will be requested.

We should fix this by marking the runner as unused when doing so internally in Poseidon.

mpass99 commented 3 months ago

We again wanted to verify if we get a clean filesystem on restart.

We create a Job, connect to it, place flags in different folders (/tmp, /workspace), and kill 1 so the task gets restarted. We connect again and check for the flags. They are gone.

This complies with our theoretical view of the restart process: The Docker container stops, Nomad notices this and starts a new Docker instance that has the files declared in the image and mounted volumes (which we don't use), but not more [1].