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

#26048 add record_size_kib to aws_fsx_openzfs_volume #26049

Merged
merged 6 commits into from
Aug 2, 2022

Conversation

pwillie
Copy link
Contributor

@pwillie pwillie commented Jul 29, 2022

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 #26048

Output from acceptance testing:

$ make testacc TESTS=TestAccFSxOpenzfsVolume_recordSizeKib PKG=fsx                         
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/fsx/... -v -count 1 -parallel 20 -run='TestAccFSxOpenzfsVolume_recordSizeKib'  -timeout 180m
=== RUN   TestAccFSxOpenzfsVolume_recordSizeKib
=== PAUSE TestAccFSxOpenzfsVolume_recordSizeKib
=== CONT  TestAccFSxOpenzfsVolume_recordSizeKib
--- PASS: TestAccFSxOpenzfsVolume_recordSizeKib (1068.79s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/fsx        1070.818s
...

@github-actions github-actions bot added documentation Introduces or discusses updates to documentation. service/fsx Issues and PRs that pertain to the fsx service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. size/M Managed by automation to categorize the size of a PR. needs-triage Waiting for first response or review from a maintainer. labels Jul 29, 2022
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Welcome @pwillie 👋

It looks like this is your first Pull Request submission to the Terraform AWS Provider! If you haven’t already done so please make sure you have checked out our CONTRIBUTING guide and FAQ to make sure your contribution is adhering to best practice and has all the necessary elements in place for a successful approval.

Also take a look at our FAQ which details how we prioritize Pull Requests for inclusion.

Thanks again, and welcome to the community! 😃

@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 Jul 29, 2022
@bschaatsbergen
Copy link
Member

Hi @pwillie - thanks for raising this PR, could you please add a changelog entry?

@pwillie
Copy link
Contributor Author

pwillie commented Jul 30, 2022

Hi @bschaatsbergen - changelog added (although think I referenced the issue rather than pull request. Is that ok?)

@bschaatsbergen
Copy link
Member

bschaatsbergen commented Jul 30, 2022

Hi @bschaatsbergen - changelog added (although think I referenced the issue rather than pull request. Is that ok?)

Preferably we reference the pull request - if you don't mind changing it, that would be great.

@pwillie
Copy link
Contributor Author

pwillie commented Jul 30, 2022

Good to know. Updated.

@bschaatsbergen
Copy link
Member

bschaatsbergen commented Jul 30, 2022

LGTM 🚀 - lets wait for a core contributor to merge it

The tests that failed here also fail on main

bruno@pop-os ~/G/f/pwillie-terraform-provider-aws (fsx-openzfs-recordsize)> make testacc TESTS=TestAccFSxOpenzfsVolume_ PKG=fsx                                                                                                 (base) 
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/fsx/... -v -count 1 -parallel 20 -run='TestAccFSxOpenzfsVolume_'  -timeout 180m
=== RUN   TestAccFSxOpenzfsVolume_basic
=== PAUSE TestAccFSxOpenzfsVolume_basic
=== RUN   TestAccFSxOpenzfsVolume_parentVolume
=== PAUSE TestAccFSxOpenzfsVolume_parentVolume
=== RUN   TestAccFSxOpenzfsVolume_tags
=== PAUSE TestAccFSxOpenzfsVolume_tags
=== RUN   TestAccFSxOpenzfsVolume_copyTags
=== PAUSE TestAccFSxOpenzfsVolume_copyTags
=== RUN   TestAccFSxOpenzfsVolume_name
=== PAUSE TestAccFSxOpenzfsVolume_name
=== RUN   TestAccFSxOpenzfsVolume_dataCompressionType
=== PAUSE TestAccFSxOpenzfsVolume_dataCompressionType
=== RUN   TestAccFSxOpenzfsVolume_readOnly
=== PAUSE TestAccFSxOpenzfsVolume_readOnly
=== RUN   TestAccFSxOpenzfsVolume_recordSizeKib
=== PAUSE TestAccFSxOpenzfsVolume_recordSizeKib
=== RUN   TestAccFSxOpenzfsVolume_storageCapacity
=== PAUSE TestAccFSxOpenzfsVolume_storageCapacity
=== RUN   TestAccFSxOpenzfsVolume_nfsExports
=== PAUSE TestAccFSxOpenzfsVolume_nfsExports
=== RUN   TestAccFSxOpenzfsVolume_userAndGroupQuotas
=== PAUSE TestAccFSxOpenzfsVolume_userAndGroupQuotas
=== CONT  TestAccFSxOpenzfsVolume_basic
=== CONT  TestAccFSxOpenzfsVolume_readOnly
=== CONT  TestAccFSxOpenzfsVolume_copyTags
=== CONT  TestAccFSxOpenzfsVolume_userAndGroupQuotas
=== CONT  TestAccFSxOpenzfsVolume_parentVolume
=== CONT  TestAccFSxOpenzfsVolume_tags
=== CONT  TestAccFSxOpenzfsVolume_dataCompressionType
=== CONT  TestAccFSxOpenzfsVolume_nfsExports
=== CONT  TestAccFSxOpenzfsVolume_name
=== CONT  TestAccFSxOpenzfsVolume_storageCapacity
=== CONT  TestAccFSxOpenzfsVolume_recordSizeKib
=== CONT  TestAccFSxOpenzfsVolume_basic
    openzfs_volume_test.go:24: Step 1/2 error: Check failed: Check 9/15 error: aws_fsx_openzfs_volume.test: Attribute 'nfs_exports.0.client_configurations.0.options.#' expected "1", got "2"
=== CONT  TestAccFSxOpenzfsVolume_userAndGroupQuotas
    openzfs_volume_test.go:412: Step 1/3 error: After applying this test step and performing a `terraform refresh`, the plan was not empty.
        stdout
        
        
        Terraform used the selected providers to generate the following execution
        plan. Resource actions are indicated with the following symbols:
          ~ update in-place
        
        Terraform will perform the following actions:
        
          # aws_fsx_openzfs_volume.test will be updated in-place
          ~ resource "aws_fsx_openzfs_volume" "test" {
                id                               = "fsvol-092edc483b8e6de8e"
                name                             = "tf-acc-test-5224169345004751284"
                tags                             = {}
                # (10 unchanged attributes hidden)
        
              - user_and_group_quotas {
                  - id                         = 0 -> null
                  - storage_capacity_quota_gib = 0 -> null
                  - type                       = "GROUP" -> null
                }
              - user_and_group_quotas {
                  - id                         = 0 -> null
                  - storage_capacity_quota_gib = 0 -> null
                  - type                       = "USER" -> null
                }
        
                # (2 unchanged blocks hidden)
            }
        
        Plan: 0 to add, 1 to change, 0 to destroy.
--- FAIL: TestAccFSxOpenzfsVolume_userAndGroupQuotas (975.51s)
--- FAIL: TestAccFSxOpenzfsVolume_basic (993.59s)
--- PASS: TestAccFSxOpenzfsVolume_tags (1029.17s)
--- PASS: TestAccFSxOpenzfsVolume_parentVolume (1088.77s)
--- PASS: TestAccFSxOpenzfsVolume_storageCapacity (1092.46s)
--- PASS: TestAccFSxOpenzfsVolume_copyTags (1099.85s)
--- PASS: TestAccFSxOpenzfsVolume_nfsExports (1132.36s)
--- PASS: TestAccFSxOpenzfsVolume_name (1133.99s)
--- PASS: TestAccFSxOpenzfsVolume_dataCompressionType (1154.14s)
--- PASS: TestAccFSxOpenzfsVolume_recordSizeKib (1154.81s)
--- PASS: TestAccFSxOpenzfsVolume_readOnly (1154.94s)
FAIL
FAIL    github.com/hashicorp/terraform-provider-aws/internal/service/fsx        1155.001s
FAIL
make: *** [GNUmakefile:52: testacc] Error 1

@pwillie
Copy link
Contributor Author

pwillie commented Jul 30, 2022

Thanks for the review @bschaatsbergen

@ewbankkit
Copy link
Contributor

ewbankkit commented Aug 1, 2022

% make testacc TESTARGS='-run=TestAccFSxOpenzfsVolume_' PKG=fsx ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/fsx/... -v -count 1 -parallel 2  -run=TestAccFSxOpenzfsVolume_ -timeout 180m
=== RUN   TestAccFSxOpenzfsVolume_basic
=== PAUSE TestAccFSxOpenzfsVolume_basic
=== RUN   TestAccFSxOpenzfsVolume_parentVolume
=== PAUSE TestAccFSxOpenzfsVolume_parentVolume
=== RUN   TestAccFSxOpenzfsVolume_tags
=== PAUSE TestAccFSxOpenzfsVolume_tags
=== RUN   TestAccFSxOpenzfsVolume_copyTags
=== PAUSE TestAccFSxOpenzfsVolume_copyTags
=== RUN   TestAccFSxOpenzfsVolume_name
=== PAUSE TestAccFSxOpenzfsVolume_name
=== RUN   TestAccFSxOpenzfsVolume_dataCompressionType
=== PAUSE TestAccFSxOpenzfsVolume_dataCompressionType
=== RUN   TestAccFSxOpenzfsVolume_readOnly
=== PAUSE TestAccFSxOpenzfsVolume_readOnly
=== RUN   TestAccFSxOpenzfsVolume_recordSizeKib
=== PAUSE TestAccFSxOpenzfsVolume_recordSizeKib
=== RUN   TestAccFSxOpenzfsVolume_storageCapacity
=== PAUSE TestAccFSxOpenzfsVolume_storageCapacity
=== RUN   TestAccFSxOpenzfsVolume_nfsExports
=== PAUSE TestAccFSxOpenzfsVolume_nfsExports
=== RUN   TestAccFSxOpenzfsVolume_userAndGroupQuotas
=== PAUSE TestAccFSxOpenzfsVolume_userAndGroupQuotas
=== CONT  TestAccFSxOpenzfsVolume_basic
=== CONT  TestAccFSxOpenzfsVolume_readOnly
--- PASS: TestAccFSxOpenzfsVolume_basic (933.18s)
=== CONT  TestAccFSxOpenzfsVolume_copyTags
--- PASS: TestAccFSxOpenzfsVolume_readOnly (1079.16s)
=== CONT  TestAccFSxOpenzfsVolume_dataCompressionType
--- PASS: TestAccFSxOpenzfsVolume_copyTags (1066.28s)
=== CONT  TestAccFSxOpenzfsVolume_name
--- PASS: TestAccFSxOpenzfsVolume_dataCompressionType (1067.53s)
=== CONT  TestAccFSxOpenzfsVolume_nfsExports
=== CONT  TestAccFSxOpenzfsVolume_userAndGroupQuotas
--- PASS: TestAccFSxOpenzfsVolume_name (1108.95s)
--- PASS: TestAccFSxOpenzfsVolume_nfsExports (1081.44s)
=== CONT  TestAccFSxOpenzfsVolume_tags
=== CONT  TestAccFSxOpenzfsVolume_userAndGroupQuotas
    openzfs_volume_test.go:412: Step 1/3 error: After applying this test step and performing a `terraform refresh`, the plan was not empty.
        stdout
        
        
        Terraform used the selected providers to generate the following execution
        plan. Resource actions are indicated with the following symbols:
          ~ update in-place
        
        Terraform will perform the following actions:
        
          # aws_fsx_openzfs_volume.test will be updated in-place
          ~ resource "aws_fsx_openzfs_volume" "test" {
                id                               = "fsvol-0dfe5f622b4dbaee2"
                name                             = "tf-acc-test-6341542772351364948"
                tags                             = {}
                # (10 unchanged attributes hidden)
        
        
              - user_and_group_quotas {
                  - id                         = 0 -> null
                  - storage_capacity_quota_gib = 0 -> null
                  - type                       = "GROUP" -> null
                }
              - user_and_group_quotas {
                  - id                         = 0 -> null
                  - storage_capacity_quota_gib = 0 -> null
                  - type                       = "USER" -> null
                }
                # (2 unchanged blocks hidden)
            }
        
        Plan: 0 to add, 1 to change, 0 to destroy.
--- PASS: TestAccFSxOpenzfsVolume_tags (922.15s)
=== CONT  TestAccFSxOpenzfsVolume_storageCapacity
--- FAIL: TestAccFSxOpenzfsVolume_userAndGroupQuotas (979.88s)
=== CONT  TestAccFSxOpenzfsVolume_recordSizeKib
--- PASS: TestAccFSxOpenzfsVolume_recordSizeKib (1117.72s)
=== CONT  TestAccFSxOpenzfsVolume_parentVolume
--- PASS: TestAccFSxOpenzfsVolume_storageCapacity (1158.71s)
--- PASS: TestAccFSxOpenzfsVolume_parentVolume (1026.34s)
FAIL
FAIL	github.com/hashicorp/terraform-provider-aws/internal/service/fsx	6317.256s
FAIL
make: *** [testacc] Error 1

Failures are unrelated to this change and occur in nightly CI:

=== RUN   TestAccFSxOpenzfsVolume_userAndGroupQuotas
=== PAUSE TestAccFSxOpenzfsVolume_userAndGroupQuotas
=== CONT  TestAccFSxOpenzfsVolume_userAndGroupQuotas
openzfs_volume_test.go:376: Step 1/3 error: After applying this test step and performing a `terraform refresh`, the plan was not empty.
stdout
Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
~ update in-place
Terraform will perform the following actions:
# aws_fsx_openzfs_volume.test will be updated in-place
~ resource "aws_fsx_openzfs_volume" "test" {
id                               = "fsvol-0156f0af32bc6bc04"
name                             = "tf-acc-test-5453947432521315878"
tags                             = {}
# (9 unchanged attributes hidden)
- user_and_group_quotas {
- id                         = 0 -> null
- storage_capacity_quota_gib = 0 -> null
- type                       = "GROUP" -> null
}
- user_and_group_quotas {
- id                         = 0 -> null
- storage_capacity_quota_gib = 0 -> null
- type                       = "USER" -> null
}
# (2 unchanged blocks hidden)
}
Plan: 0 to add, 1 to change, 0 to destroy.
--- FAIL: TestAccFSxOpenzfsVolume_userAndGroupQuotas (1018.14s)
% make testacc TESTARGS='-run=TestAccFSxOpenzfsFileSystem_' PKG=fsx ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/fsx/... -v -count 1 -parallel 2  -run=TestAccFSxOpenzfsFileSystem_ -timeout 180m
=== RUN   TestAccFSxOpenzfsFileSystem_basic
=== PAUSE TestAccFSxOpenzfsFileSystem_basic
=== RUN   TestAccFSxOpenzfsFileSystem_diskIops
=== PAUSE TestAccFSxOpenzfsFileSystem_diskIops
=== RUN   TestAccFSxOpenzfsFileSystem_disappears
=== PAUSE TestAccFSxOpenzfsFileSystem_disappears
=== RUN   TestAccFSxOpenzfsFileSystem_rootVolume
=== PAUSE TestAccFSxOpenzfsFileSystem_rootVolume
=== RUN   TestAccFSxOpenzfsFileSystem_securityGroupIDs
=== PAUSE TestAccFSxOpenzfsFileSystem_securityGroupIDs
=== RUN   TestAccFSxOpenzfsFileSystem_tags
=== PAUSE TestAccFSxOpenzfsFileSystem_tags
=== RUN   TestAccFSxOpenzfsFileSystem_copyTags
=== PAUSE TestAccFSxOpenzfsFileSystem_copyTags
=== RUN   TestAccFSxOpenzfsFileSystem_throughput
=== PAUSE TestAccFSxOpenzfsFileSystem_throughput
=== RUN   TestAccFSxOpenzfsFileSystem_storageType
=== PAUSE TestAccFSxOpenzfsFileSystem_storageType
=== RUN   TestAccFSxOpenzfsFileSystem_weeklyMaintenanceStartTime
=== PAUSE TestAccFSxOpenzfsFileSystem_weeklyMaintenanceStartTime
=== RUN   TestAccFSxOpenzfsFileSystem_automaticBackupRetentionDays
=== PAUSE TestAccFSxOpenzfsFileSystem_automaticBackupRetentionDays
=== RUN   TestAccFSxOpenzfsFileSystem_kmsKeyID
=== PAUSE TestAccFSxOpenzfsFileSystem_kmsKeyID
=== RUN   TestAccFSxOpenzfsFileSystem_dailyAutomaticBackupStartTime
=== PAUSE TestAccFSxOpenzfsFileSystem_dailyAutomaticBackupStartTime
=== RUN   TestAccFSxOpenzfsFileSystem_throughputCapacity
=== PAUSE TestAccFSxOpenzfsFileSystem_throughputCapacity
=== RUN   TestAccFSxOpenzfsFileSystem_storageCapacity
=== PAUSE TestAccFSxOpenzfsFileSystem_storageCapacity
=== CONT  TestAccFSxOpenzfsFileSystem_basic
=== CONT  TestAccFSxOpenzfsFileSystem_storageType
=== CONT  TestAccFSxOpenzfsFileSystem_basic
    openzfs_file_system_test.go:34: Step 1/2 error: Check failed: Check 31/31 error: aws_fsx_openzfs_file_system.test: Attribute 'root_volume_configuration.0.user_and_group_quotas.#' expected "0", got "2"
--- FAIL: TestAccFSxOpenzfsFileSystem_basic (835.51s)
=== CONT  TestAccFSxOpenzfsFileSystem_dailyAutomaticBackupStartTime
--- PASS: TestAccFSxOpenzfsFileSystem_storageType (906.93s)
=== CONT  TestAccFSxOpenzfsFileSystem_storageCapacity
--- PASS: TestAccFSxOpenzfsFileSystem_dailyAutomaticBackupStartTime (920.81s)
=== CONT  TestAccFSxOpenzfsFileSystem_throughputCapacity
--- PASS: TestAccFSxOpenzfsFileSystem_storageCapacity (1058.28s)
=== CONT  TestAccFSxOpenzfsFileSystem_securityGroupIDs
--- PASS: TestAccFSxOpenzfsFileSystem_throughputCapacity (1581.71s)
=== CONT  TestAccFSxOpenzfsFileSystem_throughput
--- PASS: TestAccFSxOpenzfsFileSystem_securityGroupIDs (1658.27s)
=== CONT  TestAccFSxOpenzfsFileSystem_copyTags
--- PASS: TestAccFSxOpenzfsFileSystem_copyTags (961.95s)
=== CONT  TestAccFSxOpenzfsFileSystem_tags
--- PASS: TestAccFSxOpenzfsFileSystem_throughput (1532.54s)
=== CONT  TestAccFSxOpenzfsFileSystem_automaticBackupRetentionDays
--- PASS: TestAccFSxOpenzfsFileSystem_tags (896.15s)
=== CONT  TestAccFSxOpenzfsFileSystem_kmsKeyID
--- PASS: TestAccFSxOpenzfsFileSystem_automaticBackupRetentionDays (1034.84s)
=== CONT  TestAccFSxOpenzfsFileSystem_weeklyMaintenanceStartTime
--- PASS: TestAccFSxOpenzfsFileSystem_kmsKeyID (936.06s)
=== CONT  TestAccFSxOpenzfsFileSystem_disappears
--- PASS: TestAccFSxOpenzfsFileSystem_weeklyMaintenanceStartTime (920.33s)
=== CONT  TestAccFSxOpenzfsFileSystem_rootVolume
    openzfs_file_system_test.go:153: Step 1/5 error: After applying this test step and performing a `terraform refresh`, the plan was not empty.
        stdout
        
        
        Terraform used the selected providers to generate the following execution
        plan. Resource actions are indicated with the following symbols:
          ~ update in-place
        
        Terraform will perform the following actions:
        
          # aws_fsx_openzfs_file_system.test will be updated in-place
          ~ resource "aws_fsx_openzfs_file_system" "test" {
                id                              = "fs-02f5f4243890ced4b"
                tags                            = {
                    "Name" = "tf-acc-test-378952906849157547"
                }
                # (17 unchanged attributes hidden)
        
        
              ~ root_volume_configuration {
                    # (4 unchanged attributes hidden)
        
        
                  - user_and_group_quotas {
                      - id                         = 0 -> null
                      - storage_capacity_quota_gib = 0 -> null
                      - type                       = "GROUP" -> null
                    }
                  - user_and_group_quotas {
                      - id                         = 0 -> null
                      - storage_capacity_quota_gib = 0 -> null
                      - type                       = "USER" -> null
                    }
                    # (2 unchanged blocks hidden)
                }
                # (1 unchanged block hidden)
            }
        
        Plan: 0 to add, 1 to change, 0 to destroy.
--- PASS: TestAccFSxOpenzfsFileSystem_disappears (810.46s)
=== CONT  TestAccFSxOpenzfsFileSystem_diskIops
--- FAIL: TestAccFSxOpenzfsFileSystem_rootVolume (865.53s)
--- PASS: TestAccFSxOpenzfsFileSystem_diskIops (789.74s)
FAIL
FAIL	github.com/hashicorp/terraform-provider-aws/internal/service/fsx	8021.959s
FAIL
make: *** [testacc] Error 1

Failures are unrelated to this change and have been noted in other PRs.

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 🚀.

@ewbankkit
Copy link
Contributor

@pwillie Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit 7d95e27 into hashicorp:main Aug 2, 2022
@github-actions github-actions bot added this to the v4.25.0 milestone Aug 2, 2022
@github-actions
Copy link

github-actions bot commented Aug 4, 2022

This functionality has been released in v4.25.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!

@github-actions
Copy link

github-actions bot commented Sep 4, 2022

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 Sep 4, 2022
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.

aws_fsx_openzfs: support for RecordSizeKiB
4 participants