r47100 - in /branches/upstream/libnet-amazon-ec2-perl/current: lib/Net/Amazon/ lib/Net/Amazon/EC2/ t/

jawnsy-guest at users.alioth.debian.org jawnsy-guest at users.alioth.debian.org
Fri Nov 13 13:44:56 UTC 2009


Author: jawnsy-guest
Date: Fri Nov 13 13:44:43 2009
New Revision: 47100

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=47100
Log:
[svn-upgrade] Integrating new upstream version, libnet-amazon-ec2-perl (0.11)

Added:
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZoneMessage.pm
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/CreateVolumePermission.pm
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/SnapshotAttribute.pm
Modified:
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2.pm
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZone.pm
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/BundleInstanceResponse.pm
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/RunningInstances.pm
    branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/Snapshot.pm
    branches/upstream/libnet-amazon-ec2-perl/current/t/00_use.t

Modified: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2.pm?rev=47100&op=diff
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2.pm (original)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2.pm Fri Nov 13 13:44:43 2009
@@ -47,9 +47,11 @@
 use Net::Amazon::EC2::ReservedInstanceOffering;
 use Net::Amazon::EC2::MonitoredInstance;
 use Net::Amazon::EC2::InstancePassword;
-use Data::Dumper qw(Dumper);
-
-$VERSION = '0.10';
+use Net::Amazon::EC2::SnapshotAttribute;
+use Net::Amazon::EC2::CreateVolumePermission;
+use Net::Amazon::EC2::AvailabilityZoneMessage;
+
+$VERSION = '0.11';
 
 =head1 NAME
 
@@ -59,9 +61,9 @@
 =head1 VERSION
 
 
-This document describes version 0.10 of Net::Amazon::EC2, released
-September 23rd, 2009. This module is coded against the Query API version of the '2009-07-15' 
-version of the EC2 API last updated September 3, 2009.
+This document describes version 0.11 of Net::Amazon::EC2, released
+November 12th, 2009. This module is coded against the Query API version of the '2009-08-15' 
+version of the EC2 API last updated November 10th, 2009.
 
 =head1 SYNOPSIS
 
@@ -125,7 +127,7 @@
 has 'SecretAccessKey'	=> ( is => 'ro', isa => 'Str', required => 1 );
 has 'debug'				=> ( is => 'ro', isa => 'Str', required => 0, default => 0 );
 has 'signature_version'	=> ( is => 'ro', isa => 'Int', required => 1, default => 1 );
-has 'version'			=> ( is => 'ro', isa => 'Str', required => 1, default => '2009-07-15' );
+has 'version'			=> ( is => 'ro', isa => 'Str', required => 1, default => '2009-08-15' );
 has 'base_url'			=> ( is => 'ro', isa => 'Str', required => 1, default => 'http://ec2.amazonaws.com' );
 has 'timestamp'			=> ( is => 'ro', isa => 'Str', required => 1, default => sub { my $ts = time2isoz(); chop($ts); $ts .= '.000Z'; $ts =~ s/\s+/T/g; return $ts; } );
 
@@ -160,12 +162,10 @@
 		%args
 	);
 	
-	$uri->query_form(\%params);
-	
 	my $ur	= $uri->as_string();
 	$self->_debug("GENERATED QUERY URL: $ur");
 	my $ua	= LWP::UserAgent->new();
-	my $res	= $ua->post($ur);
+	my $res	= $ua->post($ur, \%params);
 	# We should force <item> elements to be in an array
 	my $xs	= XML::Simple->new(ForceArray => qr/(?:item|Errors)/i);
 	my $xml;
@@ -511,6 +511,8 @@
 			s3_aws_access_key_id		=> $xml->{bundleInstanceTask}{storage}{S3}{bucket},
 			s3_upload_policy			=> $xml->{bundleInstanceTask}{storage}{S3}{bucket},
 			s3_policy_upload_signature	=> $xml->{bundleInstanceTask}{storage}{S3}{bucket},
+			bundle_error_code			=> $xml->{bundleInstanceTask}{error}{code},
+			bundle_error_message		=> $xml->{bundleInstanceTask}{error}{message},
 		);
 		
 		return $bundle;
@@ -557,6 +559,8 @@
 			s3_aws_access_key_id		=> $xml->{bundleInstanceTask}{storage}{S3}{bucket},
 			s3_upload_policy			=> $xml->{bundleInstanceTask}{storage}{S3}{bucket},
 			s3_policy_upload_signature	=> $xml->{bundleInstanceTask}{storage}{S3}{bucket},
+			bundle_error_code			=> $xml->{bundleInstanceTask}{error}{code},
+			bundle_error_message		=> $xml->{bundleInstanceTask}{error}{message},
 		);
 		
 		return $bundle;
@@ -696,6 +700,10 @@
 
 The volume id of the volume you want to take a snapshot of.
 
+=item Description (optional)
+
+Description of the Amazon EBS snapshot.
+
 =back
 
 Returns a Net::Amazon::EC2::Snapshot object of the newly created snapshot.
@@ -706,6 +714,7 @@
 	my $self = shift;
 	my %args = validate( @_, {
 		VolumeId	=> { type => SCALAR },
+		Description	=> { type => SCALAR, optional => 1 },
 	});
 	
 	my $xml = $self->_sign(Action  => 'CreateSnapshot', %args);
@@ -725,6 +734,9 @@
 			volume_id		=> $xml->{volumeId},
 			start_time		=> $xml->{startTime},
 			progress		=> $xml->{progress},
+			owner_id		=> $xml->{ownerId},
+			volume_size		=> $xml->{volumeSize},
+			description		=> $xml->{description},
 		);
 
   		return $snapshot;
@@ -1084,10 +1096,21 @@
 	else {
 		my $availability_zones;
 		foreach my $az (@{$xml->{availabilityZoneInfo}{item}}) {
+			my $availability_zone_messages;
+			# Create the messages for this zone
+			foreach my $azm (@{$az->{messageSet}{item}}) {
+				my $availability_zone_message = Net::Amazon::EC2::AvailabilityZoneMessage->new(
+					message => $azm->{message},
+				);
+				
+				push @$availability_zone_messages, $availability_zone_message;
+			}
+			
 			my $availability_zone = Net::Amazon::EC2::AvailabilityZone->new(
 				zone_name	=> $az->{zoneName},
 				zone_state	=> $az->{zoneState},
 				region_name	=> $az->{regionName},
+				messages	=> $availability_zone_messages,
 			);
 			
 			push @$availability_zones, $availability_zone;
@@ -1140,6 +1163,8 @@
 				s3_aws_access_key_id		=> $item->{storage}{S3}{bucket},
 				s3_upload_policy			=> $item->{storage}{S3}{bucket},
 				s3_policy_upload_signature	=> $item->{storage}{S3}{bucket},
+				bundle_error_code			=> $item->{error}{code},
+				bundle_error_message		=> $item->{error}{message},
 			);
 			
 			push @$bundle_tasks, $bundle;
@@ -1439,6 +1464,8 @@
 					ami_launch_index	=> $instance_elem->{amiLaunchIndex},
 					dns_name			=> $instance_elem->{dnsName},
 					image_id			=> $instance_elem->{imageId},
+					kernel_id			=> $instance_elem->{kernelId},
+					ramdisk_id			=> $instance_elem->{ramdiskId},
 					instance_id			=> $instance_elem->{instanceId},
 					instance_state		=> $instance_state_type,
 					instance_type		=> $instance_elem->{instanceType},
@@ -1449,6 +1476,10 @@
 					reason				=> $instance_elem->{reason},
 					platform			=> $instance_elem->{platform},
 					monitoring			=> $instance_elem->{monitoring}{state},
+					subnet_id			=> $instance_elem->{subnetId},
+					vpc_id				=> $instance_elem->{vpcId},
+					private_ip_address	=> $instance_elem->{privateIpAddress},
+					ip_address			=> $instance_elem->{ipAddress},
 				);
 
 				if ($product_codes) {
@@ -1817,27 +1848,32 @@
 	}
 }
 
-=head2 describe_snapshots(%params)
-
-Describes the snapshots currently created. It takes the following arguments:
+=head2 describe_snapshot_attribute(%params)
+
+Describes the snapshots attributes related to the snapshot in question. It takes the following arguments:
 
 =over
 
 =item SnapshotId (optional)
 
 Either a scalar or array ref of snapshot id's can be passed in. If this isn't passed in
-it will describe all the current snapshots.
-
-=back
-
-Returns an array ref of Net::Amazon::EC2::Snapshot objects.
-
-=cut
-
-sub describe_snapshots {
-	my $self = shift;
-	my %args = validate( @_, {
-		SnapshotId	=> { type => ARRAYREF | SCALAR, optional => 1 },
+it will describe the attributes of all the current snapshots.
+
+=item Attribute (required)
+
+The attribute to describe, currently, the only valid attribute is createVolumePermission.
+
+=back
+
+Returns a Net::Amazon::EC2::SnapshotAttribute object.
+
+=cut
+
+sub describe_snapshot_attribute {
+	my $self = shift;
+	my %args = validate( @_, {
+		SnapshotId		=> { type => ARRAYREF | SCALAR, optional => 1 },
+		Attribute		=> { type => SCALAR },
 	});
 
 	# If we have a array ref of volumes lets split them out into their SnapshotId.n format
@@ -1850,8 +1886,81 @@
 		}
 	}
 	
+	my $xml = $self->_sign(Action  => 'DescribeSnapshotAttribute', %args);
+	
+	if ( grep { defined && length } $xml->{Errors} ) {
+		return $self->_parse_errors($xml);
+	}
+	else {
+		my $perms;
+		
+		unless ( grep { defined && length } $xml->{createVolumePermission} and ref $xml->{createVolumePermission} ne 'HASH') {
+			$perms = undef;
+		}
+
+ 		foreach my $perm_item (@{$xml->{createVolumePermission}{item}}) {
+ 			my $perm = Net::Amazon::EC2::CreateVolumePermission->new(
+ 				user_id			=> $perm_item->{userId},
+ 				group			=> $perm_item->{group},
+ 			);
+ 			
+ 			push @$perms, $perm;
+ 		}
+
+		my $snapshot_attribute = Net::Amazon::EC2::SnapshotAttribute->new(
+			snapshot_id		=> $xml->{snapshotId},
+			permissions		=> $perms,
+		);
+ 		
+ 		return $snapshot_attribute;
+	}
+}
+
+
+=head2 describe_snapshots(%params)
+
+Describes the snapshots available to the user. It takes the following arguments:
+
+=over
+
+=item SnapshotId (optional)
+
+Either a scalar or array ref of snapshot id's can be passed in. If this isn't passed in
+it will describe all the current snapshots.
+
+=item Owner (optional)
+
+The owner of the snapshot.
+
+=item RestorableBy (optional)
+
+A user who can create volumes from the snapshot.
+
+=back
+
+Returns an array ref of Net::Amazon::EC2::Snapshot objects.
+
+=cut
+
+sub describe_snapshots {
+	my $self = shift;
+	my %args = validate( @_, {
+		SnapshotId		=> { type => ARRAYREF | SCALAR, optional => 1 },
+		Owner			=> { type => SCALAR, optional => 1 },
+		RestorableBy	=> { type => SCALAR, optional => 1 },
+	});
+
+	# If we have a array ref of volumes lets split them out into their SnapshotId.n format
+	if (ref ($args{SnapshotId}) eq 'ARRAY') {
+		my $snapshots		= delete $args{SnapshotId};
+		my $count			= 1;
+		foreach my $snapshot (@{$snapshots}) {
+			$args{"SnapshotId." . $count} = $snapshot;
+			$count++;
+		}
+	}
+	
 	my $xml = $self->_sign(Action  => 'DescribeSnapshots', %args);
-
 	
 	if ( grep { defined && length } $xml->{Errors} ) {
 		return $self->_parse_errors($xml);
@@ -1860,12 +1969,19 @@
  		my $snapshots;
 
  		foreach my $snap (@{$xml->{snapshotSet}{item}}) {
+			unless ( grep { defined && length } $snap->{description} and ref $snap->{description} ne 'HASH') {
+				$snap->{description} = undef;
+			}
+
  			my $snapshot = Net::Amazon::EC2::Snapshot->new(
  				snapshot_id		=> $snap->{snapshotId},
  				status			=> $snap->{status},
  				volume_id		=> $snap->{volumeId},
  				start_time		=> $snap->{startTime},
  				progress		=> $snap->{progress},
+ 				owner_id		=> $snap->{ownerId},
+ 				volume_size		=> $snap->{volumeSize},
+ 				description		=> $snap->{description},
  			);
  			
  			push @$snapshots, $snapshot;
@@ -2190,6 +2306,65 @@
 	}
 }
 
+=head2 modify_snapshot_attribute(%params)
+
+This method modifies attributes of a snapshot.
+
+=over
+
+=item SnapshotId (required)
+
+The snapshot id to modify the attributes of.
+
+=item UserId (optional)
+
+User Id you wish to add/remove create volume permissions for.
+
+=item UserGroup (optional)
+
+User Id you wish to add/remove create volume permissions for. To make the snapshot createable by all
+set the UserGroup to "all".
+
+=item Attribute (required)
+
+The attribute you wish to modify, right now the only attribute you can modify is "CreateVolumePermission" 
+
+=item OperationType (required)
+
+The operation you wish to perform on the attribute. Right now just 'add' and 'remove' are supported.
+
+=back
+
+Returns 1 if the modification succeeds.
+
+=cut
+
+sub modify_snapshot_attribute {
+	my $self = shift;
+	my %args = validate( @_, {
+		SnapshotId		=> { type => SCALAR },
+		UserId			=> { type => SCALAR, optional => 1 },
+		UserGroup		=> { type => SCALAR, optional => 1 },
+		Attribute		=> { type => SCALAR },
+		OperationType	=> { type => SCALAR },
+	});
+	
+	
+	my $xml = $self->_sign(Action  => 'ModifySnapshotAttribute', %args);
+	
+	if ( grep { defined && length } $xml->{Errors} ) {
+		return $self->_parse_errors($xml);
+	}
+	else {
+		if ($xml->{return} eq 'true') {
+			return 1;
+		}
+		else {
+			return undef;
+		}
+	}
+}
+
 =head2 monitor_instances(%params)
 
 Enables monitoring for a running instance. For more information, refer to the Amazon CloudWatch Developer Guide.
@@ -2455,6 +2630,51 @@
 	});
 	
 	my $xml = $self->_sign(Action  => 'ResetImageAttribute', %args);
+
+	if ( grep { defined && length } $xml->{Errors} ) {
+		return $self->_parse_errors($xml);
+	}
+	else {
+		if ($xml->{return} eq 'true') {
+			return 1;
+		}
+		else {
+			return undef;
+		}
+	}
+}
+
+=head2 reset_snapshot_attribute(%params)
+
+This method resets an attribute for an snapshot to its default state.
+
+It takes the following parameters:
+
+=over
+
+=item SnapshotId (required)
+
+The snapshot id of the snapshot you wish to reset the attributes on.
+
+=item Attribute (required)
+
+The attribute you want to reset (currently "CreateVolumePermission" is the only
+valid attribute).
+
+=back
+
+Returns 1 if the attribute reset succeeds.
+
+=cut
+
+sub reset_snapshot_attribute {
+	my $self = shift;
+	my %args = validate( @_, {
+		SnapshotId	=> { type => SCALAR },
+		Attribute	=> { type => SCALAR },
+	});
+	
+	my $xml = $self->_sign(Action  => 'ResetSnapshotAttribute', %args);
 
 	if ( grep { defined && length } $xml->{Errors} ) {
 		return $self->_parse_errors($xml);
@@ -2573,6 +2793,10 @@
 
 An scalar or array ref. Will associate this instance with the group names passed in.  If omitted, will be associated with the default security group.
 
+=item AdditionalInfo (optional)
+
+Specifies additional information to make available to the instance(s).
+
 =item UserData (optional)
 
 Optional data to pass into the instance being started.  Needs to be base64 encoded.
@@ -2602,6 +2826,14 @@
 =item c1.xlarge: High-CPU Extra Large Instance
 
 20 EC2 Compute Units (8 virtual cores with 2.5 EC2 Compute Units each). 64-bit, 7GB RAM, 1690GB disk
+
+=item m2.2xlarge
+
+13 EC2 Compute Units (4 virtual cores with 3.25 EC2 Compute Units each). 64-bit, 34.2GB RAM, 850GB disk
+
+=item m2.4xlarge
+
+26 EC2 Compute Units (8 virtual cores with 3.25 EC2 Compute Units each). 64-bit, 68.4GB RAM, 1690GB disk
 
 =back 
 
@@ -2636,6 +2868,10 @@
 =item Monitoring.Enabled (optional)
 
 Enables monitoring for this instance.
+
+=item SubnetId (optional)
+
+Specifies the subnet ID within which to launch the instance(s) for Amazon Virtual Private Cloud.
 
 =back
 
@@ -2651,6 +2887,7 @@
 		MaxCount							=> { type => SCALAR },
 		KeyName								=> { type => SCALAR, optional => 1 },
 		SecurityGroup						=> { type => SCALAR | ARRAYREF, optional => 1 },
+		AdditionalInfo						=> { type => SCALAR, optional => 1 },
 		UserData							=> { type => SCALAR, optional => 1 },
 		InstanceType						=> { type => SCALAR, optional => 1 },
 		'Placement.AvailabilityZone'		=> { type => SCALAR, optional => 1 },
@@ -2661,6 +2898,7 @@
 		Encoding							=> { type => SCALAR, optional => 1 },
 		Version								=> { type => SCALAR, optional => 1 },
 		'Monitoring.Enabled'				=> { type => SCALAR, optional => 1 },
+		SubnetId							=> { type => SCALAR, optional => 1 },
 	});
 	
 	# If we have a array ref of instances lets split them out into their SecurityGroup.n format
@@ -2742,6 +2980,8 @@
 				ami_launch_index	=> $instance_elem->{amiLaunchIndex},
 				dns_name			=> $instance_elem->{dnsName},
 				image_id			=> $instance_elem->{imageId},
+				kernel_id			=> $instance_elem->{kernelId},
+				ramdisk_id			=> $instance_elem->{ramdiskId},
 				instance_id			=> $instance_elem->{instanceId},
 				instance_state		=> $instance_state_type,
 				instance_type		=> $instance_elem->{instanceType},
@@ -2752,6 +2992,10 @@
 				reason				=> $instance_elem->{reason},
 				platform			=> $instance_elem->{platform},
 				monitoring			=> $instance_elem->{monitoring}{state},
+				subnet_id			=> $instance_elem->{subnetId},
+				vpc_id				=> $instance_elem->{vpcId},
+				private_ip_address	=> $instance_elem->{privateIpAddress},
+				ip_address			=> $instance_elem->{ipAddress},
 			);
 
 			if ($product_codes) {
@@ -2889,7 +3133,7 @@
 
 Set AWS_ACCESS_KEY_ID and SECRET_ACCESS_KEY environment variables to run the live tests.  
 Note: because the live tests start an instance (and kill it) in both the tests and backwards compat tests there will be 2 hours of 
-machine instance usage charges (since there are 2 instances started) which as of September 23rd, 2009 costs a total of $0.20 USD
+machine instance usage charges (since there are 2 instances started) which as of November 12th, 2009 costs a total of $0.17 USD
 
 Important note about the windows-only methods.  These have not been well tested as I do not run windows-based instances, so exercise
 caution in using these.
@@ -2898,6 +3142,10 @@
 
 Jeff Kim <jkim at chosec.com>
 
+=head1 CONTRIBUTORS
+
+John McCullough
+
 =head1 COPYRIGHT
 
 Copyright (c) 2006-2009 Jeff Kim. This program is free software; you can redistribute it and/or modify it

Modified: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZone.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZone.pm?rev=47100&op=diff
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZone.pm (original)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZone.pm Fri Nov 13 13:44:43 2009
@@ -25,6 +25,10 @@
 
 Name of the region.
 
+=item messages (optional)
+
+An array ref of Net::Amazon::EC2::AvailabilityZoneMessage objects representing messages for this zone (if any)
+
 =back
 
 =cut
@@ -32,6 +36,7 @@
 has 'zone_name'		=> ( is => 'ro', isa => 'Str', required => 1 );
 has 'zone_state'	=> ( is => 'ro', isa => 'Str', required => 1 );
 has 'region_name'	=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'messages'		=> ( is => 'ro', isa => 'Maybe[Net::Amazon::EC2::AvailabilityZone]', required => 0 );
 
 __PACKAGE__->meta->make_immutable();
 

Added: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZoneMessage.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZoneMessage.pm?rev=47100&op=file
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZoneMessage.pm (added)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/AvailabilityZoneMessage.pm Fri Nov 13 13:44:43 2009
@@ -1,0 +1,38 @@
+package Net::Amazon::EC2::AvailabilityZoneMessage;
+use Moose;
+
+=head1 NAME
+
+Net::Amazon::EC2::AvailabilityZoneMessage
+
+=head1 DESCRIPTION
+
+A class containing messaging associated with an availability zone.
+
+=head1 ATTRIBUTES
+
+=over
+
+=item message (required)
+
+The message itself.
+
+=cut
+
+has 'message'  => ( is => 'ro', isa => 'Str', required => 1 );
+
+__PACKAGE__->meta->make_immutable();
+
+=head1 AUTHOR
+
+Jeff Kim <jkim at chosec.com>
+
+=head1 COPYRIGHT
+
+Copyright (c) 2006-2009 Jeff Kim. This program is free software; you can redistribute it and/or modify it
+under the same terms as Perl itself.
+
+=cut
+
+no Moose;
+1;

Modified: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/BundleInstanceResponse.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/BundleInstanceResponse.pm?rev=47100&op=diff
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/BundleInstanceResponse.pm (original)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/BundleInstanceResponse.pm Fri Nov 13 13:44:43 2009
@@ -57,6 +57,14 @@
 
 The signature of the Base64 encoded JSON document.
 
+=item bundle_error_code (optional)
+
+Error code for bundle failure.
+
+=item bundle_error_message (optional)
+
+Error message associated with bundle failure.
+
 =back
 
 =cut
@@ -72,6 +80,8 @@
 has 's3_aws_access_key_id'			=> ( is => 'ro', isa => 'Str', required => 1 );
 has 's3_upload_policy'				=> ( is => 'ro', isa => 'Str', required => 1 );
 has 's3_policy_upload_signature'	=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'bundle_error_code'				=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'bundle_error_message'			=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
 
 __PACKAGE__->meta->make_immutable();
 

Added: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/CreateVolumePermission.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/CreateVolumePermission.pm?rev=47100&op=file
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/CreateVolumePermission.pm (added)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/CreateVolumePermission.pm Fri Nov 13 13:44:43 2009
@@ -1,0 +1,43 @@
+package Net::Amazon::EC2::CreateVolumePermission;
+use Moose;
+
+=head1 NAME
+
+Net::Amazon::EC2::CreateVolumePermission
+
+=head1 DESCRIPTION
+
+A class representing the users or groups allowed to create a volume from the associated snapshot.
+
+=head1 ATTRIBUTES
+
+=over
+
+=item user_id (optional)
+
+User ID of a user that can create volumes from the snapshot.
+
+=item group (optional)
+
+Group that is allowed to create volumes from the snapshot (currently supports "all").
+
+=cut
+
+has 'user_id'       => ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'group'			=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+
+__PACKAGE__->meta->make_immutable();
+
+=head1 AUTHOR
+
+Jeff Kim <jkim at chosec.com>
+
+=head1 COPYRIGHT
+
+Copyright (c) 2006-2009 Jeff Kim. This program is free software; you can redistribute it and/or modify it
+under the same terms as Perl itself.
+
+=cut
+
+no Moose;
+1;

Modified: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/RunningInstances.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/RunningInstances.pm?rev=47100&op=diff
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/RunningInstances.pm (original)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/RunningInstances.pm Fri Nov 13 13:44:43 2009
@@ -28,6 +28,14 @@
 =item image_id (required)
 
 The image id of the AMI currently running in this instance.
+
+=item kernel_id (required)
+
+The kernel id of the AKI currently running in this instance.
+
+=item ramdisk_id (required)
+
+The ramdisk id of the ARI loaded in this instance.
 
 =item instance_id (required)
 
@@ -76,31 +84,54 @@
 
 The state of monitoring on this instance.
 
+=item subnet_id (optional)
+
+Specifies the subnet ID in which the instance is running (Amazon Virtual Private Cloud).
+
+=item vpc_id (optional)
+
+Specifies the VPC in which the instance is running (Amazon Virtual Private Cloud).
+
+=item private_ip_address (optional)
+
+Specifies the private IP address that is assigned to the instance (Amazon VPC).
+
+=item ip_address (optional)
+
+Specifies the IP address of the instance.
+
 =cut
 
-has 'ami_launch_index'  => ( is => 'ro', isa => 'Str', required => 0 );
-has 'dns_name'          => ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
-has 'image_id'          => ( is => 'ro', isa => 'Str', required => 1 );
-has 'instance_id'       => ( is => 'ro', isa => 'Str', required => 1 );
-has 'instance_state'    => ( 
+has 'ami_launch_index'  	=> ( is => 'ro', isa => 'Str', required => 0 );
+has 'dns_name'          	=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'image_id'          	=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'kernel_id'         	=> ( is => 'ro', isa => 'Maybe[Str]', required => 1 );
+has 'ramdisk_id'        	=> ( is => 'ro', isa => 'Maybe[Str]', required => 1 );
+has 'instance_id'       	=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'instance_state'    	=> ( 
     is => 'ro', 
     isa => 'Net::Amazon::EC2::InstanceState', 
     required => 1
 );
-has 'instance_type'     => ( is => 'ro', isa => 'Str', required => 1 );
-has 'key_name'          => ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
-has 'launch_time'       => ( is => 'ro', isa => 'Str', required => 1 );
-has 'placement'			=> ( is => 'ro', isa => 'Net::Amazon::EC2::PlacementResponse', required => 1 );
-has 'private_dns_name'  => ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
-has 'product_codes'     => ( 
+has 'instance_type'     	=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'key_name'          	=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'launch_time'       	=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'placement'				=> ( is => 'ro', isa => 'Net::Amazon::EC2::PlacementResponse', required => 1 );
+has 'private_dns_name'  	=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'product_codes'     	=> ( 
     is          => 'rw', 
     isa         => 'ArrayRef[Net::Amazon::EC2::ProductCode]',
     auto_deref  => 1,
     required	=> 0,
 );
-has 'reason'            => ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
-has 'platform'			=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
-has 'monitoring'		=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'reason'            	=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'platform'				=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'monitoring'			=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'subnet_id'				=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'vpc_id'				=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'private_ip_address'	=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'ip_address'			=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+
 
 __PACKAGE__->meta->make_immutable();
 
@@ -116,4 +147,4 @@
 =cut
 
 no Moose;
-1;
+1;

Modified: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/Snapshot.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/Snapshot.pm?rev=47100&op=diff
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/Snapshot.pm (original)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/Snapshot.pm Fri Nov 13 13:44:43 2009
@@ -29,9 +29,21 @@
 
 The time the snapshot was started.
 
-=item progress (required)
+=item progress (optional)
 
-The current progress of the snaptop, in percent.
+The current progress of the snapshop, in percent.
+
+=item owner_id (required)
+
+AWS Access Key ID of the user who owns the snapshot.
+
+=item volume_size (optional)
+
+The size of the volume, in GiB.
+
+=item description (optional)
+
+Description of the snapshot.
 
 =back
 
@@ -42,6 +54,9 @@
 has 'volume_id'		=> ( is => 'ro', isa => 'Str', required => 1 );
 has 'start_time'	=> ( is => 'ro', isa => 'Str', required => 1 );
 has 'progress'		=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'owner_id'		=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'volume_size'	=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
+has 'description'	=> ( is => 'ro', isa => 'Maybe[Str]', required => 0 );
 
 __PACKAGE__->meta->make_immutable();
 

Added: branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/SnapshotAttribute.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/SnapshotAttribute.pm?rev=47100&op=file
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/SnapshotAttribute.pm (added)
+++ branches/upstream/libnet-amazon-ec2-perl/current/lib/Net/Amazon/EC2/SnapshotAttribute.pm Fri Nov 13 13:44:43 2009
@@ -1,0 +1,45 @@
+package Net::Amazon::EC2::SnapshotAttribute;
+use Moose;
+
+=head1 NAME
+
+Net::Amazon::EC2::SnapshotAttribute
+
+=head1 DESCRIPTION
+
+A class representing the snapshot attributes of a volume.
+
+=head1 ATTRIBUTES
+
+=over
+
+=item snapshot_id (required)
+
+The ID of the snapshot.
+
+=item permissions (required)
+
+An arrayref of Net::Amazon::EC2::CreateVolumePermission objects
+
+=back
+
+=cut
+
+has 'snapshot_id'	=> ( is => 'ro', isa => 'Str', required => 1 );
+has 'permissions'	=> ( is => 'ro', isa => 'Maybe[ArrayRef[Net::Amazon::EC2::CreateVolumePermission]]', required => 0 );
+
+__PACKAGE__->meta->make_immutable();
+
+=head1 AUTHOR
+
+Jeff Kim <jkim at chosec.com>
+
+=head1 COPYRIGHT
+
+Copyright (c) 2006-2009 Jeff Kim. This program is free software; you can redistribute it and/or modify it
+under the same terms as Perl itself.
+
+=cut
+
+no Moose;
+1;

Modified: branches/upstream/libnet-amazon-ec2-perl/current/t/00_use.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libnet-amazon-ec2-perl/current/t/00_use.t?rev=47100&op=diff
==============================================================================
--- branches/upstream/libnet-amazon-ec2-perl/current/t/00_use.t (original)
+++ branches/upstream/libnet-amazon-ec2-perl/current/t/00_use.t Fri Nov 13 13:44:43 2009
@@ -39,6 +39,9 @@
 		Net::Amazon::EC2::ReservedInstanceOffering
 		Net::Amazon::EC2::MonitoredInstance
 		Net::Amazon::EC2::InstancePassword
+		Net::Amazon::EC2::SnapshotAttribute
+		Net::Amazon::EC2::CreateVolumePermission
+		Net::Amazon::EC2::AvailabilityZoneMessage
 	);
 
 	plan tests => scalar @modules;




More information about the Pkg-perl-cvs-commits mailing list