diff --git a/articles/flow/production/production-build.adoc b/articles/flow/production/production-build.adoc index 1b700ebfcb..23fb47ba30 100644 --- a/articles/flow/production/production-build.adoc +++ b/articles/flow/production/production-build.adoc @@ -165,6 +165,11 @@ For other applications, e.g., Jakarta EE or plain Java, and for better backwards ---- +.Caution when defining `vaadin-maven-plugin` +[WARNING] +To ensure that the production build packages all resources correctly, make sure the `vaadin-maven-plugin` is executed after the `maven-compiler-plugin`. This can be achieved either configuring the execution goal of `vaadin-maven-plugin` to run after the goal targeted by `maven-compiler-plugin`, or if both target the same goal, placing the `vaadin-maven-plugin` definition after the `maven-compiler-plugin` in your `pom.xml`. The same applies for `kotlin-maven-plugin` or any other plugin that produces Vaadin related Java classes. + + .Building for 64-bit [NOTE] If you're using a 64-bit operating system, be sure to use a 64-bit JDK installation, as well. diff --git a/articles/flow/production/troubleshooting.adoc b/articles/flow/production/troubleshooting.adoc index 0d9a97f1c0..67258457cb 100644 --- a/articles/flow/production/troubleshooting.adoc +++ b/articles/flow/production/troubleshooting.adoc @@ -102,6 +102,11 @@ The application won't start after adding the `flow-server-production-mode` depen One potential cause of this problem is that the `build-frontend` of the `flow-maven-plugin` wasn't executed, either because the plugin is missing from the [filename]`pom.xml` file, or it's missing in the configuration. To resolve this, add the `flow-maven-plugin` to your Maven `build` block. Make sure it's visible in your production mode profile. Then enable the `build-frontend` goal. +Frontend resources are missing or not loaded in the running application.:: +A production build can result in a running application without properly loaded frontend resources due to a misconfigured `vaadin-maven-plugin`. ++ +To ensure that the production build packages all resources correctly, make sure the `vaadin-maven-plugin` is executed after the `maven-compiler-plugin`. This can be achieved either configuring the execution goal of `vaadin-maven-plugin` to run after the goal targeted by `maven-compiler-plugin`, or if both target the same goal, placing the `vaadin-maven-plugin` definition after the `maven-compiler-plugin` in your `pom.xml`. The same applies for `kotlin-maven-plugin` or any other plugin that produces Vaadin related Java classes. + When running multiple Vaadin applications on different ports on the same host, the browser tabs keeps reloading the page.:: The cause of page reloading is possibly due to server session expiration caused by all Vaadin application having the same HTTP session cookie name (e.g., `JSESSIONID`). Cookies for a given host are shared across all of the ports on that host, even though "same-origin policy", typically used by web browsers, isolates content retrieved via different ports. +