Subject: | Bug in list_vaults |
Marker string in list_vaults must be preceded by the 'marker=' keyword
(see https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vaults-get.html)
The bug reveals itself when you have more than 10 vaults.
Patch attached.
Subject: | 2-use_marker_parameter.patch |
Marker string in list_vaults must be preceded by the 'marker=' keyword
(see https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vaults-get.html)
Index: Net-Amazon-Glacier-0.15/lib/Net/Amazon/Glacier.pm
--- Net-Amazon-Glacier-0.15-orig/lib/Net/Amazon/Glacier.pm 2014-08-05 21:34:59.000000000 +0200
+++ Net-Amazon-Glacier-0.15/lib/Net/Amazon/Glacier.pm 2018-12-15 15:03:16.353338147 +0100
@@ -197,7 +197,7 @@ sub list_vaults {
my $marker;
do {
#1000 is the default limit, send a marker if needed
- my $res = $self->_send_receive( GET => "/-/vaults?limit=1000" . ($marker?'&'.$marker:'') );
+ my $res = $self->_send_receive( GET => "/-/vaults?limit=1000" . ($marker?'&marker='.$marker:'') );
# updated error severity
croak 'list_vaults failed with error ' . $res->status_line unless $res->is_success;
my $decoded = $self->_decode_and_handle_response( $res );