Description
Background & Description
First of all, thank you all for the great lib! It is great to see such a mature Schema First library for GraphQL in Java, I'm really enjoying working with it.
I'm trying to use graphql-java-tools
with federation-jvm and overall it works great.
However, I'm facing one issue where we have a service which defines its own query, but also extends one entity to add fields to it. Like the schema here.
The root of the issue is that graphql-java-tools
ignores the User
type because it is "orphan" as it is not referenced by any other type in the schema. However, this is a completely valid scenario, and would be great if graphql-java-tools
could support it.
How to reproduce
I've created a simple project reproducing the issue: https://github.com/danilo-barboza/apollo-federation-java-tools/
Just clone it and run
./gradlew test
Possible solutions
I've also hacked hard and created a draft Pull Request to show a possible way to fix it: #441. The main idea is to make sure we add types that have the @extends
annotation.