|
|
@@ -260,8 +260,8 @@ Add the following configuration to your existing Maven POM:
|
|
260
|
260
|
<build>
|
|
261
|
261
|
<plugins>
|
|
262
|
262
|
<plugin>
|
|
263
|
|
- <groupId>org.apache.maven.plugins</groupId>
|
|
264
|
|
- <artifactId>maven-shade-plugin</artifactId>
|
|
|
263
|
+ <groupId>org.springframework.zero</groupId>
|
|
|
264
|
+ <artifactId>spring-package-maven-plugin</artifactId>
|
|
265
|
265
|
</plugin>
|
|
266
|
266
|
</plugins>
|
|
267
|
267
|
</build>
|
|
|
@@ -269,13 +269,13 @@ Add the following configuration to your existing Maven POM:
|
|
269
|
269
|
|
|
270
|
270
|
The `start-class` property tells Maven to create a `META-INF/MANIFEST.MF` file with a `Main-Class: hello.Application` entry. This entry enables you to run the jar with `java -jar`.
|
|
271
|
271
|
|
|
272
|
|
-The [Maven Shade plugin][maven-shade-plugin] extracts classes from all jars on the classpath and builds a single "über-jar", which makes it more convenient to execute and transport your service.
|
|
|
272
|
+The [Spring Package maven plugin][spring-package-maven-plugin] collects all the jars on the classpath and builds a single "über-jar", which makes it more convenient to execute and transport your service.
|
|
273
|
273
|
|
|
274
|
274
|
Now run the following to produce a single executable JAR file containing all necessary dependency classes and resources:
|
|
275
|
275
|
|
|
276
|
276
|
mvn package
|
|
277
|
277
|
|
|
278
|
|
-[maven-shade-plugin]: https://maven.apache.org/plugins/maven-shade-plugin
|
|
|
278
|
+[spring-package-maven-plugin]: https://github.com/SpringSource/spring-zero/tree/master/spring-package-maven-plugin
|
|
279
|
279
|
|
|
280
|
280
|
> **Note:** The procedure above will create a runnable JAR. You can also opt to [build a classic WAR file](/guides/gs/convert-jar-to-war/content) instead.
|
|
281
|
281
|
|