diff --git a/reference/html/spring-cloud-function.html b/reference/html/spring-cloud-function.html index b289edd37..84c5f87fd 100644 --- a/reference/html/spring-cloud-function.html +++ b/reference/html/spring-cloud-function.html @@ -2016,7 +2016,24 @@ public class CloudFunctionMain { You can get on the whitelist to try it out.

-

First, add the Shade Plugin configuration to generate a fat jar when you run the mvn package command.

+

To deploy to Google Cloud Function, you need to produce a fat jar using the Shade plugin, rather than the Spring Boot plugin.

+
+
+

First, if you already have the Spring Boot plugin in your pom.xml, remove it:

+
+
+
+
<!-- Remove this block by deleting or commenting it out -->
+<!--
+<plugin>
+    <groupId>org.springframework.boot</groupId>
+    <artifactId>spring-boot-maven-plugin</artifactId>
+</plugin>
+-->
+
+
+
+

Then, add the Shade Plugin configuration to generate a fat jar when you run the mvn package command.

@@ -2031,7 +2048,7 @@ You can get on the + + + + + +
+ + +If both Spring Boot plugin and Shade plugin are present, Shade plugin may be shading a Spring Boot produced JAR, resulting in a Fat JAR that’s unusable in Google Cloud Function. Don’t forget to remove the Spring Boot plugin! +
+

Package the application.

@@ -2063,7 +2092,7 @@ You can get on the
-

You should see the fat jar in deploy directory.

+

You should see the fat jar in target/deploy directory.

Make sure that you have the Cloud SDK CLI installed.

@@ -2077,7 +2106,7 @@ You can get on the