kainxspirits / laravel-pubsub-queue

A Laravel queue driver for Google PubSub.
MIT License
45 stars 36 forks source link

Feature/configurable pull and acknowledge timeouts #24

Closed v8-ict closed 5 years ago

v8-ict commented 5 years ago

After some investigation using returnImmediatly is quite risky duo to client side connection termination..

See: https://github.com/googleapis/google-cloud-php/issues/710

I now solved it, to configure a timeout to keep pulling with returnImmediately => true for a specific period of time.

I wonder. If we should mention in the readme, that configure-ing acknowledge_deadline is required, if you run more then one worker per queue.

I also have your unmerged open branch inside, because i already merged it into my fork, as i needed it to get the attempts property to work...

I set the default acknowledge deadline to 60 seconds, as this is also the default timeout that workers have if, no flags are passed...

v8-ict commented 5 years ago

Closing this PR. because i still have some issues with the ackDeadline, i am testing them some more in production, to be sure it's a solid solution