Subject: | Support no_ack for get() |
Date: | Wed, 19 Aug 2015 15:58:21 -1000 |
To: | bug-AnyEvent-RabbitMQ [...] rt.cpan.org |
From: | Julio Polo <julio [...] hawaii.edu> |
Could you support passing the value of no_ack to the get method? Only two
lines need to change for this to happen:
*** 566,577 ****
my $self = shift;
my ($cb, $failure_cb, %args) = $self->_delete_cbs(@_);
return $self if !$self->_check_open($failure_cb);
$self->{connection}->_push_write_and_read(
'Basic::Get',
{
! no_ack => 1,
%args, # queue
ticket => 0,
},
--- 566,579 ----
my $self = shift;
my ($cb, $failure_cb, %args) = $self->_delete_cbs(@_);
+ my $no_ack = delete $args{no_ack} // 1;
+
return $self if !$self->_check_open($failure_cb);
$self->{connection}->_push_write_and_read(
'Basic::Get',
{
! no_ack => $no_ack,
%args, # queue
ticket => 0,
},
Julio Polo
University of Hawaii