Skip to content

[Fusion] Remove empty types after excluding all members via tagging#9359

Merged
glen-84 merged 3 commits intomainfrom
gai/tagging-remove-empty-types
Mar 11, 2026
Merged

[Fusion] Remove empty types after excluding all members via tagging#9359
glen-84 merged 3 commits intomainfrom
gai/tagging-remove-empty-types

Conversation

@glen-84
Copy link
Member

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

Summary of the changes (Less than 80 chars)

  • [Fusion] Remove empty types after excluding all members via tagging.

Copilot AI review requested due to automatic review settings March 11, 2026 14:41
@github-actions
Copy link
Contributor

github-actions bot commented Mar 11, 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 22960293478 • Commit 0f432a1 • Wed, 11 Mar 2026 15:25:52 GMT

Copy link
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

This PR updates Fusion source schema preprocessing so that when ExcludeByTag removes all members of a type, the now-empty type is removed from the schema (including root operation types).

Changes:

  • Remove object/interface types from schema.Types if all fields were excluded by tag.
  • Remove input object types if all input fields were excluded by tag, and enum types if all values were excluded by tag.
  • Clear schema.QueryType / MutationType / SubscriptionType when they become empty after exclusion; add a regression test for this behavior.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/HotChocolate/Fusion/src/Fusion.Composition/SourceSchemaPreprocessor.cs Removes empty types after tag-based exclusion and clears empty root operation types.
src/HotChocolate/Fusion/test/Fusion.Composition.Tests/SourceSchemaPreprocessorTests.cs Adds a test asserting empty root types and other empty types are removed after exclusion.

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

Copy link
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

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.


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

Copy link
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

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


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

@glen-84 glen-84 merged commit 885abdd into main Mar 11, 2026
128 of 134 checks passed
@glen-84 glen-84 deleted the gai/tagging-remove-empty-types branch March 11, 2026 15:33
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