Skip to content

amqp long running jobs - graceful shutdown #1938

Answered by rustatian
dr-diesel asked this question in Q&A
Discussion options

You must be logged in to vote

num_pollers is relevant for long running tasks

Yes, because while consuming the items from the priority queue, goroutine will wait for the response from the PHP worker.

I don't close amqp via RPC

I didn't say about RPC. But this doesn't matter actually, since the mechanism is the same.

waiting pollers can't nack() their waiting jobs.

That's actually doesn't matter from the broker POV, since the message would be simply re-delivered.

Couldn't the amqp driver stop only consuming in this stage and shutdown later after pollers and workers are done ?

Actually can, during the grace timeout period, but this is not implemented.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@dr-diesel
Comment options

@rustatian
Comment options

Answer selected by rustatian
@rustatian
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
P-jobs Plugin: Jobs
2 participants