Closed clareliguori closed 1 year ago
Note there is another ARN parser that likely should be addressed as part of the proposed solution: https://github.com/aws/aws-sdk-js-v3/blob/main/packages/util-endpoints/src/lib/aws/parseArn.ts
Hi @clareliguori, thanks for opening this issue. I agree with the suggested changes. I will mark this issue to be reviewed so we can address it further. I can not guarantee this will be addressed soon since we have a huge backlog and therefore we must prioritize.
Thanks!
Hi @clareliguori ,
After discussing this with the team we agreed that this is a reasonable feature request, however the team currently have no bandwidth to tackle implementing this feature. Additionally feature requests are prioritized based on community engagement, and since this FR was open without any additional engagement we have concluded that its better to close this rather then letting it languish in our queue and setting false expectations.
We appreciate your patience and hope this doesn't discourage you from opening additional bug reports / feature requests int he future.
Thanks again, Ran~
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.
Describe the feature
util-arn-parser takes a naive approach to extracting resource names from ARNs, simply splitting the ARN on
:
into 6 segments. I cannot always use util-arn-parser to extract a resource name from an ARN that can be directly provided to a service API. Some ARNs include resource types, and util-arn-parser returns the "resourceName" string including the resource type name.For example:
Use Case
I often find myself duplicating logic to extract the resource name from ARNs:
Ideally I would be able to parse the resource name directly, without an additional split:
Proposed Solution
The AWS CDK contains logic that could be adapted to util-arn-parser. The caller passes the expected ARN format (an enum) for the given ARN. https://github.com/aws/aws-cdk/blob/main/packages/%40aws-cdk/core/lib/arn.ts#L6-L48
Other Information
No response
Acknowledgements
SDK version used
3.208.0
Environment details (OS name and version, etc.)
Linux