Skip to content

GROOVY-12096: Replace qdox with javaparser#2632

Merged
daniellansun merged 1 commit into
masterfrom
GROOVY-12096
Jun 27, 2026
Merged

GROOVY-12096: Replace qdox with javaparser#2632
daniellansun merged 1 commit into
masterfrom
GROOVY-12096

Conversation

@daniellansun

Copy link
Copy Markdown
Contributor

@github-actions

github-actions Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

JMH summary — classic (commit 0630a98)

Speedup vs trailing 90-day baseline on gh-pages. Higher = faster.
1.00 = in line with history. Per-benchmark ratio, geomean within group.
Time-per-op units inverted so direction is consistent.

Group Speedup n
bench 0.943 × 26
core 1.026 × 77
grails 1.095 × 80

Baseline: dev/bench/jmh/<part>/classic/data.js on gh-pages, trailing 90 days. Daily dashboard · Per-suite raw data

@codecov-commenter

codecov-commenter commented Jun 26, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 95.16129% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 68.5430%. Comparing base (568bf98) to head (bce2962).

Files with missing lines Patch % Lines
.../groovy/docgenerator/JavaExtensionSourceSet.groovy 97.1698% 0 Missing and 6 partials ⚠️
...che/groovy/docgenerator/MockSourceGenerator.groovy 83.3333% 0 Missing and 6 partials ⚠️
Additional details and impacted files

Impacted file tree graph

@@                Coverage Diff                 @@
##               master      #2632        +/-   ##
==================================================
+ Coverage     68.5180%   68.5430%   +0.0249%     
- Complexity      33597      33710       +113     
==================================================
  Files            1519       1523         +4     
  Lines          127384     127876       +492     
  Branches        23123      23232       +109     
==================================================
+ Hits            87281      87650       +369     
- Misses          32355      32458       +103     
- Partials         7748       7768        +20     
Files with missing lines Coverage Δ
.../groovy/docgenerator/JavaExtensionSourceSet.groovy 97.1698% <97.1698%> (ø)
...che/groovy/docgenerator/MockSourceGenerator.groovy 93.0636% <83.3333%> (ø)

... and 11 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.50.

Benchmark suite Current: bce2962 Previous: 568bf98 Ratio
org.apache.groovy.bench.dispatch.CallsiteBench.dispatch_1_monomorphic_java 35560.53682313535 ops/ms 23028.17975286173 ops/ms 1.54
org.apache.groovy.bench.StaticMethodCallIndyColdBench.staticSum_java ( {"n":"2000"} ) 52.802937500000006 us/op 35.0502125 us/op 1.51
org.apache.groovy.bench.StaticMethodCallIndyColdBench.staticSum_java ( {"n":"20000"} ) 434.8573875 us/op 274.46545000000015 us/op 1.58

This comment was automatically generated by workflow using github-action-benchmark.

@github-actions

github-actions Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

JMH summary — indy (commit 0630a98)

Speedup vs trailing 90-day baseline on gh-pages. Higher = faster.
1.00 = in line with history. Per-benchmark ratio, geomean within group.
Time-per-op units inverted so direction is consistent.

Group Speedup n
bench 1.003 × 26
core 4.000 × 77
grails 2.314 × 80

Baseline: dev/bench/jmh/<part>/indy/data.js on gh-pages, trailing 90 days. Daily dashboard · Per-suite raw data

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 implements GROOVY-12096 by replacing QDox-based Java source parsing with JavaParser in Groovy’s doc generation and stub-generator test infrastructure, updating dependencies and verification metadata accordingly.

Changes:

  • Swap Groovy docgenerator’s mock-source generation from QDox to a new JavaParser-backed source model (JavaExtensionSourceSet), with new/updated tests.
  • Replace stub-generator test parsing helpers (QDox builder/category) with JavaParser-backed equivalents (JavaParserSourceSet, JavaParserCategory).
  • Remove QDox dependency/version references and adjust Gradle dependencies + dependency verification metadata.

Reviewed changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
versions.properties Drops the qdox version entry (dependency no longer used).
subprojects/groovy-docgenerator/build.gradle Replaces QDox dependency with javaparser-core.
subprojects/groovy-docgenerator/src/main/groovy/org/apache/groovy/docgenerator/MockSourceGenerator.groovy Migrates mock-source generation to consume JavaParser-backed method/type models.
subprojects/groovy-docgenerator/src/main/groovy/org/apache/groovy/docgenerator/JavaExtensionSourceSet.groovy Adds JavaParser-backed parsing/type/javadoc model for extension sources.
subprojects/groovy-docgenerator/src/test/groovy/org/apache/groovy/docgenerator/MockSourceGeneratorTest.groovy Adds coverage validating mock generation output based on JavaParser model and CLI paths.
subprojects/groovy-docgenerator/src/test/groovy/org/apache/groovy/docgenerator/JavaExtensionSourceSetTest.groovy Adds focused tests for method/type rendering and javadoc parsing.
src/test/groovy/org/codehaus/groovy/tools/stubgenerator/StubTestCase.groovy Switches stub test harness from QDox to JavaParser-backed parsing.
src/test/groovy/org/codehaus/groovy/tools/stubgenerator/QDoxCategory.groovy Removes QDox-specific assertion category (no longer applicable).
src/test/groovy/org/codehaus/groovy/tools/stubgenerator/JavaParserSourceSet.groovy Adds JavaParser-backed parsed-class/method views for stub assertions.
src/test/groovy/org/codehaus/groovy/tools/stubgenerator/JavaParserCategory.groovy Adds category helpers for concise assertions against JavaParser-backed views.
gradle/verification-metadata.xml Removes verification entries for the removed QDox dependency.
build.gradle Replaces QDox test dependency with javaparser-core and removes QDox from tools deps.

@testlens-app

testlens-app Bot commented Jun 27, 2026

Copy link
Copy Markdown

✅ All tests passed ✅

⚠️ TestLens detected flakiness ⚠️

Test Summary

Build and test / lts (17, macos-latest) > :test

Test Runs
GenericsSTCTest > testReturnTypeInferenceWithMethodGenerics18() ❌ ✅
GenericsSTCTest > testReturnTypeInferenceWithMethodGenerics18a() ❌ ✅
GenericsStaticCompileTest > testReturnTypeInferenceWithMethodGenerics18() ❌ ✅
GenericsStaticCompileTest > testReturnTypeInferenceWithMethodGenerics18a() ❌ ✅

🏷️ Commit: bce2962
▶️ Tests: 104612 executed
⚪️ Checks: 62/62 completed


Learn more about TestLens at testlens.app.

@sonarqubecloud

Copy link
Copy Markdown

@daniellansun daniellansun merged commit 2f7cf6d into master Jun 27, 2026
77 of 79 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants