[DO NOT MERGE] Schema traverser perf by andimarek · Pull Request #4232 · graphql-java/graphql-java · GitHub
Skip to content

[DO NOT MERGE] Schema traverser perf #4232

Draft
andimarek wants to merge 2 commits intomasterfrom
schema-traverser-perf
Draft

[DO NOT MERGE] Schema traverser perf #4232
andimarek wants to merge 2 commits intomasterfrom
schema-traverser-perf

Conversation

@andimarek
Copy link
Copy Markdown
Member

No description provided.

andimarek-atlassian and others added 2 commits January 29, 2026 20:26
Adds benchmark to compare built-in SchemaTraverser.depthFirstFullSchema()
with manual recursive traversal using direct iteration over
schema.getAllTypesAsList().

Results show manual traversal is ~13x faster for steady-state and ~3.5x
faster for cold-start, while counting the same 5030 schema elements.

- SchemaTraversalBenchmark: JMH benchmark with both approaches
- SchemaTraversalVerificationTest: Verifies both count identical elements
- build.gradle: Add JMH include filter configuration

Co-authored-by: Cursor <cursoragent@cursor.com>
Enable passing profilers via -Pjmh.profilers (e.g., 'gc' for memory profiling).

Co-authored-by: Cursor <cursoragent@cursor.com>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jan 29, 2026

@andimarek andimarek changed the title Schema traverser perf [DO NOT MERGE] Schema traverser perf Jan 29, 2026
@github-actions
Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot added the Stale label Mar 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants