feat(backends): add Uninstall method to Backend interface and uninstall-backend endpoint#770
Merged
doringeman merged 1 commit intodocker:mainfrom Mar 20, 2026
Conversation
Contributor
There was a problem hiding this comment.
Hey - I've left some high level feedback:
- Scheduler.UninstallBackend proceeds with installer.uninstallBackend even if UnloadBackend leaves active runners with non-zero references, which can result in running processes using files that have been removed; consider returning an error or blocking until all references are drained before uninstalling the backend.
- The new loader.UnloadBackend logic partly duplicates the eviction behavior in Unload; you might want to reuse or refactor the existing unload path so that runner selection and logging remain consistent and future changes to eviction behavior don’t need to be updated in multiple places.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- Scheduler.UninstallBackend proceeds with installer.uninstallBackend even if UnloadBackend leaves active runners with non-zero references, which can result in running processes using files that have been removed; consider returning an error or blocking until all references are drained before uninstalling the backend.
- The new loader.UnloadBackend logic partly duplicates the eviction behavior in Unload; you might want to reuse or refactor the existing unload path so that runner selection and logging remain consistent and future changes to eviction behavior don’t need to be updated in multiple places.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
ilopezluna
approved these changes
Mar 20, 2026
…ll-backend endpoint Deferred backends (vllm-metal, diffusers) install to local directories but had no cleanup path; this lets the CLI trigger backend removal via the running model-runner. Signed-off-by: Dorin Geman <dorin.geman@docker.com>
e9c195e to
72809c5
Compare
Contributor
|
Warning Gemini is experiencing higher than usual traffic and was unable to create the review. Please try again in a few hours by commenting |
ericcurtin
approved these changes
Mar 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Deferred backends (vllm-metal, diffusers) install to local directories but had no cleanup path; this lets the CLI trigger backend removal via the running model-runner.
On uninstalling, the backend will first be unloaded.
Server logs: