2

My application use annotation processor querydsl:

<dependency>
    <groupId>com.querydsl</groupId>
    <artifactId>querydsl-apt</artifactId>
    <version>${querydsl.version}</version>
    <classifier>hibernate</classifier>
</dependency>

(querydsl-apt generates and compile useful classes)

But I don't want querydsl-apt in my application because I don't need it.

As

<scope>provided</scope>

and

<optional>true</optional>

is ignored by spring-boot-maven-plugin so I defined

<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
    <excludeArtifactIds>querydsl-apt</excludeArtifactIds>

Now querydsl-apt is excluded from repackaing, but:

  • querydsl-codegen
  • codegen
  • ecj

are included in repackaged JAR because their are querydsl-apt dependencies.

Is there a way to exclude entire querydsl-apt & friends, other than very long excludeArtifactIds?

PS. I tried to move querydsl-apt to maven-compiler-plugin dependencies but It does not work well with IntelliJ

michaldo
  • 4,195
  • 1
  • 39
  • 65
  • The spring-bot-maven-plugin team strictly declines that feature. They declined that enhancement several times before, as you see on these pages, https://github.com/spring-projects/spring-boot/issues/3426 or https://github.com/spring-projects/spring-boot/issues/3602 or etc... – Yusuf K. Feb 18 '18 at 15:22

0 Answers0