Can spring-boot-maven-plugin provide includeGroupIds just like excludeGroupIds?
Comment From: snicoll
Closing in favour of PR #12813
Comment From: vision-ken
Thanks!
Comment From: CraKeyBoy
I need this feature also. When this feature will be released? thx.
Comment From: snicoll
@javmain one of the label states declined with more context in the related PR.
Comment From: vision-ken
@javmain
You can fork and customize your own spring-boot-maven-plugin.
Comment From: CraKeyBoy
thx @vision-ken and @snicoll It's a nice feature, I need a thin jar for docker. I want to exclude some third-party libs. Thus, I can get a jar to only contain classes and other local model jars. Then we can use ''maven-dependency-plugin" copy all third-party in another folder, use it "excludeGroupIds" feather. If we build a Docker image, we can let docker cache all of the third-party libs. It is very convenient for me.
Comment From: vision-ken
@javmain @snicoll
I did this just like you, divide a Fat jar to several parts in order to split a docker image into multi layers is very necessary because it can help transmission efficiency of publishing a docker image.
Comment From: wangliang181230
@vision-ken @CraKeyBoy @Seriels
Please try the temporary maven-plugin I developed: icu.easyj.maven.plugins:easyj-maven-plugin:1.0.9 spring-boot-extend
https://github.com/easyj-projects/easyj-maven-plugin/blob/develop/src/main/java/icu/easyj/maven/plugin/mojo/springboot/SpringBootExtendMojo.java
<build>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>${spring-boot.version}</version>
</plugin>
<plugin>
<groupId>icu.easyj.maven.plugins</groupId>
<artifactId>easyj-maven-plugin</artifactId>
<version>1.0.9</version>
<executions>
<execution>
<id>spring-boot-extend</id>
<phase>prepare-package</phase>
<goals>
<goal>spring-boot-extend</goal>
</goals>
<configuration>
<!-- Same as `excludeGroupIds` of `maven-dependency-plugin` -->
<includeGroupIds>groupA, groupB, groupC</includeGroupIds>
</configuration>
</execution>
</executions>
</plugin>
</build>
Comment From: wangliang181230
Upgrade easyj-maven-plugin to v1.0.9.
The maven-dependency-plugin:copy-dependencies is no longer needed.