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 'mesh_owner' and 'resource_owner' attributes in support of cross-account AppMesh mesh sharing #14349

Merged
merged 5 commits into from
Sep 23, 2020

Conversation

ewbankkit
Copy link
Contributor

@ewbankkit ewbankkit commented Jul 26, 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 #12561.

Release note for CHANGELOG:

resource/aws_appmesh_mesh: Add `mesh_owner` and `resource_owner` attributes
resource/aws_appmesh_route: Add `mesh_owner` and `resource_owner` attributes
resource/aws_appmesh_virtual_node: Add `mesh_owner` and `resource_owner` attributes
resource/aws_appmesh_virtual_router: Add `mesh_owner` and `resource_owner` attributes
resource/aws_appmesh_virtual_service: Add `mesh_owner` and `resource_owner` attributes

Output from acceptance testing:

$ make testacc TEST=./aws TESTARGS='-run=TestAccAWSAppmesh'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSAppmesh -timeout 120m
=== RUN   TestAccAWSAppmesh_serial
=== RUN   TestAccAWSAppmesh_serial/VirtualService
=== RUN   TestAccAWSAppmesh_serial/VirtualService/virtualRouter
=== RUN   TestAccAWSAppmesh_serial/VirtualService/tags
=== RUN   TestAccAWSAppmesh_serial/VirtualService/virtualNode
=== RUN   TestAccAWSAppmesh_serial/Mesh
=== RUN   TestAccAWSAppmesh_serial/Mesh/tags
=== RUN   TestAccAWSAppmesh_serial/Mesh/basic
=== RUN   TestAccAWSAppmesh_serial/Mesh/egressFilter
=== RUN   TestAccAWSAppmesh_serial/Route
=== RUN   TestAccAWSAppmesh_serial/Route/httpHeader
=== RUN   TestAccAWSAppmesh_serial/Route/httpRoute
=== RUN   TestAccAWSAppmesh_serial/Route/tcpRoute
=== RUN   TestAccAWSAppmesh_serial/Route/routePriority
=== RUN   TestAccAWSAppmesh_serial/Route/tags
=== RUN   TestAccAWSAppmesh_serial/VirtualNode
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/listenerHealthChecks
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/logging
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/tags
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/basic
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/cloudMapServiceDiscovery
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter/basic
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter/tags
--- PASS: TestAccAWSAppmesh_serial (558.20s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualService (90.68s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/virtualRouter (25.63s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/tags (38.00s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/virtualNode (27.05s)
    --- PASS: TestAccAWSAppmesh_serial/Mesh (57.45s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/tags (24.83s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/basic (10.78s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/egressFilter (21.84s)
    --- PASS: TestAccAWSAppmesh_serial/Route (168.12s)
        --- PASS: TestAccAWSAppmesh_serial/Route/httpHeader (27.25s)
        --- PASS: TestAccAWSAppmesh_serial/Route/httpRoute (37.32s)
        --- PASS: TestAccAWSAppmesh_serial/Route/tcpRoute (37.46s)
        --- PASS: TestAccAWSAppmesh_serial/Route/routePriority (27.64s)
        --- PASS: TestAccAWSAppmesh_serial/Route/tags (38.44s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualNode (186.98s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/listenerHealthChecks (22.96s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/logging (22.66s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/tags (32.08s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/basic (14.31s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/cloudMapServiceDiscovery (94.97s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualRouter (54.97s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/basic (23.49s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/tags (31.49s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	558.268s

@ewbankkit ewbankkit requested a review from a team July 26, 2020 21:33
@ghost ghost added size/S Managed by automation to categorize the size of a PR. documentation Introduces or discusses updates to documentation. service/appmesh Issues and PRs that pertain to the appmesh 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. and removed size/S Managed by automation to categorize the size of a PR. labels Jul 26, 2020
@ewbankkit ewbankkit changed the title Add 'mesh_owner' and 'resource_owner' attributes in support of cross-account AppMesh mesh sharing [WIP] Add 'mesh_owner' and 'resource_owner' attributes in support of cross-account AppMesh mesh sharing Jul 26, 2020
@ghost ghost added size/L Managed by automation to categorize the size of a PR. and removed size/M Managed by automation to categorize the size of a PR. labels Jul 26, 2020
@ewbankkit ewbankkit changed the title [WIP] Add 'mesh_owner' and 'resource_owner' attributes in support of cross-account AppMesh mesh sharing Add 'mesh_owner' and 'resource_owner' attributes in support of cross-account AppMesh mesh sharing Jul 26, 2020
@ewbankkit ewbankkit force-pushed the f-appmesh-mesh-and-resource-owner branch from 6728eaa to b673142 Compare July 26, 2020 22:23
… in support of cross-account mesh sharing.

Acceptance test output:

$ make testacc TEST=./aws TESTARGS='-run=TestAccAWSAppmesh/Route'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSAppmesh/Route -timeout 120m
=== RUN   TestAccAWSAppmesh_serial
=== RUN   TestAccAWSAppmesh_serial/Route
=== RUN   TestAccAWSAppmesh_serial/Route/httpHeader
=== RUN   TestAccAWSAppmesh_serial/Route/httpRoute
=== RUN   TestAccAWSAppmesh_serial/Route/tcpRoute
=== RUN   TestAccAWSAppmesh_serial/Route/routePriority
=== RUN   TestAccAWSAppmesh_serial/Route/tags
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter/basic
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter/tags
--- PASS: TestAccAWSAppmesh_serial (223.84s)
    --- PASS: TestAccAWSAppmesh_serial/Route (169.52s)
        --- PASS: TestAccAWSAppmesh_serial/Route/httpHeader (27.91s)
        --- PASS: TestAccAWSAppmesh_serial/Route/httpRoute (37.76s)
        --- PASS: TestAccAWSAppmesh_serial/Route/tcpRoute (37.54s)
        --- PASS: TestAccAWSAppmesh_serial/Route/routePriority (27.71s)
        --- PASS: TestAccAWSAppmesh_serial/Route/tags (38.61s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualRouter (54.32s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/basic (22.79s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/tags (31.53s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	223.931s
…ributes in support of cross-account mesh sharing.

Acceptance test output:

$ make testacc TEST=./aws TESTARGS='-run=TestAccAWSAppmesh/VirtualNode'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSAppmesh/VirtualNode -timeout 120m
=== RUN   TestAccAWSAppmesh_serial
=== RUN   TestAccAWSAppmesh_serial/VirtualNode
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/logging
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/tags
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/basic
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/cloudMapServiceDiscovery
=== RUN   TestAccAWSAppmesh_serial/VirtualNode/listenerHealthChecks
--- PASS: TestAccAWSAppmesh_serial (189.22s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualNode (189.22s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/logging (23.33s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/tags (33.05s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/basic (14.57s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/cloudMapServiceDiscovery (95.31s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/listenerHealthChecks (22.95s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	189.280s
…ttributes in support of cross-account mesh sharing.

Acceptance test output:

$ make testacc TEST=./aws TESTARGS='-run=TestAccAWSAppmesh/VirtualRouter'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSAppmesh/VirtualRouter -timeout 120m
=== RUN   TestAccAWSAppmesh_serial
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter/basic
=== RUN   TestAccAWSAppmesh_serial/VirtualRouter/tags
--- PASS: TestAccAWSAppmesh_serial (53.74s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualRouter (53.74s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/basic (22.57s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/tags (31.18s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	53.793s
…attributes in support of cross-account mesh sharing.

Acceptance test output:

$ make testacc TEST=./aws TESTARGS='-run=TestAccAWSAppmesh/VirtualService'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSAppmesh/VirtualService -timeout 120m
=== RUN   TestAccAWSAppmesh_serial
=== RUN   TestAccAWSAppmesh_serial/VirtualService
=== RUN   TestAccAWSAppmesh_serial/VirtualService/virtualNode
=== RUN   TestAccAWSAppmesh_serial/VirtualService/virtualRouter
=== RUN   TestAccAWSAppmesh_serial/VirtualService/tags
--- PASS: TestAccAWSAppmesh_serial (90.76s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualService (90.76s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/virtualNode (27.38s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/virtualRouter (25.29s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/tags (38.08s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	90.827s
…in support of cross-account mesh sharing.

Acceptance test output:

$ make testacc TEST=./aws TESTARGS='-run=TestAccAWSAppmesh/Mesh'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSAppmesh/Mesh -timeout 120m
=== RUN   TestAccAWSAppmesh_serial
=== RUN   TestAccAWSAppmesh_serial/Mesh
=== RUN   TestAccAWSAppmesh_serial/Mesh/tags
=== RUN   TestAccAWSAppmesh_serial/Mesh/basic
=== RUN   TestAccAWSAppmesh_serial/Mesh/egressFilter
--- PASS: TestAccAWSAppmesh_serial (58.23s)
    --- PASS: TestAccAWSAppmesh_serial/Mesh (58.23s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/tags (25.62s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/basic (10.61s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/egressFilter (21.99s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	58.329s
@ewbankkit ewbankkit force-pushed the f-appmesh-mesh-and-resource-owner branch from b673142 to eb96e4c Compare September 14, 2020 20:14
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

    --- PASS: TestAccAWSAppmesh_serial/Mesh (228.15s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/basic (40.36s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/egressFilter (88.71s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/tags (99.07s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualNode (492.84s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/basic (47.30s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/cloudMapServiceDiscovery (165.43s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/listenerHealthChecks (82.30s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/logging (80.76s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/tags (117.06s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualRouter (199.21s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/basic (79.95s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/tags (119.26s)

@bflad bflad self-assigned this Sep 23, 2020
@bflad bflad added the enhancement Requests to existing resources that expand the functionality or scope. label Sep 23, 2020
@bflad bflad added this to the v3.8.0 milestone Sep 23, 2020
Copy link
Contributor

@bflad bflad left a comment

Choose a reason for hiding this comment

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

Looks good, thanks @ewbankkit 🚀

Output from acceptance testing (I'll ensure there's a covering bug report for the test failure if there isn't one already):

    --- PASS: TestAccAWSAppmesh_serial/Mesh (71.08s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/basic (12.63s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/egressFilter (28.11s)
        --- PASS: TestAccAWSAppmesh_serial/Mesh/tags (30.34s)
    --- PASS: TestAccAWSAppmesh_serial/Route (142.94s)
        --- PASS: TestAccAWSAppmesh_serial/Route/routePriority (22.44s)
        --- PASS: TestAccAWSAppmesh_serial/Route/tags (34.26s)
        --- PASS: TestAccAWSAppmesh_serial/Route/httpHeader (22.21s)
        --- PASS: TestAccAWSAppmesh_serial/Route/httpRoute (32.62s)
        --- PASS: TestAccAWSAppmesh_serial/Route/tcpRoute (31.41s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualNode (194.55s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/cloudMapServiceDiscovery (107.37s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/listenerHealthChecks (22.52s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/logging (22.32s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/tags (30.41s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualNode/basic (11.93s)
    --- PASS: TestAccAWSAppmesh_serial/VirtualRouter (54.33s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/basic (21.91s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualRouter/tags (32.42s)
    --- FAIL: TestAccAWSAppmesh_serial/VirtualService (60.19s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/virtualRouter (21.26s)
        --- PASS: TestAccAWSAppmesh_serial/VirtualService/tags (32.76s)
        --- FAIL: TestAccAWSAppmesh_serial/VirtualService/virtualNode (6.17s)

TestAccAWSAppmesh_serial/VirtualService/virtualNode: resource_aws_appmesh_virtual_service_test.go:89: Step 1/3 error: terraform failed: exit status 1
stderr:
Error: Provider produced inconsistent result after apply
When applying changes to aws_appmesh_virtual_service.test, provider
"registry.terraform.io/-/aws" produced an unexpected new value for was
present, but now absent.
This is a bug in the provider, which should be reported in the provider's own
issue tracker.

@bflad bflad merged commit 9efb631 into hashicorp:master Sep 23, 2020
@ewbankkit ewbankkit deleted the f-appmesh-mesh-and-resource-owner branch September 23, 2020 18:56
bflad added a commit that referenced this pull request Sep 23, 2020
@bflad
Copy link
Contributor

bflad commented Sep 23, 2020

Bug report already present: #15084

@ewbankkit
Copy link
Contributor Author

OK, I'll address that (it never happens for me 😄).

@ghost
Copy link

ghost commented Sep 24, 2020

This has been released in version 3.8.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 Oct 24, 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 Oct 24, 2020
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/appmesh Issues and PRs that pertain to the appmesh service. size/L 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 App Mesh adds support to connect services deployed in multiple AWS accounts into a shared mesh
3 participants