apollographql / apollo-federation-subgraph-compatibility

A repo to test subgraph libraries compatibility with the Apollo Federation Specification
https://www.apollographql.com/docs/federation/building-supergraphs/supported-subgraphs/
MIT License
77 stars 57 forks source link

graphql-go Federation support #74

Open hwillson opened 2 years ago

hwillson commented 2 years ago

There is an interesting discussion about adding Federation support to graphql-go here: https://github.com/graphql-go/graphql/issues/492

graphql-go is intended to be more of a graphql-js clone, which means Federation support doesn't necessarily belong in the library itself, but it looks like there are API changes that could be made to graphql-go to make it easier to use with Federation. The above linked to issue dives into this a bit (https://github.com/graphql-go/graphql/issues/492#issuecomment-553707207), but we'll need to validate this and see if any other changes are needed (see also https://github.com/graphql-go/graphql/issues/541). If we can help get these changes in place, we can then think about potentially creating a Go based Federation helper library, like we've done with @apollo/subgraph (JS/Node) and federation-jvm (Java/JVM).

codebdy commented 2 years ago

It is a good idea, I need Federation support

hwillson commented 2 years ago

We're going to prep a PR to add Federation enabling changes in graphql-go.

dariuszkuc commented 1 year ago

POC is available at dariuszkuc/graphql@v0.9.0-federation.

Example implementation of the testing schema used in this repo: https://github.com/dariuszkuc/graphql/tree/federation/examples/federation (ftv1 tracing is not supported, all other tests are 🟢)

graphql-go/graphql PRs:

Once above PRs are merged we can create and publish separate federation module.

hwillson commented 1 year ago

While we wait for feedback (and 🤞 our graphql-go PR's to be merged), we're going to go ahead and add graphql-go tests to this repo, pointing to the above fork for now.

hwillson commented 1 year ago

Re-opening this issue to use as our tracking issue for getting @dariuszkuc's awesome graphql-go + Federation work hopefully merged into the project.