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

wait for active downloads during shutdown #116

Open
9001 opened this issue Nov 9, 2024 · 0 comments
Open

wait for active downloads during shutdown #116

9001 opened this issue Nov 9, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@9001
Copy link
Owner

9001 commented Nov 9, 2024

currently, during shutdown, all tcp sockets/connections are closed immediately.

consider only closing the listening socket, and let client connections linger for some time, until all active downloads have had a chance to finish.

this would be useful during upgrades; could start shutting down the old instance, then launch the new one, and let the old one expire on its own when ready. But there's a couple things to keep in mind,

  • ongoing uploads must be terminated immediately to avoid multiple instances writing into the same target files
  • kill background tasks (up2k snapshots/rescans etc.) so they don't trample eachother
  • check if there's any interesting opportunities for sqlite deadlocks
@9001 9001 added the enhancement New feature or request label Nov 9, 2024
@9001 9001 self-assigned this Nov 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant