You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create two GQL servers, both containing the same method, returning their own results. For example:
ServiceA with method Suggest, returning ProcessingResult with values a
ServiceB with method Suggest, returning ProcessingResult with values b
Then create Fusion gateway, produce FGP file, merging those two services into supergraph on the gateway. dotnet fusion compose -p .\Gateway\gateway.fgp -s .\out\serviceA.fsp dotnet fusion compose -p .\Gateway\gateway.fgp -s .\out\serviceB.fsp
What is expected?
Gateway will stitch two services into a single call, distributing the queries in parallel to their respective resolvers, passing all parameters down the stream.
When called with inlined arguments, it works correctly, getting the results. The problem happens when you use query variables:
query Suggest($limit: Int, $query: String!) {
suggest(limit: $limit, query: $query) {
a
b
}
}
This will produce parallel query to both services, but providing variables only to the first service. Second service is completely missing forwardedVariables and crashing on missing input:
Product
Hot Chocolate
Version
15.1.1
Link to minimal reproduction
https://www.dropbox.com/scl/fi/av26h4zc1x27kyejsoapc/GqlGatewayPoC.rar?rlkey=03945jt4rgwgfeqcgnbn4pxpr&st=cc7ozct4&dl=0
Steps to reproduce
Create two GQL servers, both containing the same method, returning their own results. For example:
Suggest
, returningProcessingResult
with valuesa
Suggest
, returningProcessingResult
with valuesb
Then create Fusion gateway, produce FGP file, merging those two services into supergraph on the gateway.
dotnet fusion compose -p .\Gateway\gateway.fgp -s .\out\serviceA.fsp
dotnet fusion compose -p .\Gateway\gateway.fgp -s .\out\serviceB.fsp
What is expected?
Gateway will stitch two services into a single call, distributing the queries in parallel to their respective resolvers, passing all parameters down the stream.
What is actually happening?
fusion.graphql
correctly contains stitched methodsuggest
, returning mergedProcessingResult
When called with inlined arguments, it works correctly, getting the results. The problem happens when you use query variables:
This will produce parallel query to both services, but providing variables only to the first service. Second service is completely missing
forwardedVariables
and crashing on missing input:Relevant log output
Additional context
No response
The text was updated successfully, but these errors were encountered: