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

update AppSync example integration with the latest schema changes #179

Closed
Tracked by #166
dariuszkuc opened this issue Aug 15, 2022 · 5 comments
Closed
Tracked by #166
Labels
type: schema change Change introduces change to the subgraph schemas

Comments

@dariuszkuc
Copy link
Member

See #166 for details.

@dariuszkuc dariuszkuc changed the title update appsync example integration with the latest schema changes update AppSync example integration with the latest schema changes Aug 15, 2022
@dariuszkuc
Copy link
Member Author

@flochaz could you help us out with updating AppSync test integration with the latest schema changes?

@dariuszkuc dariuszkuc added the type: schema change Change introduces change to the subgraph schemas label Aug 15, 2022
@flochaz
Copy link
Contributor

flochaz commented Aug 31, 2022

I can't make @requires to work and looks like it's the same for a many other implementation: The first reason seems to be that the docker hub image used in docker-compose for users service (apollo-federation-implementations/users) does not implement new schema (especially yearsOfEmployment). But even using local implementation (https://github.com/apollographql/apollo-federation-subgraph-compatibility/tree/main/subgraphs/users) I end up with the following error, any suggestion ?

{
  "data": {
    "product": {
      "createdBy": {
        "averageProductsCreatedPerYear": null
      }
    }
  },
  "errors": [
    {
      "message": "invalid content: Missing key `_entities`!",
      "locations": [],
      "path": [
        "product",
        "createdBy"
      ],
      "extensions": {
        "type": "ExecutionInvalidContent",
        "reason": "Missing key `_entities`!"
      }
    }
  ]
}

@dariuszkuc
Copy link
Member Author

👋 Make sure to pull in the latest main and rebuild it locally using npm run setup - apollo-federation-implementations/users does implement the latest schema.

In order to test averageProductsCreatedPerYear make sure to run your queries through the router, since it @requires(fields: "totalProductsCreated yearsOfEmployment") those fields will only be populated if request flows through the router.

@dariuszkuc
Copy link
Member Author

Hello 👋
@flochaz by any chance will you be able to help us out with this?

@flochaz
Copy link
Contributor

flochaz commented Nov 2, 2022

will do this week

dariuszkuc pushed a commit that referenced this issue Nov 3, 2022
…schema changes (#259)

This PR implement latest changes requested by #166 as requested by #179

ftv1 still not supported

Co-authored-by: Florian Chazal <chazalf@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: schema change Change introduces change to the subgraph schemas
Projects
None yet
Development

No branches or pull requests

2 participants