smallrye-graphql icon indicating copy to clipboard operation
smallrye-graphql copied to clipboard

Inconsistent enablement of Federation

Open t1 opened this issue 2 years ago • 4 comments

In 1.9.1, enabling Federation is not automatic any more and is only possible with a system property

t1 avatar Jan 08 '23 11:01 t1

No, it's automatic, at least it will be when quarkus updates to SmallRye GraphQL 1.9.1/2.0.1 via this PR: https://github.com/quarkusio/quarkus/pull/30227/files (see SmallRyeGraphQLProcessor#activateFederation)

For WildFly, I am going to do something similar.

jmartisk avatar Jan 09 '23 10:01 jmartisk

I want to make the automatic enablement handled by the runtime, not directly in SmallRye, because different runtimes have different configuration mechanisms - for example Quarkus has its own configuration property for enabling federation (quarkus.smallrye-graphql.federation.enabled), and I want Quarkus to decide based on THAT property, not based only on smallrye.graphql.federation.enabled, so the plan is that Quarkus will set the value of smallrye.graphql.federation.enabled by itself, and then the SchemaBuilder will be controlled by that value.

jmartisk avatar Jan 09 '23 10:01 jmartisk

Okay, I see... but wouldn't it make more sense to implement it once? Have you seen #1690

t1 avatar Jan 09 '23 21:01 t1

I've commented on the PR, I think it might make sense, but it would need some changes, let's move the discussion there

jmartisk avatar Jan 10 '23 08:01 jmartisk