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

Include Appmesh Data Sources #17590

Closed
completenovice opened this issue Feb 12, 2021 · 6 comments · Fixed by #29064
Closed

Include Appmesh Data Sources #17590

completenovice opened this issue Feb 12, 2021 · 6 comments · Fixed by #29064
Labels
enhancement Requests to existing resources that expand the functionality or scope. new-data-source Introduces a new data source. service/appmesh Issues and PRs that pertain to the appmesh service.

Comments

@completenovice
Copy link

completenovice commented Feb 12, 2021

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue 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 issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

At the current time of writing, all AWS App Mesh Services can be defined as resources in Terraform:

  • aws_appmesh_gateway_route
  • aws_appmesh_mesh
  • aws_appmesh_route
  • aws_appmesh_virtual_gateway
  • aws_appmesh_virtual_node
  • aws_appmesh_virtual_router
  • aws_appmesh_virtual_service

However, corresponding data sources for each one can not.

New or Affected Resource(s)

  • data source: aws_appmesh_gateway_route
  • data source: aws_appmesh_mesh
  • data source: aws_appmesh_route
  • data source: aws_appmesh_virtual_gateway
  • data source: aws_appmesh_virtual_node
  • data source: aws_appmesh_virtual_router
  • data source: aws_appmesh_virtual_service

Potential Terraform Configuration

data "aws_appmesh_mesh" "example" {
  name = "example"
}

data "aws_appmesh_virtual_router" "service" {
  name      = "service"
  mesh_name = data.aws_appmesh_mesh.example.name
}

resource "aws_appmesh_route" "service" {
  name                = "my-service-route"
  mesh_name           = data.aws_appmesh_mesh.example.name
  virtual_router_name = data.aws_appmesh_virtual_router.service.name

  spec {
    http_route {
      match {
        prefix = "/example-prefix"
      }

      action {
        weighted_target {
          virtual_node = aws_appmesh_virtual_node.an_example_node.name
          weight       = 100
        }
      }
    }
  }
}

References

none at the time of writing

@completenovice completenovice added the enhancement Requests to existing resources that expand the functionality or scope. label Feb 12, 2021
@ghost ghost added the service/appmesh Issues and PRs that pertain to the appmesh service. label Feb 12, 2021
@github-actions github-actions bot added the needs-triage Waiting for first response or review from a maintainer. label Feb 12, 2021
@ewbankkit
Copy link
Contributor

@completenovice Thanks for raising this issue.
Do you have a priority order for implementation of these data sources?

@ewbankkit ewbankkit added new-data-source Introduces a new data source. and removed needs-triage Waiting for first response or review from a maintainer. labels Feb 12, 2021
@completenovice
Copy link
Author

completenovice commented Feb 12, 2021

Do you have a priority order for implementation of these data sources?

Not particularly, our organisation would honestly benefit from all of them but from a functional point of view I'd guess the more common resources first:

  1. aws_appmesh_mesh
  2. aws_appmesh_virtual_service
  3. aws_appmesh_virtual_node
  4. aws_appmesh_virtual_router
  5. aws_appmesh_virtual_gateway
  6. aws_appmesh_route
  7. aws_appmesh_gateway_route

1 is probably the most useful, then 2-4 would likely vary on a per organisation basis. I would include aws_appmesh_virtual_gateway in that but due to the AWS Service limits don't feel there will be as many of them, but that's an assumptive blanket statement so I'd love input from the community if anyone disagrees with this.

@philnichol
Copy link
Contributor

Hi @completenovice @ewbankkit , I would be interested in implementing this if that's alright with you both? Would probably start just on the Mesh to make sure I'm on the right track.

@philnichol
Copy link
Contributor

Hope you don't mind but I went ahead and raised a PR for the Mesh ^

@philnichol
Copy link
Contributor

Haven't had heaps of time to continue so if anyone else wants to pick up any of these, all yours. Will still try once I have a bit more time.

@github-actions
Copy link

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 have found a problem that seems similar to this, 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 Apr 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Requests to existing resources that expand the functionality or scope. new-data-source Introduces a new data source. service/appmesh Issues and PRs that pertain to the appmesh service.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants