-
-
Notifications
You must be signed in to change notification settings - Fork 2
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
Add enqueue_multi
#38
Comments
Yes some sort of batched enqueue and dequeue makes sense to me. |
could this one also be for |
Certainly! |
@kirillsalykin are you planning to take this on? |
i plan to work on this next week, lets not postpone release because of this - dont want to be a stopper. |
hi @maxcountryman I see this implemented as:
where
This approach lets the user schedule different tasks in one go (as long as they go into the same queue). Questions:
What do you think? I'd love your feedback. P.S. I’m new to Rust, so feel free to correct any mistakes. |
which makes me think, maybe |
I'm a little bit confused re the purpose of the
I think it's important to return
I suspect it's true we may want to implement |
I just checked the thank you for a pointer. |
Hi @maxcountryman, |
Hey no worries at all! I don't think there's a big rush here, so let's wait for the New Year. If someone comes along and needs it before then we can reassess and see if they'd like to contribute, etc. Very much appreciate your contributions and please don't feel any pressure whatsoever. :) |
thanks! |
As an aside here, it looks like this might be somewhat of a challenge in The query builder approach may be the best option but it's not perfect. |
indeed |
Sometimes you want to enqueue a lot of jobs, like 10_000 or more, inserting task one-by-one is not very performant.
Something like can speed up things a lot
psql is limited params number limite to
65535
, so if my calculations are correct, it can be inserted around5.461,25
tasks at a time, lets round it to 5000.So if it is needed to enqueue 10_000 tasks, it can be done in two batched by 5_000.
what do you think?
The text was updated successfully, but these errors were encountered: