This method allows a client to reject one or more incoming messages. It can be used to interrupt and cancel large incoming messages, or return untreatable messages to their original queue. :param integer delivery_tag: int/long The server-assigned delivery tag :param
(self,
delivery_tag: int = 0,
multiple: bool = False,
requeue: bool = True)
| 434 | self._send_method(spec.Basic.Get(queue=queue, no_ack=auto_ack)) |
| 435 | |
| 436 | def basic_nack(self, |
| 437 | delivery_tag: int = 0, |
| 438 | multiple: bool = False, |
| 439 | requeue: bool = True) -> None: |
| 440 | """This method allows a client to reject one or more incoming messages. |
| 441 | It can be used to interrupt and cancel large incoming messages, or |
| 442 | return untreatable messages to their original queue. |
| 443 | |
| 444 | :param integer delivery_tag: int/long The server-assigned delivery tag |
| 445 | :param bool multiple: If set to True, the delivery tag is treated as |
| 446 | "up to and including", so that multiple messages |
| 447 | can be acknowledged with a single method. If set |
| 448 | to False, the delivery tag refers to a single |
| 449 | message. If the multiple field is 1, and the |
| 450 | delivery tag is zero, this indicates |
| 451 | acknowledgement of all outstanding messages. |
| 452 | :param bool requeue: If requeue is true, the server will attempt to |
| 453 | requeue the message. If requeue is false or the |
| 454 | requeue attempt fails the messages are discarded or |
| 455 | dead-lettered. |
| 456 | |
| 457 | """ |
| 458 | self._raise_if_not_open() |
| 459 | return self._send_method( |
| 460 | spec.Basic.Nack(delivery_tag, multiple, requeue)) |
| 461 | |
| 462 | def basic_publish(self, |
| 463 | exchange: str, |