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

fsx_lustre_file_system - add auto_import_policy argument #15231

Merged
merged 6 commits into from
Oct 1, 2020

Conversation

DrFaust92
Copy link
Collaborator

@DrFaust92 DrFaust92 commented Sep 19, 2020

Community Note

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

Closes #14406

Release note for CHANGELOG:

resoruce_aws_fsx_lustre_file_system - add `auto_import_policy`  argument

Output from acceptance testing:

$ make testacc TESTARGS='-run=TestAccAWSFsxLustreFileSystem_'
--- PASS: TestAccAWSFsxLustreFileSystem_basic (596.06s)
--- PASS: TestAccAWSFsxLustreFileSystem_ExportPath (1396.45s)
--- PASS: TestAccAWSFsxLustreFileSystem_autoImportPolicy (1373.40s)

@DrFaust92 DrFaust92 requested a review from a team September 19, 2020 13:11
@ghost ghost added size/M Managed by automation to categorize the size of a PR. service/fsx Issues and PRs that pertain to the fsx service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. documentation Introduces or discusses updates to documentation. labels Sep 19, 2020
@DrFaust92 DrFaust92 added the enhancement Requests to existing resources that expand the functionality or scope. label Sep 19, 2020
"auto_import_policy": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Copy link
Contributor

@bflad bflad Sep 21, 2020

Choose a reason for hiding this comment

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

Should this default to NONE to match the API and enable drift detection when it is unconfigured?

Suggested change
Computed: true,
Default: fsx.AutoImportPolicyTypeNone,

Copy link
Collaborator Author

@DrFaust92 DrFaust92 Sep 21, 2020

Choose a reason for hiding this comment

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

I tried to play to play with this but wasn't able to find a combination other than the one in the PR to maked this work.

@DrFaust92
Copy link
Collaborator Author

DrFaust92 commented Sep 21, 2020 via email

@DrFaust92
Copy link
Collaborator Author

Rebased

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 TEST=./aws TESTARGS='-run=TestAccAWSFsxLustreFileSystem_basic\|TestAccAWSFsxLustreFileSystem_autoImportPolicy'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSFsxLustreFileSystem_basic\|TestAccAWSFsxLustreFileSystem_autoImportPolicy -timeout 120m
=== RUN   TestAccAWSFsxLustreFileSystem_basic
=== PAUSE TestAccAWSFsxLustreFileSystem_basic
=== RUN   TestAccAWSFsxLustreFileSystem_autoImportPolicy
=== PAUSE TestAccAWSFsxLustreFileSystem_autoImportPolicy
=== CONT  TestAccAWSFsxLustreFileSystem_basic
=== CONT  TestAccAWSFsxLustreFileSystem_autoImportPolicy
--- PASS: TestAccAWSFsxLustreFileSystem_basic (585.18s)
--- PASS: TestAccAWSFsxLustreFileSystem_autoImportPolicy (1196.34s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	1196.389s

@breathingdust
Copy link
Member

Hey @DrFaust92

Getting consistent test failures on this one, can you take a look?

make testacc TEST=./aws TESTARGS='-run=TestAccAWSFsxLustreFileSystem_basic\|TestAccAWSFsxLustreFileSystem_autoImportPolicy'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSFsxLustreFileSystem_basic\|TestAccAWSFsxLustreFileSystem_autoImportPolicy -timeout 120m
=== RUN   TestAccAWSFsxLustreFileSystem_basic
=== RUN   TestAccAWSFsxLustreFileSystem_autoImportPolicy
    resource_aws_fsx_lustre_file_system_test.go:75: Check 19/19 error: aws_fsx_lustre_file_system.test: Attribute 'auto_import_policy' expected "NONE", got ""
--- FAIL: TestAccAWSFsxLustreFileSystem_basic (483.51s)

@DrFaust92
Copy link
Collaborator Author

@breathingdust mistake on my part during the rebase. basic test should not check this. its computed only when s3 export is set.

@breathingdust
Copy link
Member

Thanks @DrFaust92, looking good now. 🚀

Verified Acceptance Tests in Commercial (us-west-2)

make testacc TEST=./aws TESTARGS='-run=TestAccAWSFsxLustreFileSystem_basic\|TestAccAWSFsxLustreFileSystem_autoImportPolicy'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSFsxLustreFileSystem_basic\|TestAccAWSFsxLustreFileSystem_autoImportPolicy -timeout 120m
=== RUN   TestAccAWSFsxLustreFileSystem_basic
=== PAUSE TestAccAWSFsxLustreFileSystem_basic
=== RUN   TestAccAWSFsxLustreFileSystem_autoImportPolicy
=== PAUSE TestAccAWSFsxLustreFileSystem_autoImportPolicy
=== CONT  TestAccAWSFsxLustreFileSystem_basic
=== CONT  TestAccAWSFsxLustreFileSystem_autoImportPolicy
--- PASS: TestAccAWSFsxLustreFileSystem_basic (642.49s)
--- PASS: TestAccAWSFsxLustreFileSystem_autoImportPolicy (1281.19s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	1283.173s

@breathingdust breathingdust added this to the v3.9.0 milestone Oct 1, 2020
@breathingdust breathingdust merged commit e1d887f into hashicorp:master Oct 1, 2020
breathingdust added a commit that referenced this pull request Oct 1, 2020
@ghost
Copy link

ghost commented Oct 2, 2020

This has been released in version 3.9.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 for triage. Thanks!

@ghost
Copy link

ghost commented Nov 1, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked as resolved and limited conversation to collaborators Nov 1, 2020
@DrFaust92 DrFaust92 deleted the fsx_auto_import_policy branch April 15, 2021 10:40
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/fsx Issues and PRs that pertain to the fsx service. size/M 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.

Expose FSx import preferences to always update S3 Objects
4 participants