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

Add model_access_config, multi_model_config and inference_specification_name to sagemaker_model primary_container and container block #35873

Conversation

deepakbshetty
Copy link
Contributor

@deepakbshetty deepakbshetty commented Feb 18, 2024

Description

Relations

Closes #34795
Also adds below to primary_container and container

inference_specification_name
multi_model_config - > model_access_config ( Enabled | Disabled )

References

Output from Acceptance Testing

$ make testacc TESTS=TestAccSageMakerModel_primaryContainerInferenceSpecificationName PKG=sagemaker
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.23.0 test ./internal/service/sagemaker/... -v -count 1 -parallel 20 -run='TestAccSageMakerModel_primaryContainerInferenceSpecificationName'  -timeout 360m
=== RUN   TestAccSageMakerModel_primaryContainerInferenceSpecificationName
=== PAUSE TestAccSageMakerModel_primaryContainerInferenceSpecificationName
=== CONT  TestAccSageMakerModel_primaryContainerInferenceSpecificationName
--- PASS: TestAccSageMakerModel_primaryContainerInferenceSpecificationName (101.61s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/sagemaker  134.874s

$ make testacc TESTS=TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting PKG=sagemaker
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.23.0 test ./internal/service/sagemaker/... -v -count 1 -parallel 20 -run='TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting'  -timeout 360m
=== RUN   TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting
=== PAUSE TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting
=== CONT  TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting
--- PASS: TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting (114.44s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/sagemaker  147.930s

$ make testacc TESTS=TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula PKG=sagemaker
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.23.0 test ./internal/service/sagemaker/... -v -count 1 -parallel 20 -run='TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula'  -timeout 360m
=== RUN   TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula
=== PAUSE TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula
=== CONT  TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula
--- PASS: TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula (114.83s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/sagemaker  148.564s

$ make testacc TESTS=TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting PKG=sagemaker
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.23.0 test ./internal/service/sagemaker/... -v -count 1 -parallel 20 -run='TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting'  -timeout 360m
=== RUN   TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting
=== PAUSE TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting
=== CONT  TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting
--- PASS: TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting (110.88s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/sagemaker  143.968s

...

Copy link

Community Note

Voting for Prioritization

  • Please vote on this pull request by adding a 👍 reaction to the original post to help the community and maintainers prioritize this pull request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

For Submitters

  • Review the contribution guide relating to the type of change you are making to ensure all of the necessary steps have been taken.
  • For new resources and data sources, use skaff to generate scaffolding with comments detailing common expectations.
  • Whether or not the branch has been rebased will not impact prioritization, but doing so is always a welcome surprise.

@github-actions github-actions bot added size/XL Managed by automation to categorize the size of a PR. documentation Introduces or discusses updates to documentation. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. service/sagemaker Issues and PRs that pertain to the sagemaker service. labels Feb 18, 2024
@terraform-aws-provider terraform-aws-provider bot added the needs-triage Waiting for first response or review from a maintainer. label Feb 18, 2024
@deepakbshetty
Copy link
Contributor Author

deepakbshetty commented Feb 18, 2024

Hi @DrFaust92, For your kind review. 4 new test cases created to cover the enhancement.

@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch 2 times, most recently from 7bb843b to 2185243 Compare February 20, 2024 19:30
@deepakbshetty
Copy link
Contributor Author

deepakbshetty commented Feb 20, 2024

Hi @ewbankkit, The issues should be fixed now and lint tests should be better. Appreciate if you can retrigger. Thanks in advance.

@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch from 31c67c8 to cbc02a1 Compare February 20, 2024 22:40
@justinretzolk justinretzolk added enhancement Requests to existing resources that expand the functionality or scope. and removed needs-triage Waiting for first response or review from a maintainer. labels Mar 7, 2024
@deepakbshetty
Copy link
Contributor Author

Dear @DrFaust92, Gentle nudge to review

Copy link
Collaborator

@DrFaust92 DrFaust92 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@deepakbshetty
Copy link
Contributor Author

Hi @ewbankkit 👋 May I request if you can consider this for merge

@DrFaust92
Copy link
Collaborator

deepakbshetty can you fix conflicts and add changelog entry?

@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch from cbc02a1 to 6192bb3 Compare July 20, 2024 19:30
@deepakbshetty deepakbshetty requested a review from a team as a code owner July 20, 2024 19:30
Copy link

Thank you for your contribution! 🚀

Please note that typically Go dependency changes are handled in this repository by dependabot or the maintainers. This is to prevent pull request merge conflicts and further delay reviews of contributions. Remove any changes to the go.mod or go.sum files and commit them into this pull request.

Additional details:

  • Check open pull requests with the dependencies label to view other dependency updates.
  • If this pull request includes an update the AWS Go SDK (or any other dependency) version, only updates submitted via dependabot will be merged. This pull request will need to remove these changes and will need to be rebased after the existing dependency update via dependabot has been merged for this pull request to be reviewed.
  • If this pull request is for supporting a new AWS service:
    • Ensure the new AWS service changes are following the Contributing Guide section on new services, in particular that the dependency addition and initial provider support are in a separate pull request from other changes (e.g. new resources). Contributions not following this item will not be reviewed until the changes are split.
    • If this pull request is already a separate pull request from the above item, you can ignore this message.

@deepakbshetty
Copy link
Contributor Author

Dear @DrFaust92 , Added changelog and fixed conflicts

@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch from 6192bb3 to 3d3f13d Compare July 20, 2024 22:45
Copy link

Thank you for your contribution! 🚀

Please note that typically Go dependency changes are handled in this repository by dependabot or the maintainers. This is to prevent pull request merge conflicts and further delay reviews of contributions. Remove any changes to the go.mod or go.sum files and commit them into this pull request.

Additional details:

  • Check open pull requests with the dependencies label to view other dependency updates.
  • If this pull request includes an update the AWS Go SDK (or any other dependency) version, only updates submitted via dependabot will be merged. This pull request will need to remove these changes and will need to be rebased after the existing dependency update via dependabot has been merged for this pull request to be reviewed.
  • If this pull request is for supporting a new AWS service:
    • Ensure the new AWS service changes are following the Contributing Guide section on new services, in particular that the dependency addition and initial provider support are in a separate pull request from other changes (e.g. new resources). Contributions not following this item will not be reviewed until the changes are split.
    • If this pull request is already a separate pull request from the above item, you can ignore this message.

@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch from 3d3f13d to d63693b Compare July 21, 2024 01:37
Copy link

Thank you for your contribution! 🚀

Please note that typically Go dependency changes are handled in this repository by dependabot or the maintainers. This is to prevent pull request merge conflicts and further delay reviews of contributions. Remove any changes to the go.mod or go.sum files and commit them into this pull request.

Additional details:

  • Check open pull requests with the dependencies label to view other dependency updates.
  • If this pull request includes an update the AWS Go SDK (or any other dependency) version, only updates submitted via dependabot will be merged. This pull request will need to remove these changes and will need to be rebased after the existing dependency update via dependabot has been merged for this pull request to be reviewed.
  • If this pull request is for supporting a new AWS service:
    • Ensure the new AWS service changes are following the Contributing Guide section on new services, in particular that the dependency addition and initial provider support are in a separate pull request from other changes (e.g. new resources). Contributions not following this item will not be reviewed until the changes are split.
    • If this pull request is already a separate pull request from the above item, you can ignore this message.

Copy link
Collaborator

@DrFaust92 DrFaust92 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (without running tests)

@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch 2 times, most recently from c309079 to 11e56d8 Compare July 24, 2024 21:01
@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch 3 times, most recently from 3996375 to 8dcc494 Compare August 3, 2024 12:11
@deepakbshetty
Copy link
Contributor Author

Dear @DrFaust92 , Request re-review. Added prebuilt ecr image data source to tests, as they are now available in provider version 5.61.0

@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch 3 times, most recently from 3d3096e to dea8c9d Compare August 31, 2024 14:12
…on_name to primary_container and container block
@deepakbshetty deepakbshetty force-pushed the f-aws_sagemaker_model-model-access_config branch from dea8c9d to 72b549a Compare August 31, 2024 16:16
.changelog/35873.txt Outdated Show resolved Hide resolved
@deepakbshetty
Copy link
Contributor Author

Hi @ewbankkit , For your kind consideration. Adds multiple missing features for sagemaker model creation.

@ewbankkit ewbankkit self-assigned this Sep 12, 2024
@github-actions github-actions bot added the prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. label Sep 12, 2024
Copy link
Contributor

@ewbankkit ewbankkit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀.

% make testacc TESTARGS='-run=TestAccSageMakerModel_' PKG=sagemaker ACCTEST_PARALLELISM=3
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.22.6 test ./internal/service/sagemaker/... -v -count 1 -parallel 3  -run=TestAccSageMakerModel_ -timeout 360m
=== RUN   TestAccSageMakerModel_basic
=== PAUSE TestAccSageMakerModel_basic
=== RUN   TestAccSageMakerModel_inferenceExecution
=== PAUSE TestAccSageMakerModel_inferenceExecution
=== RUN   TestAccSageMakerModel_tags
=== PAUSE TestAccSageMakerModel_tags
=== RUN   TestAccSageMakerModel_primaryContainerModelDataURL
=== PAUSE TestAccSageMakerModel_primaryContainerModelDataURL
=== RUN   TestAccSageMakerModel_primaryContainerHostname
=== PAUSE TestAccSageMakerModel_primaryContainerHostname
=== RUN   TestAccSageMakerModel_primaryContainerImage
=== PAUSE TestAccSageMakerModel_primaryContainerImage
=== RUN   TestAccSageMakerModel_primaryContainerEnvironment
=== PAUSE TestAccSageMakerModel_primaryContainerEnvironment
=== RUN   TestAccSageMakerModel_primaryContainerModeSingle
=== PAUSE TestAccSageMakerModel_primaryContainerModeSingle
=== RUN   TestAccSageMakerModel_primaryContainerModelPackageName
=== PAUSE TestAccSageMakerModel_primaryContainerModelPackageName
=== RUN   TestAccSageMakerModel_primaryContainerModelDataSource
=== PAUSE TestAccSageMakerModel_primaryContainerModelDataSource
=== RUN   TestAccSageMakerModel_containers
=== PAUSE TestAccSageMakerModel_containers
=== RUN   TestAccSageMakerModel_vpc
=== PAUSE TestAccSageMakerModel_vpc
=== RUN   TestAccSageMakerModel_primaryContainerPrivateDockerRegistry
=== PAUSE TestAccSageMakerModel_primaryContainerPrivateDockerRegistry
=== RUN   TestAccSageMakerModel_networkIsolation
=== PAUSE TestAccSageMakerModel_networkIsolation
=== RUN   TestAccSageMakerModel_disappears
=== PAUSE TestAccSageMakerModel_disappears
=== RUN   TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula
=== PAUSE TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula
=== RUN   TestAccSageMakerModel_primaryContainerInferenceSpecificationName
=== PAUSE TestAccSageMakerModel_primaryContainerInferenceSpecificationName
=== RUN   TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting
=== PAUSE TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting
=== RUN   TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting
=== PAUSE TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting
=== CONT  TestAccSageMakerModel_basic
=== CONT  TestAccSageMakerModel_containers
=== CONT  TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula
--- PASS: TestAccSageMakerModel_containers (22.84s)
=== CONT  TestAccSageMakerModel_primaryContainerImage
--- PASS: TestAccSageMakerModel_primaryContainerModelS3DataSourceAcceptEula (22.93s)
=== CONT  TestAccSageMakerModel_primaryContainerModelDataSource
--- PASS: TestAccSageMakerModel_basic (27.84s)
=== CONT  TestAccSageMakerModel_primaryContainerModelPackageName
--- PASS: TestAccSageMakerModel_primaryContainerModelDataSource (25.78s)
=== CONT  TestAccSageMakerModel_primaryContainerModeSingle
--- PASS: TestAccSageMakerModel_primaryContainerModelPackageName (22.54s)
=== CONT  TestAccSageMakerModel_primaryContainerEnvironment
--- PASS: TestAccSageMakerModel_primaryContainerImage (27.78s)
=== CONT  TestAccSageMakerModel_primaryContainerModelDataURL
--- PASS: TestAccSageMakerModel_primaryContainerEnvironment (21.20s)
=== CONT  TestAccSageMakerModel_primaryContainerHostname
--- PASS: TestAccSageMakerModel_primaryContainerModeSingle (26.26s)
=== CONT  TestAccSageMakerModel_networkIsolation
--- PASS: TestAccSageMakerModel_primaryContainerModelDataURL (27.18s)
=== CONT  TestAccSageMakerModel_disappears
--- PASS: TestAccSageMakerModel_disappears (20.28s)
=== CONT  TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting
--- PASS: TestAccSageMakerModel_networkIsolation (25.28s)
=== CONT  TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting
--- PASS: TestAccSageMakerModel_primaryContainerHostname (32.05s)
=== CONT  TestAccSageMakerModel_primaryContainerInferenceSpecificationName
--- PASS: TestAccSageMakerModel_primaryContainerMultiModelConfigModelCacheSetting (24.70s)
=== CONT  TestAccSageMakerModel_tags
--- PASS: TestAccSageMakerModel_containersMultiModelConfigModelCacheSetting (25.98s)
=== CONT  TestAccSageMakerModel_inferenceExecution
--- PASS: TestAccSageMakerModel_primaryContainerInferenceSpecificationName (26.21s)
=== CONT  TestAccSageMakerModel_primaryContainerPrivateDockerRegistry
--- PASS: TestAccSageMakerModel_inferenceExecution (22.70s)
=== CONT  TestAccSageMakerModel_vpc
--- PASS: TestAccSageMakerModel_primaryContainerPrivateDockerRegistry (27.31s)
--- PASS: TestAccSageMakerModel_tags (41.34s)
--- PASS: TestAccSageMakerModel_vpc (26.29s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/sagemaker	180.223s

@ewbankkit
Copy link
Contributor

@deepakbshetty Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit 50a8f2c into hashicorp:main Sep 12, 2024
40 checks passed
@github-actions github-actions bot added this to the v5.67.0 milestone Sep 12, 2024
@github-actions github-actions bot removed the prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. label Sep 13, 2024
Copy link

This functionality has been released in v5.67.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

Copy link

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Introduces or discusses updates to documentation. enhancement Requests to existing resources that expand the functionality or scope. service/sagemaker Issues and PRs that pertain to the sagemaker service. size/XL Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Enhancement]: aws_sagemaker_model resource missing ModelAccessConfig
4 participants