Skip to content
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

Honor the 'rest' option #530

Merged
merged 2 commits into from
Mar 15, 2023
Merged

Honor the 'rest' option #530

merged 2 commits into from
Mar 15, 2023

Conversation

khepin
Copy link
Collaborator

@khepin khepin commented Mar 13, 2023

From #529

Looks like we correctly honor all of the other queue:work options and have kept maintaining compatibility with queue:work.
There are also other options from queue:work that we honor despite the fact that they make little sense with this consumer. For example sleep when the queue is empty is useful for queues where you pull the work from the queue. Especially ones like SQS where you get charged every time you make a request. But when doing basic_consume this makes little sense yet it is respected by this package.

Our other choices with this --rest options would be:

  1. accept it but ignore it (current situation). Making it the first of the queue:work options we are not compatible with
  2. remove it (would break compatibility with queue:work by throwing an exception for providing an undefined option)
  3. accept it and output a warning

@khepin khepin marked this pull request as ready for review March 13, 2023 20:48
src/Consumer.php Outdated Show resolved Hide resolved
@adm-bome adm-bome linked an issue Mar 13, 2023 that may be closed by this pull request
@khepin khepin merged commit a83eff9 into master Mar 15, 2023
@adm-bome adm-bome deleted the increase-compatibility branch April 11, 2023 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't add a delay between consumption of messages.
2 participants