Add comprehensive JavaDoc to plugin classes missing documentation.#1672
Add comprehensive JavaDoc to plugin classes missing documentation.#1672
Conversation
Added class-level JavaDoc to 9 plugin classes to improve developer experience and API documentation: - LombokPlugin: Lombok integration and delombok task generation - MkDocsPlugin: MkDocs documentation build tasks - PluginVersionsPlugin: Automatic plugin version registration for settings - OptionalPlugin: Optional dependency configuration support - WarPlugin: Composite WAR plugin with overlays and class archiving - WarArchiveClassesPlugin: Separate class JAR for skinny WARs - WarAttachClassesPlugin: Attach classes as publishable artifact - SassBasePlugin: Sass/SCSS compilation base configuration - SassWarPlugin: Sass integration for WAR projects Each JavaDoc includes: - Clear description of plugin purpose - What configurations/tasks are provided - Usage examples where relevant
|
Automated status check: All CI checks are passing and there are no merge conflicts. This PR is ready for manual review and merge. |
Frisch12
left a comment
There was a problem hiding this comment.
Code Review — Automated
Summary
Reviewed the JavaDoc additions across all 9 changed files. The documentation is generally well-written and helpful. However, there are a few accuracy issues that could mislead readers.
Should fix before merge — OptionalPlugin extension direction is backwards
maven-plugin/.../OptionalPlugin.java, class-level JavaDoc
The doc says the optional configuration "extends compileOnly, testCompileOnly, and testRuntimeOnly." This is backwards. Looking at the code (lines 26–33), compileOnly, testCompileOnly, and testRuntimeOnly extend from optional — not the other way around. This means anything declared optional is available at compile time and for tests, but excluded from runtime and published metadata.
Suggested fix:
* Creates an {@code optional} configuration. The {@code compileOnly},
* {@code testCompileOnly}, and {@code testRuntimeOnly} configurations all
* extend from it, so anything declared as {@code optional} is available at
* compile time and for tests but is excluded from the runtime classpath
* and from published dependency metadata.Should fix before merge — SassBasePlugin source map URL description is inverted
embedded-sass-plugin/.../SassBasePlugin.java, line 14–15
The bullet says "Source map URL inclusion" but the actual property is omitSourceMapUrl — a flag to omit the URL. The doc should say "Whether to omit the source map URL from compiled output" to match the actual behavior.
Should fix before merge — LombokPlugin misleadingly claims SonarQube integration
lombok-plugin/.../LombokPlugin.java, line 31–45
The JavaDoc says the plugin "configures integration with Mapstruct, SpotBugs, and SonarQube." The SonarQube code path actually adds SpotBugs annotations (not SonarQube-specific functionality) when the org.sonarqube plugin is present. The doc should say the plugin adds SpotBugs annotations when either com.github.spotbugs or org.sonarqube is detected.
Suggestion — Inconsistent @author tag
lombok-plugin/.../LombokPlugin.java, line 43
Only LombokPlugin has an @author tag; the other 8 files do not. For consistency, either add it everywhere or remove it here.
Suggestion — WarPlugin should use @link for Gradle's WarPlugin
maven-plugin/.../WarPlugin.java, line 10
The other three entries in the list use {@link ...} references, but Gradle's built-in WarPlugin is referenced as plain {@code war}. Using {@link org.gradle.api.plugins.WarPlugin} would be consistent.
Result
The JavaDoc additions are a welcome improvement. Three accuracy issues should be fixed before merging: the OptionalPlugin extension direction, the SassBasePlugin source map description, and the LombokPlugin SonarQube claim. The other suggestions are optional improvements.
- OptionalPlugin: fix extension direction description (compileOnly etc. extend FROM optional, not the other way around) - SassBasePlugin: fix source map URL description (property omits URL, not includes it) - LombokPlugin: fix SonarQube claim (plugin adds SpotBugs annotations when spotbugs or sonarqube plugin is present, not SonarQube integration) - LombokPlugin: remove inconsistent @author tag - WarPlugin: use @link for Gradle's WarPlugin for consistency
|
Automated maintenance summary: Fixed JavaDoc accuracy issues:
CI pipelines triggered and running. Waiting for results. |
Added class-level JavaDoc to 9 plugin classes to improve developer experience and API documentation:
Each JavaDoc includes: