Skip to content

Commit

Permalink
Consumer fix: reject message from queue and do not requeue when retur…
Browse files Browse the repository at this point in the history
…ning IConsumer::MESSAGE_REJECT
  • Loading branch information
paveljanda committed Jul 12, 2017
1 parent cf7a6be commit d07c9a0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Consumer/Consumer.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ function (Message $message, Channel $channel, Client $client): void {
break;

case IConsumer::MESSAGE_REJECT:
$channel->reject($message); // Message will be discarded
$channel->reject($message, FALSE); // Message will be discarded
break;

default:
Expand Down Expand Up @@ -108,7 +108,7 @@ public function consumeSpecifiedAmountOfMessages(int $amountOfMessages): void
break;

case IConsumer::MESSAGE_REJECT:
$channel->reject($message); // Message will be discarded
$channel->reject($message, FALSE); // Message will be discarded
break;

default:
Expand Down

0 comments on commit d07c9a0

Please sign in to comment.