kue icon indicating copy to clipboard operation
kue copied to clipboard

look into changing over to brpoplpush

Open tj opened this issue 13 years ago • 20 comments

atomic goodness for queues, could get rid of my hack of a zpop

http://redis.io/commands/brpoplpush

tj avatar Jul 19 '11 17:07 tj

Any idea if/when this is coming? It looks like we could really do with this feature too!

Keep up the great work BTW and thanks! :)

maboa avatar Jun 19 '14 11:06 maboa

I'm thinking of doing this on a major version release, specifically 1.0.0 since it requires a very big code change, and kue redesign on redis sets/lists usage.

But you currently should have no problems in many deployment situations with the existing implementation.

behrad avatar Jun 19 '14 12:06 behrad

Thanks Behrad! afaict this will only be an issue if something fails. We need to detect that situation so we can resubmit.

maboa avatar Jun 20 '14 10:06 maboa

when something bad fails, everything can be an issue, event with the atomic brpoplpush

behrad avatar Jun 20 '14 10:06 behrad

As I see it, with atomic brpoplpush the work stays in redis. Without it, there's a brief windows between a pop and a push where, if the node.js process goes down, the work is lost. Am I right?

pgte avatar Jun 20 '14 13:06 pgte

right @pgte , in the current Kue code we have seen a couple of recovery codes from this situation

behrad avatar Jun 20 '14 14:06 behrad

A good example of how to provide priorities: https://github.com/josiahcarlson/rpqueue/blob/master/rpqueue/init.py#L226

behrad avatar Sep 11 '14 17:09 behrad

Any movement on this?

landau avatar Jun 10 '15 15:06 landau

I'd planned to start the refactoring to atomic Kue 1.0 early 2015, however it was my very busy days. I'm thinking of starting it in a few months, and remember this is a really huge refactoring effecting all Kue

behrad avatar Jun 10 '15 18:06 behrad

if you have a local redis instance (or one without poor network connection) you won't face queued stuck jobs. however active stuck jobs is something caused 95% by your app code.

behrad avatar Jun 10 '15 19:06 behrad

Hi, Any progress on this?

pawawat avatar Sep 04 '15 18:09 pawawat

I've been very busy for a couple of months...

behrad avatar Sep 04 '15 18:09 behrad

up ?

vieks avatar Apr 20 '16 06:04 vieks

Hi @tj any plans to work on this?

rturk avatar Oct 14 '16 13:10 rturk

brpoplpush is one of methods of reaching atomicity/consistency but in favor of loosing priorities... I don't want to drop priority queues, and implementing them with brpoplpush adds some complexities. Another method is using lua scripts which is being preferred and implemented in v1 branch currently.

behrad avatar Oct 14 '16 14:10 behrad

@behrad. That's the point: atomicity/consistency is very important for me, priority not. Most my jobs will complete in less than 1s. Appreciate your thoughts about bee-queue?

rturk avatar Jan 15 '17 22:01 rturk

have you tested v1 branch @rturk ? you should align with your requirements if it fits you the bee-queue @rturk

behrad avatar Feb 08 '17 11:02 behrad

@behrad any updates with the 1.0.0 release?

mir-nawaz-10p avatar Jun 07 '17 08:06 mir-nawaz-10p

Hello from 2018, how's 1.0.0 looking?

Palisand avatar Jan 12 '18 15:01 Palisand

hello from future, our cars can flying but kue is still under 1.0.0

MetinSeylan avatar Jul 06 '18 07:07 MetinSeylan