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 _entities query to resolve interfaces to objects in the supergraph #3

Merged
merged 1 commit into from
May 24, 2023

Conversation

nicolerenee
Copy link
Member

This adds the _entities Query which is used in graphql federation by the supergraph to resolve interfaces to concrete object types.

@nicolerenee nicolerenee requested a review from a team as a code owner May 24, 2023 00:07
@nicolerenee
Copy link
Member Author

Ran a version of this PR in compose-stack and it shows the query works that previously failed.

query {
  node(id: "lctnloc-sEdikPSFsjYJjJxssdTkY") {
    ... on Location {
      name
      owner {
        id
        ... on Tenant {
          name
        }
      }
    }
  }
}

Response:

{
  "data": {
    "node": {
      "name": "Just a test location",
      "owner": {
        "id": "tnntten-rXirlFQULBHDw9urtOjya",
        "name": "Development"
      }
    }
  }
}

@nicolerenee nicolerenee merged commit 2f117fa into infratographer:main May 24, 2023
@nicolerenee nicolerenee deleted the entities_endpoint branch May 24, 2023 00:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants