Skip to content

Commit 545490a

Browse files
Add support to roll back an In_Progress ECS Service Deployment
1 parent 5cadc46 commit 545490a

14 files changed

+270
-5585
lines changed

generator/ServiceModels/ecs/ecs-2014-11-13.docs.json

Lines changed: 7 additions & 7 deletions
Large diffs are not rendered by default.

generator/ServiceModels/ecs/ecs-2014-11-13.normal.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -731,7 +731,7 @@
731731
{"shape":"BlockedException"},
732732
{"shape":"ConflictException"}
733733
],
734-
"documentation":"<p>Starts a new task using the specified task definition.</p> <note> <p>On March 21, 2024, a change was made to resolve the task definition revision before authorization. When a task definition revision is not specified, authorization will occur using the latest revision of a task definition.</p> </note> <note> <p>Amazon Elastic Inference (EI) is no longer available to customers.</p> </note> <p>You can allow Amazon ECS to place tasks for you, or you can customize how Amazon ECS places tasks using placement constraints and placement strategies. For more information, see <a href=\"https://docs.aws.amazon.com/AmazonECS/latest/developerguide/scheduling_tasks.html\">Scheduling Tasks</a> in the <i>Amazon Elastic Container Service Developer Guide</i>.</p> <p>Alternatively, you can use <code>StartTask</code> to use your own scheduler or place tasks manually on specific container instances.</p> <p>You can attach Amazon EBS volumes to Amazon ECS tasks by configuring the volume when creating or updating a service. For more infomation, see <a href=\"https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ebs-volumes.html#ebs-volume-types\">Amazon EBS volumes</a> in the <i>Amazon Elastic Container Service Developer Guide</i>.</p> <p>The Amazon ECS API follows an eventual consistency model. This is because of the distributed nature of the system supporting the API. This means that the result of an API command you run that affects your Amazon ECS resources might not be immediately visible to all subsequent commands you run. Keep this in mind when you carry out an API command that immediately follows a previous API command.</p> <p>To manage eventual consistency, you can do the following:</p> <ul> <li> <p>Confirm the state of the resource before you run a command to modify it. Run the DescribeTasks command using an exponential backoff algorithm to ensure that you allow enough time for the previous command to propagate through the system. To do this, run the DescribeTasks command repeatedly, starting with a couple of seconds of wait time and increasing gradually up to five minutes of wait time.</p> </li> <li> <p>Add wait time between subsequent commands, even if the DescribeTasks command returns an accurate response. Apply an exponential backoff algorithm starting with a couple of seconds of wait time, and increase gradually up to about five minutes of wait time.</p> </li> </ul> <p>If you get a <code>ConflictException</code> error, the <code>RunTask</code> request could not be processed due to conflicts. The provided <code>clientToken</code> is already in use with a different <code>RunTask</code> request. The <code>resourceIds</code> are the existing task ARNs which are already associated with the <code>clientToken</code>. </p> <p>To fix this issue:</p> <ul> <li> <p>Run <code>RunTask</code> with a unique <code>clientToken</code>.</p> </li> <li> <p>Run <code>RunTask</code> with the <code>clientToken</code> and the original set of parameters</p> </li> </ul>"
734+
"documentation":"<p>Starts a new task using the specified task definition.</p> <note> <p>On March 21, 2024, a change was made to resolve the task definition revision before authorization. When a task definition revision is not specified, authorization will occur using the latest revision of a task definition.</p> </note> <note> <p>Amazon Elastic Inference (EI) is no longer available to customers.</p> </note> <p>You can allow Amazon ECS to place tasks for you, or you can customize how Amazon ECS places tasks using placement constraints and placement strategies. For more information, see <a href=\"https://docs.aws.amazon.com/AmazonECS/latest/developerguide/scheduling_tasks.html\">Scheduling Tasks</a> in the <i>Amazon Elastic Container Service Developer Guide</i>.</p> <p>Alternatively, you can use <code>StartTask</code> to use your own scheduler or place tasks manually on specific container instances.</p> <p>You can attach Amazon EBS volumes to Amazon ECS tasks by configuring the volume when creating or updating a service. For more infomation, see <a href=\"https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ebs-volumes.html#ebs-volume-types\">Amazon EBS volumes</a> in the <i>Amazon Elastic Container Service Developer Guide</i>.</p> <p>The Amazon ECS API follows an eventual consistency model. This is because of the distributed nature of the system supporting the API. This means that the result of an API command you run that affects your Amazon ECS resources might not be immediately visible to all subsequent commands you run. Keep this in mind when you carry out an API command that immediately follows a previous API command.</p> <p>To manage eventual consistency, you can do the following:</p> <ul> <li> <p>Confirm the state of the resource before you run a command to modify it. Run the DescribeTasks command using an exponential backoff algorithm to ensure that you allow enough time for the previous command to propagate through the system. To do this, run the DescribeTasks command repeatedly, starting with a couple of seconds of wait time and increasing gradually up to five minutes of wait time.</p> </li> <li> <p>Add wait time between subsequent commands, even if the DescribeTasks command returns an accurate response. Apply an exponential backoff algorithm starting with a couple of seconds of wait time, and increase gradually up to about five minutes of wait time.</p> </li> </ul> <p>If you get a <code>ConflictException</code> error, the <code>RunTask</code> request could not be processed due to conflicts. The provided <code>clientToken</code> is already in use with a different <code>RunTask</code> request. The <code>resourceIds</code> are the existing task ARNs which are already associated with the <code>clientToken</code>. </p> <p>To fix this issue:</p> <ul> <li> <p>Run <code>RunTask</code> with a unique <code>clientToken</code>.</p> </li> <li> <p>Run <code>RunTask</code> with the <code>clientToken</code> and the original set of parameters</p> </li> </ul> <p>If you get a <code>ClientException</code>error, the <code>RunTask</code> could not be processed because you use managed scaling and there is a capacity error because the quota of tasks in the <code>PROVISIONING</code> per cluster has been reached. For information about the service quotas, see <a href=\"https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-quotas.html\">Amazon ECS service quotas</a>.</p>"
735735
},
736736
"StartTask":{
737737
"name":"StartTask",
@@ -767,7 +767,7 @@
767767
{"shape":"ServiceDeploymentNotFoundException"},
768768
{"shape":"UnsupportedFeatureException"}
769769
],
770-
"documentation":"<p>Stops an ongoing service deployment.</p> <note> <p>StopServiceDeployment isn't currently supported.</p> </note>"
770+
"documentation":"<p>Stops an ongoing service deployment.</p> <p>The following stop types are avaiable:</p> <ul> <li> <p>ROLLBACK - This option rolls back the service deployment to the previous service revision. </p> <p>You can use this option even if you didn't configure the service deployment for the rollback option. </p> </li> </ul> <p>For more information, see <a href=\"https://docs.aws.amazon.com/AmazonECS/latest/developerguide/stop-service-deployment.html\">Stopping Amazon ECS service deployments</a> in the <i>Amazon Elastic Container Service Developer Guide</i>.</p>"
771771
},
772772
"StopTask":{
773773
"name":"StopTask",
@@ -1346,7 +1346,7 @@
13461346
"documentation":"<p> Message that describes the cause of the exception.</p>"
13471347
}
13481348
},
1349-
"documentation":"<p>These errors are usually caused by a client action. This client action might be using an action or resource on behalf of a user that doesn't have permissions to use the action or resource. Or, it might be specifying an identifier that isn't valid.</p> <p>The following list includes additional causes for the error:</p> <ul> <li> <p>The <code>RunTask</code> could not be processed because you use managed scaling and there is a capacity error because the quota of tasks in the <code>PROVISIONING</code> per cluster has been reached. For information about the service quotas, see <a href=\"https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-quotas.html\">Amazon ECS service quotas</a>.</p> </li> </ul>",
1349+
"documentation":"<p>These errors are usually caused by a client action. This client action might be using an action or resource on behalf of a user that doesn't have permissions to use the action or resource. Or, it might be specifying an identifier that isn't valid.</p>",
13501350
"exception":true
13511351
},
13521352
"Cluster":{
@@ -2359,7 +2359,7 @@
23592359
},
23602360
"principalArn":{
23612361
"shape":"String",
2362-
"documentation":"<p>The Amazon Resource Name (ARN) of the principal. It can be an user, role, or the root user. If you specify the root user, it disables the account setting for all users, roles, and the root user of the account unless a user or role explicitly overrides these settings. If this field is omitted, the setting is changed only for the authenticated user.</p>"
2362+
"documentation":"<p>The Amazon Resource Name (ARN) of the principal. It can be a user, role, or the root user. If you specify the root user, it disables the account setting for all users, roles, and the root user of the account unless a user or role explicitly overrides these settings. If this field is omitted, the setting is changed only for the authenticated user.</p> <p>In order to use this parameter, you must be the root user, or the principal.</p>"
23632363
}
23642364
}
23652365
},
@@ -3750,7 +3750,7 @@
37503750
},
37513751
"principalArn":{
37523752
"shape":"String",
3753-
"documentation":"<p>The ARN of the principal, which can be a user, role, or the root user. If this field is omitted, the account settings are listed only for the authenticated user.</p> <note> <p>Federated users assume the account setting of the root user and can't have explicit account settings set for them.</p> </note>"
3753+
"documentation":"<p>The ARN of the principal, which can be a user, role, or the root user. If this field is omitted, the account settings are listed only for the authenticated user.</p> <p>In order to use this parameter, you must be the root user, or the principal.</p> <note> <p>Federated users assume the account setting of the root user and can't have explicit account settings set for them.</p> </note>"
37543754
},
37553755
"effectiveSettings":{
37563756
"shape":"Boolean",
@@ -4708,7 +4708,7 @@
47084708
},
47094709
"principalArn":{
47104710
"shape":"String",
4711-
"documentation":"<p>The ARN of the principal, which can be a user, role, or the root user. If you specify the root user, it modifies the account setting for all users, roles, and the root user of the account unless a user or role explicitly overrides these settings. If this field is omitted, the setting is changed only for the authenticated user.</p> <note> <p>You must use the root user when you set the Fargate wait time (<code>fargateTaskRetirementWaitPeriod</code>). </p> <p>Federated users assume the account setting of the root user and can't have explicit account settings set for them.</p> </note>"
4711+
"documentation":"<p>The ARN of the principal, which can be a user, role, or the root user. If you specify the root user, it modifies the account setting for all users, roles, and the root user of the account unless a user or role explicitly overrides these settings. If this field is omitted, the setting is changed only for the authenticated user.</p> <p>In order to use this parameter, you must be the root user, or the principal.</p> <note> <p>You must use the root user when you set the Fargate wait time (<code>fargateTaskRetirementWaitPeriod</code>). </p> <p>Federated users assume the account setting of the root user and can't have explicit account settings set for them.</p> </note>"
47124712
}
47134713
}
47144714
},
@@ -6057,7 +6057,7 @@
60576057
},
60586058
"stopType":{
60596059
"shape":"StopServiceDeploymentStopType",
6060-
"documentation":"<p>How you want Amazon ECS to stop the service. </p> <p>The ROLLBACK and ABORT stopType aren't supported.</p>"
6060+
"documentation":"<p>How you want Amazon ECS to stop the service. </p> <p>The valid values are <code>ROLLBACK</code>.</p>"
60616061
}
60626062
}
60636063
},

sdk/src/Services/ECS/Generated/Model/ClientException.cs

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,6 @@ namespace Amazon.ECS.Model
3333
/// These errors are usually caused by a client action. This client action might be using
3434
/// an action or resource on behalf of a user that doesn't have permissions to use the
3535
/// action or resource. Or, it might be specifying an identifier that isn't valid.
36-
///
37-
///
38-
/// <para>
39-
/// The following list includes additional causes for the error:
40-
/// </para>
41-
/// <ul> <li>
42-
/// <para>
43-
/// The <c>RunTask</c> could not be processed because you use managed scaling and there
44-
/// is a capacity error because the quota of tasks in the <c>PROVISIONING</c> per cluster
45-
/// has been reached. For information about the service quotas, see <a href="https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-quotas.html">Amazon
46-
/// ECS service quotas</a>.
47-
/// </para>
48-
/// </li> </ul>
4936
/// </summary>
5037
#if !NETSTANDARD
5138
[Serializable]

sdk/src/Services/ECS/Generated/Model/DeleteAccountSettingRequest.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,12 +65,16 @@ internal bool IsSetName()
6565
/// <summary>
6666
/// Gets and sets the property PrincipalArn.
6767
/// <para>
68-
/// The Amazon Resource Name (ARN) of the principal. It can be an user, role, or the root
68+
/// The Amazon Resource Name (ARN) of the principal. It can be a user, role, or the root
6969
/// user. If you specify the root user, it disables the account setting for all users,
7070
/// roles, and the root user of the account unless a user or role explicitly overrides
7171
/// these settings. If this field is omitted, the setting is changed only for the authenticated
7272
/// user.
7373
/// </para>
74+
///
75+
/// <para>
76+
/// In order to use this parameter, you must be the root user, or the principal.
77+
/// </para>
7478
/// </summary>
7579
public string PrincipalArn
7680
{

sdk/src/Services/ECS/Generated/Model/ListAccountSettingsRequest.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,10 @@ internal bool IsSetNextToken()
138138
/// The ARN of the principal, which can be a user, role, or the root user. If this field
139139
/// is omitted, the account settings are listed only for the authenticated user.
140140
/// </para>
141+
///
142+
/// <para>
143+
/// In order to use this parameter, you must be the root user, or the principal.
144+
/// </para>
141145
/// <note>
142146
/// <para>
143147
/// Federated users assume the account setting of the root user and can't have explicit

sdk/src/Services/ECS/Generated/Model/PutAccountSettingRequest.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,10 @@ internal bool IsSetName()
189189
/// user of the account unless a user or role explicitly overrides these settings. If
190190
/// this field is omitted, the setting is changed only for the authenticated user.
191191
/// </para>
192+
///
193+
/// <para>
194+
/// In order to use this parameter, you must be the root user, or the principal.
195+
/// </para>
192196
/// <note>
193197
/// <para>
194198
/// You must use the root user when you set the Fargate wait time (<c>fargateTaskRetirementWaitPeriod</c>).

sdk/src/Services/ECS/Generated/Model/RunTaskRequest.cs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,14 @@ namespace Amazon.ECS.Model
106106
/// <para>
107107
/// Run <c>RunTask</c> with the <c>clientToken</c> and the original set of parameters
108108
/// </para>
109-
/// </li> </ul>
109+
/// </li> </ul>
110+
/// <para>
111+
/// If you get a <c>ClientException</c>error, the <c>RunTask</c> could not be processed
112+
/// because you use managed scaling and there is a capacity error because the quota of
113+
/// tasks in the <c>PROVISIONING</c> per cluster has been reached. For information about
114+
/// the service quotas, see <a href="https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-quotas.html">Amazon
115+
/// ECS service quotas</a>.
116+
/// </para>
110117
/// </summary>
111118
public partial class RunTaskRequest : AmazonECSRequest
112119
{

sdk/src/Services/ECS/Generated/Model/StopServiceDeploymentRequest.cs

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,26 @@ namespace Amazon.ECS.Model
3333
/// Container for the parameters to the StopServiceDeployment operation.
3434
/// Stops an ongoing service deployment.
3535
///
36-
/// <note>
36+
///
3737
/// <para>
38-
/// StopServiceDeployment isn't currently supported.
38+
/// The following stop types are avaiable:
39+
/// </para>
40+
/// <ul> <li>
41+
/// <para>
42+
/// ROLLBACK - This option rolls back the service deployment to the previous service revision.
43+
///
44+
/// </para>
45+
///
46+
/// <para>
47+
/// You can use this option even if you didn't configure the service deployment for the
48+
/// rollback option.
49+
/// </para>
50+
/// </li> </ul>
51+
/// <para>
52+
/// For more information, see <a href="https://docs.aws.amazon.com/AmazonECS/latest/developerguide/stop-service-deployment.html">Stopping
53+
/// Amazon ECS service deployments</a> in the <i>Amazon Elastic Container Service Developer
54+
/// Guide</i>.
3955
/// </para>
40-
/// </note>
4156
/// </summary>
4257
public partial class StopServiceDeploymentRequest : AmazonECSRequest
4358
{
@@ -70,7 +85,7 @@ internal bool IsSetServiceDeploymentArn()
7085
/// </para>
7186
///
7287
/// <para>
73-
/// The ROLLBACK and ABORT stopType aren't supported.
88+
/// The valid values are <c>ROLLBACK</c>.
7489
/// </para>
7590
/// </summary>
7691
public StopServiceDeploymentStopType StopType

0 commit comments

Comments
 (0)