Skip to content

Commit b877e67

Browse files
committed
Removed customization in ec2.customizations.json which excluded DryRun property from service request model and marked AmazonEC2Client.DryRun() extension method as obsolete.
1 parent 8fbb1c9 commit b877e67

File tree

1,234 files changed

+15389
-11
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,234 files changed

+15389
-11
lines changed

docgenerator/AWSSDKDocSamples/EC2/EC2.GeneratedSamples.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2495,6 +2495,7 @@ public void EC2ModifyVolumeAttribute()
24952495
var response = client.ModifyVolumeAttribute(new ModifyVolumeAttributeRequest
24962496
{
24972497
AutoEnableIO = jsondata object,
2498+
DryRun = true,
24982499
VolumeId = "vol-1234567890abcdef0"
24992500
});
25002501

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"services": [
3+
{
4+
"serviceName": "EC2",
5+
"type": "patch",
6+
"changeLogMessages": [
7+
"[Breaking Change] Removed DryRun method from service client. To perform a dry run use the DryRun property on the request object for individual EC2 operations."
8+
]
9+
}
10+
]
11+
}

generator/ServiceModels/ec2/ec2.customizations.json

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -126,11 +126,6 @@
126126
}
127127
},
128128
"shapeModifiers": {
129-
"*": {
130-
"exclude": [
131-
"DryRun"
132-
]
133-
},
134129
"AttachVolumeResponse": {
135130
"modify": [
136131
{

sdk/src/Services/EC2/Custom/AmazonEC2Client.Extensions.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ private static Dictionary<Type, DryRunInfo> MethodCache
149149
/// </summary>
150150
/// <param name="request">Request to do a dry run of.</param>
151151
/// <returns>Result of the dry run.</returns>
152+
[Obsolete("This method has been deprecated. Use DryRun property at request level instead.")]
152153
public DryRunResponse DryRun(AmazonEC2Request request)
153154
{
154155
DryRunResponse response = new DryRunResponse { IsSuccessful = false };

sdk/src/Services/EC2/Custom/IAmazonEC2.Extensions.cs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,12 @@ namespace Amazon.EC2
2020
{
2121
public partial interface IAmazonEC2 : IAmazonService, IDisposable
2222
{
23-
/// <summary>
24-
/// Checks whether you have the required permissions for the action, without actually making the request.
25-
/// </summary>
26-
/// <param name="request">Request to do a dry run of.</param>
27-
/// <returns>Result of the dry run.</returns>
28-
DryRunResponse DryRun(AmazonEC2Request request);
23+
/// <summary>
24+
/// Checks whether you have the required permissions for the action, without actually making the request.
25+
/// </summary>
26+
/// <param name="request">Request to do a dry run of.</param>
27+
/// <returns>Result of the dry run.</returns>
28+
[Obsolete("This method has been deprecated. Use DryRun property at request level instead.")]
29+
DryRunResponse DryRun(AmazonEC2Request request);
2930
}
3031
}

sdk/src/Services/EC2/Generated/Model/AcceptAddressTransferRequest.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ namespace Amazon.EC2.Model
3737
public partial class AcceptAddressTransferRequest : AmazonEC2Request
3838
{
3939
private string _address;
40+
private bool? _dryRun;
4041
private List<TagSpecification> _tagSpecifications = AWSConfigs.InitializeCollections ? new List<TagSpecification>() : null;
4142

4243
/// <summary>
@@ -58,6 +59,26 @@ internal bool IsSetAddress()
5859
return this._address != null;
5960
}
6061

62+
/// <summary>
63+
/// Gets and sets the property DryRun.
64+
/// <para>
65+
/// Checks whether you have the required permissions for the action, without actually
66+
/// making the request, and provides an error response. If you have the required permissions,
67+
/// the error response is <c>DryRunOperation</c>. Otherwise, it is <c>UnauthorizedOperation</c>.
68+
/// </para>
69+
/// </summary>
70+
public bool? DryRun
71+
{
72+
get { return this._dryRun; }
73+
set { this._dryRun = value; }
74+
}
75+
76+
// Check to see if DryRun property is set
77+
internal bool IsSetDryRun()
78+
{
79+
return this._dryRun.HasValue;
80+
}
81+
6182
/// <summary>
6283
/// Gets and sets the property TagSpecifications.
6384
/// <para>

sdk/src/Services/EC2/Generated/Model/AcceptCapacityReservationBillingOwnershipRequest.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ namespace Amazon.EC2.Model
3838
public partial class AcceptCapacityReservationBillingOwnershipRequest : AmazonEC2Request
3939
{
4040
private string _capacityReservationId;
41+
private bool? _dryRun;
4142

4243
/// <summary>
4344
/// Gets and sets the property CapacityReservationId.
@@ -58,5 +59,25 @@ internal bool IsSetCapacityReservationId()
5859
return this._capacityReservationId != null;
5960
}
6061

62+
/// <summary>
63+
/// Gets and sets the property DryRun.
64+
/// <para>
65+
/// Checks whether you have the required permissions for the action, without actually
66+
/// making the request, and provides an error response. If you have the required permissions,
67+
/// the error response is <c>DryRunOperation</c>. Otherwise, it is <c>UnauthorizedOperation</c>.
68+
/// </para>
69+
/// </summary>
70+
public bool? DryRun
71+
{
72+
get { return this._dryRun; }
73+
set { this._dryRun = value; }
74+
}
75+
76+
// Check to see if DryRun property is set
77+
internal bool IsSetDryRun()
78+
{
79+
return this._dryRun.HasValue;
80+
}
81+
6182
}
6283
}

sdk/src/Services/EC2/Generated/Model/AcceptReservedInstancesExchangeQuoteRequest.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,30 @@ namespace Amazon.EC2.Model
3636
/// </summary>
3737
public partial class AcceptReservedInstancesExchangeQuoteRequest : AmazonEC2Request
3838
{
39+
private bool? _dryRun;
3940
private List<string> _reservedInstanceIds = AWSConfigs.InitializeCollections ? new List<string>() : null;
4041
private List<TargetConfigurationRequest> _targetConfigurations = AWSConfigs.InitializeCollections ? new List<TargetConfigurationRequest>() : null;
4142

43+
/// <summary>
44+
/// Gets and sets the property DryRun.
45+
/// <para>
46+
/// Checks whether you have the required permissions for the action, without actually
47+
/// making the request, and provides an error response. If you have the required permissions,
48+
/// the error response is <c>DryRunOperation</c>. Otherwise, it is <c>UnauthorizedOperation</c>.
49+
/// </para>
50+
/// </summary>
51+
public bool? DryRun
52+
{
53+
get { return this._dryRun; }
54+
set { this._dryRun = value; }
55+
}
56+
57+
// Check to see if DryRun property is set
58+
internal bool IsSetDryRun()
59+
{
60+
return this._dryRun.HasValue;
61+
}
62+
4263
/// <summary>
4364
/// Gets and sets the property ReservedInstanceIds.
4465
/// <para>

sdk/src/Services/EC2/Generated/Model/AcceptTransitGatewayMulticastDomainAssociationsRequest.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,31 @@ namespace Amazon.EC2.Model
3535
/// </summary>
3636
public partial class AcceptTransitGatewayMulticastDomainAssociationsRequest : AmazonEC2Request
3737
{
38+
private bool? _dryRun;
3839
private List<string> _subnetIds = AWSConfigs.InitializeCollections ? new List<string>() : null;
3940
private string _transitGatewayAttachmentId;
4041
private string _transitGatewayMulticastDomainId;
4142

43+
/// <summary>
44+
/// Gets and sets the property DryRun.
45+
/// <para>
46+
/// Checks whether you have the required permissions for the action, without actually
47+
/// making the request, and provides an error response. If you have the required permissions,
48+
/// the error response is <c>DryRunOperation</c>. Otherwise, it is <c>UnauthorizedOperation</c>.
49+
/// </para>
50+
/// </summary>
51+
public bool? DryRun
52+
{
53+
get { return this._dryRun; }
54+
set { this._dryRun = value; }
55+
}
56+
57+
// Check to see if DryRun property is set
58+
internal bool IsSetDryRun()
59+
{
60+
return this._dryRun.HasValue;
61+
}
62+
4263
/// <summary>
4364
/// Gets and sets the property SubnetIds.
4465
/// <para>

sdk/src/Services/EC2/Generated/Model/AcceptTransitGatewayPeeringAttachmentRequest.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,29 @@ namespace Amazon.EC2.Model
3636
/// </summary>
3737
public partial class AcceptTransitGatewayPeeringAttachmentRequest : AmazonEC2Request
3838
{
39+
private bool? _dryRun;
3940
private string _transitGatewayAttachmentId;
4041

42+
/// <summary>
43+
/// Gets and sets the property DryRun.
44+
/// <para>
45+
/// Checks whether you have the required permissions for the action, without actually
46+
/// making the request, and provides an error response. If you have the required permissions,
47+
/// the error response is <c>DryRunOperation</c>. Otherwise, it is <c>UnauthorizedOperation</c>.
48+
/// </para>
49+
/// </summary>
50+
public bool? DryRun
51+
{
52+
get { return this._dryRun; }
53+
set { this._dryRun = value; }
54+
}
55+
56+
// Check to see if DryRun property is set
57+
internal bool IsSetDryRun()
58+
{
59+
return this._dryRun.HasValue;
60+
}
61+
4162
/// <summary>
4263
/// Gets and sets the property TransitGatewayAttachmentId.
4364
/// <para>

0 commit comments

Comments
 (0)