Specification
Some RPC handlers are preforming long running async tasks. In these cases they need to make use of the provided ctx and handle cancellation gracefully to prevent any resource leaks. A clear example of this is the vaults pull and clone handlers.
So we need to review handlers and update the ones that need CTX handling applied.
Additional context
Tasks
- Review all RPC handlers and identify ones that preform complex async or long running tasks.
- Refactor theses handlers to handle cancellation in a responsive and graceful manor.
- Apply testing to see if timing out during these tasks causes any problems. Possibly apply regression testing for this.