Open noseworthy opened 2 weeks ago
Hi @noseworthy , thanks for reaching out. L3 Constructs like aws-ecs-patterns are very much opinionated and usecase based. On checking CDK Docs, FargateTaskDefinition has Pidmode property - https://github.com/aws/aws-cdk/blob/aedf617a754fff87d3cde7efbb996bec6f0fa129/packages/aws-cdk-lib/aws-ecs/lib/fargate/fargate-task-definition.ts#L94 hence it makes sense to make it available here as well - https://github.com/aws/aws-cdk/blob/4b8714d7b499362f0b77ad9a615479227e339078/packages/aws-cdk-lib/aws-ecs-patterns/lib/fargate/application-load-balanced-fargate-service.ts#L74 Please feel free to contribute the PR. Team would be happy to review it. Thanks.
Thanks for reviewing the issue, @khushail!
I've submitted PR #31461 for review. I haven't added any integration tests as I'm not sure that it's required as it's just exposing an existing property of an underlying construct, and frankly it's going to be hard for me at the moment to build and snapshot the integration test. Hopefully I'm able to get an exemption, but if not, I'll just have to try and build it later when I get back to work.
Hi @noseworthy , thanks for your contribution. Appreciate your efforts! Please see that for PR approval, first it goes through community review. You can reach out to CDK.dev community on slack for seeking support for review for your PR. Once its get reviewed by community, it would be reviewed by the CDK Core team and afterwards it will get merged. let me know if you have any further questions !
Describe the feature
I'd like to configure the
pidMode
for the fargate task definition that I'm building using theaws-ecs-patterns.ApplicationLoadBalancedFargateService
construct. However, the construct takes aApplicationLoadBalancedFargateServiceProps
object which doesn't allow configuringpidMode
.It'd be great to add
pidMode
as an option toApplicationLoadBalancedFargateServiceProps
so that this can be configured without having to build a fullFargateTaskDefinition
construct.Use Case
I need to configure
pidMode
so that I can monitor live process information my fagate ecs tasks with DataDog. Replacing my use oftaskImageOptions
with a newtaskDefinition
property will cause a full replacement of my task definition which i'm trying to avoid. I'm surprised thattaskImageOptions
doesn't supportpidMode
.Proposed Solution
Add an optional
pidMode
property toFargateServiceBaseProps
and if specified, provide it to theFargateTaskDefinition
construct created inapplication-load-balanced-fargate-service.ts
Other Information
Related Issues:
Acknowledgements
CDK version used
2.148.1
Environment details (OS name and version, etc.)
macOS Sonoma 14.6.1, Macbook Pro 2021, Apple m1 Max