Skip to content

[Fusion] Add support for merging @specifiedBy directives#9307

Merged
glen-84 merged 2 commits intomainfrom
gai/merge-specified-by
Mar 5, 2026
Merged

[Fusion] Add support for merging @specifiedBy directives#9307
glen-84 merged 2 commits intomainfrom
gai/merge-specified-by

Conversation

@glen-84
Copy link
Copy Markdown
Member

@glen-84 glen-84 commented Mar 5, 2026

Summary of the changes (Less than 80 chars)

  • [Fusion] Add support for merging @specifiedBy directives.

Copilot AI review requested due to automatic review settings March 5, 2026 10:05
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 5, 2026

Fusion Gateway Performance Results

Progress: 0/6 benchmarks completed — this report updates as each job finishes.

Simple Composite Query

Req/s Err%
Constant 1 (50 VUs) pending pending
Ramping 1 (0-500-0 VUs) pending pending
Response Times
Min Med Avg P90 P95 Max
Constant 1 pending pending pending pending pending pending
Ramping 1 pending pending pending pending pending pending

Deep Recursion Query

Req/s Err%
Constant 1 (50 VUs) pending pending
Ramping 1 (0-500-0 VUs) pending pending
Response Times
Min Med Avg P90 P95 Max
Constant 1 pending pending pending pending pending pending
Ramping 1 pending pending pending pending pending pending

Variable Batching Throughput

Req/s Err%
Constant 1 (50 VUs) pending pending
Ramping 1 (0-500-0 VUs) pending pending
Response Times
Min Med Avg P90 P95 Max
Constant 1 pending pending pending pending pending pending
Ramping 1 pending pending pending pending pending pending

Runner 1 = benchmarking-1

Run 22712753887 • Commit 72fc799 • Thu, 05 Mar 2026 10:05:55 GMT

@glen-84 glen-84 merged commit 23213bc into main Mar 5, 2026
128 of 134 checks passed
@glen-84 glen-84 deleted the gai/merge-specified-by branch March 5, 2026 10:12
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds Fusion composition support for carrying @specifiedBy(url: ...) through scalar merging so the composed schema preserves scalar specification URLs.

Changes:

  • Introduces a SpecifiedByDirectiveMerger (+ parsing helper) and wires it into scalar type merging.
  • Fixes CompositeSchemaBuilder to correctly read the specifiedBy directive argument value node.
  • Updates composition resources and tests/snapshots to validate the merged output.

Reviewed changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/HotChocolate/Mutable/src/Types.Mutable/BuiltIns/SpecifiedByMutableDirectiveDefinition.cs Adds a schema-based factory for the mutable @specifiedBy directive definition.
src/HotChocolate/Mutable/src/Types.Mutable/BuiltIns/OneOfMutableDirectiveDefinition.cs Minor signature tweak to avoid unused parameter warnings.
src/HotChocolate/Fusion-vnext/test/Fusion.Composition.Tests/SourceSchemaMerger.Scalar.Tests.cs Adds a snapshot test for merging scalars with @specifiedBy.
src/HotChocolate/Fusion-vnext/src/Fusion.Execution.Types/Completion/CompositeSchemaBuilder.cs Fixes extraction of the url argument from @specifiedBy.
src/HotChocolate/Fusion-vnext/src/Fusion.Composition/WellKnownDirectiveNames.cs Adds SpecifiedBy constant.
src/HotChocolate/Fusion-vnext/src/Fusion.Composition/WellKnownArgumentNames.cs Adds Url constant.
src/HotChocolate/Fusion-vnext/src/Fusion.Composition/SourceSchemaMerger.cs Registers and applies the SpecifiedByDirectiveMerger during scalar merging.
src/HotChocolate/Fusion-vnext/src/Fusion.Composition/Properties/CompositionResources.resx Adds localized error message for invalid url argument.
src/HotChocolate/Fusion-vnext/src/Fusion.Composition/Properties/CompositionResources.Designer.cs Designer update for new resource entry.
src/HotChocolate/Fusion-vnext/src/Fusion.Composition/Directives/SpecifiedByDirective.cs Adds typed parsing for @specifiedBy(url: String!).
src/HotChocolate/Fusion-vnext/src/Fusion.Composition/DirectiveMergers/SpecifiedByDirectiveMerger.cs Implements merging of @specifiedBy onto merged scalar types.
src/HotChocolate/Adapters/test/Adapters.OpenApi.Tests/OpenApi/snapshots/OpenApiIntegrationTestBase.OpenApi_Includes_Initial_Routes_NET10_0_Fusion.json Snapshot update reflecting changed OpenAPI output.
Files not reviewed (1)
  • src/HotChocolate/Fusion-vnext/src/Fusion.Composition/Properties/CompositionResources.Designer.cs: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants