There are two ways of integrating springboot.
1 Direct Parent Project point to Springboot
<parent><groupId>org.springframework.boot</groupId><artifactId> Spring-boot-starter-parent</artifactid><version>2.0.3.release</version></parent>
This is handy, and the default jar is complete.
2 Using Spring-boot-dependencie
<!--Springcloud--><dependencymanagement><dependencies><dependency><groupid> org.springframework.boot</groupid><artifactid>spring-boot-dependencies</artifactid>< version>2.0.3.release</version><type>pom</type><scope>import</scope></ Dependency></dependencies></dependencymanagement>
This default-typed jar package is incomplete. cannot be run directly.
Add the following configuration to it.
<build> <plugins> <plugin> <groupid>org.springframework.boot</groupid > <artifactId>spring-boot-maven-plugin</artifactId> <configuration> < mainclass>com.sbl.pay.subaccount.subaccountserverrunner</mainclass> </configuration> <executions> <execution> <goals> <goal>repackage</goal> </ goals> </execution> </executions> </plugin> </plugins></ Build>
The second kind of trouble, but we can use our own parent class.
Spring-boot-dependencies jar Incomplete problem