How to generate federation v2 compatible schemas via gradle in 6.x ? #1644
-
I am getting the following error when using federation v2 annotations during my gradle build:
I had no luck finding a property to set the opt in flag for the gradle plugin action. How do I allow the Gradle action to generate a federation v2 schema? I checked all actions and think its an oversight as its settable e.g. in the Spring server in 6.x. I know the default will change in 7.x, but that version is still in alpha. Having the ability to override the opt in for the gradle task would be an improvement regardless. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hello 👋 Federation v2 is supported with an opt-in mechanism in Plugins rely on a service loader mechanism to generate SDL based on the provided hooks (defaults to non-federated schema). Service loader mechanism is pretty flexible as it allows us to dynamically load hooks at runtime based on the available classpath. On the other hand it is also non-configurable as we cannot pass arguments in some generic fashion (as we don't know what will be loaded) - that's why don't have a plugin configuration option to distinguish between v1 and v2 and we use the same default behavior as the schema generator. Since Fed v2 is an opt-in behavior (in Thanks, |
Beta Was this translation helpful? Give feedback.
Hello 👋
Federation v2 is supported with an opt-in mechanism in
graphql-kotlin
v6 (note: we will be releasing v6.3.5 that contains a fed bug fix soon) and it defaults to v1 if flag is not specified.Plugins rely on a service loader mechanism to generate SDL based on the provided hooks (defaults to non-federated schema). Service loader mechanism is pretty flexible as it allows us to dynamically load hooks at runtime based on the available classpath. On the other hand it is also non-configurable as we cannot pass arguments in some generic fashion (as we don't know what will be loaded) - that's why don't have a plugin configuration option to distinguish between v1 and v2 and we use the same d…