-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(batch-alpha): add RuntimePlatform prop #26506
feat(batch-alpha): add RuntimePlatform prop #26506
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.
A comment requesting an exemption should contain the text Exemption Request
. Additionally, if clarification is needed add Clarification Request
to a comment.
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
if (props.runtimePlatform) { | ||
this.runtimePlatform = props.runtimePlatform; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you should modify the _renderContainerDefinition() function to add the new runtimePlatform
property like
runtimePlatform: this.runtimePlatform
So it will synth a new container definition for ContainerProperties
OK looks like the RuntimePlatform support was just added into cloudformation in Aug 2023 AWS CDK at this moment uses CFN spec aws-cdk/packages/@aws-cdk/cfnspec/spec-source/specification/000_cfn/000_official/000_AWS_Batch.json Line 2 in ed9b537
cfnspec 130.1.0 was PR merged on July 14 The latest CFN spec is 135.0.0 which DOES have We will need to wait another PR from the core team to support 135.0.0 or above before we are allowed to continue this PR. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
6 similar comments
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
I was wrong. CDK now uses awscdk-service-spec as the source of the truth for the L1 and the latest definition can be found here: And I can confirm
|
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
This PR has been in the CHANGES REQUESTED state for 3 weeks, and looks abandoned. To keep this PR from being closed, please continue work on it. If not, it will automatically be closed in a week. |
* | ||
* A runtimePlatform is supported only for tasks using the Fargate launch type. | ||
* | ||
* @default - Undefined. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't write "undefined". We all know that the JavaScript value of a missing variable is undefined
.
Describe what the behavior is if the value is left undefined
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this property need to be on the interface? IEcsContainerDefinition
?
It only needs to be here if downstream consumers of this class need to make decisions based on runtimePlatform
. If so, it also needs to be added to EcsContainerDefinition.fromContainerDefinitionAttributes()
.
* | ||
* A runtimePlatform is supported only for tasks using the Fargate launch type. | ||
* | ||
* @default - Undefined. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same.
@@ -643,6 +667,10 @@ abstract class EcsContainerDefinitionBase extends Construct implements IEcsConta | |||
logConfiguration: this.logDriverConfig, | |||
readonlyRootFilesystem: this.readonlyRootFilesystem, | |||
resourceRequirements: this._renderResourceRequirements(), | |||
runtimePlatform: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please make it so the entire subobject is not rendered if this.runtimePlatform
is undefined
, otherwise this will lead to unnecessary changes to existing templates.
* | ||
* @default - Undefined. | ||
*/ | ||
readonly runtimePlatform?: RuntimePlatform; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of having this subproperty, how about we inline the 2 fields from RuntimePlatform
here? It will be easier to work with for users.
Prefer flat properties, CDK Design Guidelines, section Props.
Also this is not a |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
1 similar comment
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
Hello @pahud, Sorry I can not help you on this one, I don't have the skills to contribute. But the need is always here. |
@comcalvi FYI |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
3 similar comments
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR has been deemed to be abandoned, and will be automatically closed. Please create a new PR for these changes if you think this decision has been made in error. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.
A comment requesting an exemption should contain the text Exemption Request
. Additionally, if clarification is needed add Clarification Request
to a comment.
The pull request linter fails with the following errors:
PRs must pass status checks before we can provide a meaningful review. If you would like to request an exemption from the status checks or clarification on feedback, please leave a comment on this PR containing |
This PR has been deemed to be abandoned, and will be automatically closed. Please create a new PR for these changes if you think this decision has been made in error. |
Closes #26484.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license