Skip Menu |

This queue is for tickets about the Net-Amazon-Glacier CPAN distribution.

Report information
The Basics
Id: 128028
Status: new
Priority: 0/
Queue: Net-Amazon-Glacier

People
Owner: Nobody in particular
Requestors: SGRAY [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: (no value)
Fixed in: (no value)



Subject: improper HTTP method in get_vault_notifications
The get_vault_notifications should use GET, instead of PUT (https://docs.aws.amazon.com/amazonglacier/latest/dev/api-vault-notifications-get.html) The attached patch fixes this as well as some minor typos in croak messages.
Subject: 1-get_vault_notifications.patch
Fix misguiding croak messages. Fix HTTP method in get_vault_notifications (must be GET) 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:01:13.148498597 +0100 @@ -125,7 +125,7 @@ sub create_vault { my $res = $self->_send_receive( PUT => "/-/vaults/$vault_name" ); # updated error severity - croak 'describe_vault failed with error ' . $res->status_line + croak 'create_vault failed with error ' . $res->status_line unless $res->is_success; return 1; @@ -247,7 +247,7 @@ sub set_vault_notifications { encode_json($content_raw), ); # updated error severity - croak 'get_vault_notifications failed with error ' . $res->status_line + croak 'set_vault_notifications failed with error ' . $res->status_line unless $res->is_success; return 1; @@ -270,7 +270,7 @@ sub get_vault_notifications { croak "no vault name given" unless $vault_name; my $res = $self->_send_receive( - PUT => "/-/vaults/$vault_name/notification-configuration", + GET => "/-/vaults/$vault_name/notification-configuration", ); # updated error severity croak 'get_vault_notifications failed with error ' . $res->status_line