Replies: 1 comment
-
|
re (1) this is a good request, please put it on Issues -> Feature Request, should be easy, pending detail discussion in the issue or the discord PR will be welcome |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Use Case
We run SwarmUI in a VFX studio environment with multiple artists sharing a common GPU render pool. Currently, the queue is strictly FIFO — whoever submits first gets processed first, with no way to differentiate between urgent production renders and casual experimentation.
This creates real problems:
Related Issues
Proposed Features
1. Per-user priority levels
Add an integer
Priorityfield toT2IBackendRequest. Higher priority requests get dequeued first. Default priority = 0 preserves current FIFO behavior for existing single-user setups.Priority could be:
2. Fair-share scheduling (optional)
When multiple users have the same priority level, distribute GPU time fairly using round-robin or weighted fair queuing instead of pure FIFO. This prevents one user from monopolizing the queue with a large batch.
Example: User A submits 100 images, then User B submits 5. Currently B waits for all 100. With fair-share, they’d alternate (or use weighted interleaving).
3. Queue visibility API
A
/API/QueueStatusendpoint returning:This enables building dashboards for studio supervisors.
4. Per-user cancel isolation
Building on #781 — ensure that cancel operations are scoped to the requesting user’s session. Admins could have a "cancel all" capability, but regular users should only cancel their own jobs.
Implementation Approach
I’ve looked through the codebase and believe the changes would be primarily in:
src/Backends/BackendHandler.cs— replaceConcurrentQueuewith a priority-aware structure inRequestHandlingLoopsrc/WebAPI/BackendAPI.cs— add queue status endpointI’m happy to submit a PR for this. Before I start coding, I wanted to check:
Happy to follow whatever code style and approach works best for the project. Thanks for building such a great tool!
Beta Was this translation helpful? Give feedback.
All reactions