Skip to content
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

aws-opensearchservice/domain: r7gd not usable #32138

Open
1 task
alex-at-cascade opened this issue Nov 14, 2024 · 2 comments
Open
1 task

aws-opensearchservice/domain: r7gd not usable #32138

alex-at-cascade opened this issue Nov 14, 2024 · 2 comments
Labels
bug This issue is a bug. effort/small Small work item – less than a day of effort p2 package/tools Related to AWS CDK Tools or CLI

Comments

@alex-at-cascade
Copy link

Describe the bug

When trying to create a domain with dataNodeInstanceType of r7gd.4xlarge.search, CDK reports Error: EBS volumes are required when using instance types other than R3, I3, R6GD, I4G, or IM4GN. - however, gd instances have integrated storage and do not use EBS storage.

Regression Issue

  • Select this option if this issue appears to be a regression.

Last Known Working CDK Version

No response

Expected Behavior

I expected r7gd instances to be allowed, as the AWS console is urging me to upgrade to the newer generation.

Current Behavior

I get the error noted above.

Reproduction Steps

See description.

Possible Solution

Correct the list. (Having a hard-coded list seems really brittle - is there another way to achieve this?)

Additional Information/Context

No response

CDK CLI Version

2.166.0 (build 7bb9203)

Framework Version

No response

Node.js Version

v18.18.2

OS

macOS Monterey Version 12.7.6

Language

TypeScript

Language Version

typescript 5.4.3

Other information

No response

@alex-at-cascade alex-at-cascade added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Nov 14, 2024
@github-actions github-actions bot added the package/tools Related to AWS CDK Tools or CLI label Nov 14, 2024
@khushail khushail added investigating This issue is being investigated and/or work is in progress to resolve the issue. p2 and removed needs-triage This issue or PR still needs to be triaged. labels Nov 14, 2024
@khushail khushail self-assigned this Nov 14, 2024
@khushail
Copy link
Contributor

Hi @alex-at-cascade , thanks for reporting this. I see the error is generated because of the code section given below. The list needs to be updated with r7gd instance as its a Graviton instance and does not need internal EBS Storage.

Screenshot 2024-11-14 at 12 15 33 PM

throw new Error('EBS volumes are required when using instance types other than R3, I3, R6GD, I4G, or IM4GN.');

    // Validate against instance type restrictions, per
    // https://docs.aws.amazon.com/opensearch-service/latest/developerguide/supported-instance-types.html
    if (isSomeInstanceType('i3', 'r6gd', 'i4g', 'im4gn') && ebsEnabled) {
      throw new Error('I3, R6GD, I4G, and IM4GN instance types do not support EBS storage volumes.');
    }

I am marking this as P2 which means it won't be immediately addressed by the team but would be on their radar and would also be open for community contribution.

You are right in saying there should be a generalised way of adding these instance rather than hardcoded values. Suggestions are welcome in this regard.

I have been working on adding i4i instance with this PR and would see if I can take up this one too.

@khushail khushail added effort/small Small work item – less than a day of effort and removed investigating This issue is being investigated and/or work is in progress to resolve the issue. labels Nov 14, 2024
@khushail khushail removed their assignment Nov 14, 2024
@alex-at-cascade
Copy link
Author

Great, thank you! One approach that might be less of an obstruction would be to have two lists : those that are known to need EBS, and those that are known not to. If the instance type is on one of those lists, throw an error if the config is wrong. But if it's a new instance type not on either list, log a prominent warning (not error) about a currently unknown instance type, and urging to verify the setting in either case (and maybe also recommend to file a support ticket 😉 )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. effort/small Small work item – less than a day of effort p2 package/tools Related to AWS CDK Tools or CLI
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants