Skip to content

Comments

Fix max runners check and leaky JIT runners#620

Merged
gabriel-samfira merged 1 commit intocloudbase:mainfrom
gabriel-samfira:fix-leaky-jit
Feb 11, 2026
Merged

Fix max runners check and leaky JIT runners#620
gabriel-samfira merged 1 commit intocloudbase:mainfrom
gabriel-samfira:fix-leaky-jit

Conversation

@gabriel-samfira
Copy link
Member

The check for max runners was added to CreateInstance(), but we crete the JIT runners before we run the function to add a runner to the DB. The defer function to clean up the JIT runner was being run after the error return generated by CreateInstance. So the cleanup code never ran. Additionally we would know that max runners was reached only after creating the JIT runner. Which kills rate limits.

The check for max runners was added to CreateInstance(), but we crete the
JIT runners before we run the function to add a runner to the DB. The defer
function to clean up the JIT runner was being run after the error return
generated by CreateInstance. So the cleanup code never ran. Additionally
we would know that max runners was reached only after creating the JIT
runner. Which kills rate limits.

Signed-off-by: Gabriel Adrian Samfira <gsamfira@cloudbasesolutions.com>
@gabriel-samfira gabriel-samfira merged commit 80e08e7 into cloudbase:main Feb 11, 2026
4 checks passed
@gabriel-samfira gabriel-samfira deleted the fix-leaky-jit branch February 11, 2026 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant