Issue 1085:deprecate getRegion from EC2 domain objects

This commit is contained in:
Adrian Cole 2012-09-16 12:55:48 -07:00
parent fae9ec1228
commit 6f5ebf3e90
14 changed files with 75 additions and 19 deletions

View File

@ -114,8 +114,12 @@ public class Attachment implements Comparable<Attachment> {
}
/**
* Snapshots are tied to Regions and can only be used for volumes within the same Region.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -209,9 +209,12 @@ public class BundleTask implements Comparable<BundleTask> {
}
/**
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* @return region of the bundle task
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -219,9 +219,12 @@ public class Image implements Comparable<Image> {
}
/**
* AMIs are tied to the Region where its files are located within Amazon S3.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -47,8 +47,12 @@ public class InstanceStateChange implements Comparable<InstanceStateChange> {
}
/**
* Instances are tied to Availability Zones. However, the instance ID is tied to the Region.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -103,8 +103,12 @@ public class KeyPair implements Comparable<KeyPair> {
}
/**
* Key pairs (to connect to instances) are Region-specific.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -42,8 +42,12 @@ public class PublicIpInstanceIdPair implements Comparable<PublicIpInstanceIdPair
}
/**
* Elastic IP addresses are tied to a Region and cannot be mapped across Regions.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -156,8 +156,12 @@ public class Reservation<T extends RunningInstance> extends ForwardingSet<T> imp
}
/**
* Instances are tied to Availability Zones. However, the instance ID is tied to the Region.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -46,10 +46,17 @@ public class ReservedInstancesOffering implements Comparable<ReservedInstancesOf
this.usagePrice = usagePrice;
}
/**
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}
/**
* @return The Availability Zone in which the Reserved Instance can be used.
*/

View File

@ -290,8 +290,12 @@ public class RunningInstance implements Comparable<RunningInstance> {
}
/**
* Instance Ids are scoped to the region.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -49,13 +49,14 @@ public class SecurityGroup implements Comparable<SecurityGroup> {
this.description = description;
this.ipPermissions = ipPermissions;
}
/**
* Security groups are not copied across Regions. Instances within the Region
* cannot communicate with instances outside the Region using group-based
* firewall rules. Traffic from instances in another Region is seen as WAN
* bandwidth.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -75,12 +75,16 @@ public class Snapshot implements Comparable<Snapshot> {
}
/**
* Snapshots are tied to Regions and can only be used for volumes within the same Region.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}
/**
* The ID of the snapshot.
*/

View File

@ -172,9 +172,12 @@ public class Volume implements Comparable<Volume> {
}
/**
* An Amazon EBS volume must be located within the same Availability Zone as the instance to
* which it attaches.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -77,8 +77,12 @@ public class PlacementGroup implements Comparable<PlacementGroup> {
}
/**
* @return placement groups are in a region, however the namescope is global.
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}

View File

@ -92,6 +92,13 @@ public class Spot implements Comparable<Spot> {
this.timestamp = checkNotNull(timestamp, "timestamp");
}
/**
* To be removed in jclouds 1.6 <h4>Warning</h4>
*
* Especially on EC2 clones that may not support regions, this value is fragile. Consider
* alternate means to determine context.
*/
@Deprecated
public String getRegion() {
return region;
}