From 53e492d117001322add15deed5845db2bd44a5cd Mon Sep 17 00:00:00 2001 From: Sylwester Lachiewicz Date: Wed, 5 Aug 2026 22:59:14 +0200 Subject: [PATCH] [MINOR] Run delombok only in the release profile The delombok output has exactly one consumer: maven-javadoc-plugin in the release profile, which reads ${delombok.output.dir} so that the lombok-generated builders, getters and equals/hashCode appear in the javadoc jar. There is no section and the website build is Docusaurus, so nothing else looks at it. The execution itself sat in bound to generate-sources, so it ran on every build - every CI run and every local install - to produce a directory that only a release ever reads. Move it next to its consumer. This keeps the javadoc jars intact, so it is not a repeat of #728, which removed the plugin outright and left the javadoc jar empty until #854 restored it. Verified below. It also takes lombok-maven-plugin off the path of ordinary builds. Its last release is 1.18.20.0 (April 2021) and it cannot delombok on JDK 21+, so today every contributor pays for a plugin whose output they never use. Note this removes one of three independent JDK 21 blockers - spotless (google-java-format 1.10.0 < 1.17.0) and a javac-21 inference failure in xtable-core remain, so this alone does not make the build JDK 21 ready. Verified on Temurin 11 with the project's wrapper: - ./mvnw install -DskipTests -> 0 delombok executions, BUILD SUCCESS - ./mvnw package -DdeployArtifacts=true -> 10 delombok executions, 6 javadoc jars, and InternalTable.html documents builder(), the generated InternalTableBuilder class, the getters and equals/hashCode --- pom.xml | 46 +++++++++++++++++++++++++++------------------- 1 file changed, 27 insertions(+), 19 deletions(-) diff --git a/pom.xml b/pom.xml index 630a9fef1..edcb5dce2 100644 --- a/pom.xml +++ b/pom.xml @@ -719,25 +719,6 @@ - - org.projectlombok - lombok-maven-plugin - ${lombok-maven-plugin.version} - - ${project.basedir}/src/main/java - false - ${delombok.output.dir} - UTF-8 - - - - generate-sources - - delombok - - - - org.apache.maven.plugins maven-enforcer-plugin @@ -1078,6 +1059,33 @@ + + + org.projectlombok + lombok-maven-plugin + ${lombok-maven-plugin.version} + + ${project.basedir}/src/main/java + false + ${delombok.output.dir} + UTF-8 + + + + generate-sources + + delombok + + + + org.apache.maven.plugins maven-source-plugin