eks: Remove the Cluster custom resource in favour of L1 #28609
Labels
@aws-cdk/aws-eks
Related to Amazon Elastic Kubernetes Service
effort/medium
Medium work item – several days of effort
feature-request
A feature should be added or improved.
p2
Describe the feature
Currently,
eks.Cluster
is implemented as a Custom Resource, though I believe this is no longer required and is causing unneeded complexity.The docstring for the CR says
This was added 4 years ago in #3510 and I don't think it's true anymore. The Cfn resource takes a
RoleArn
property which should solve the problem identified in the docstring.I had a quick run through of the custom handler source and it looks like it hasn't really gained any other features since then, so should be a straighforward replacement.
Use Case
#28584 highlights the serious risks introduced by CDK diverging from Cloudformation and implementing custom resources. The current implementation makes the behaviour harder to inspect.
Proposed Solution
The L2
eks.Cluster
should replace its internalClusterResource
with just the L1CfnCluster
.I'm unsure on how this migration would actually have to work.
Other Information
No response
Acknowledgements
CDK version used
2.113.0 (build ccd534a)
Environment details (OS name and version, etc.)
N/A
The text was updated successfully, but these errors were encountered: