From 3d6859e80f5b66613db1f33a6751854de7e49b21 Mon Sep 17 00:00:00 2001 From: Phillip Webb Date: Thu, 28 Sep 2023 13:29:30 -0700 Subject: [PATCH] Use the term "uber jar" in reference documentation and javadoc Update reference documentation and javadoc to use the term "uber jar" rather than "fat jar". Closes gh-37653 --- .../springframework/boot/devtools/restart/Restarter.java | 6 +++--- .../src/docs/asciidoc/container-images/dockerfiles.adoc | 2 +- .../docs/asciidoc/container-images/efficient-images.adoc | 6 +++--- .../src/docs/asciidoc/executable-jar/property-launcher.adoc | 2 +- .../asciidoc/features/developing-auto-configuration.adoc | 2 +- .../docs/asciidoc/getting-started/first-application.adoc | 2 +- .../src/docs/asciidoc/reacting.adoc | 2 +- .../java/org/springframework/boot/loader/tools/Library.java | 4 ++-- .../springframework/boot/loader/tools/StandardLayers.java | 2 +- .../boot/loader/jarmode/JarModeLauncher.java | 2 +- .../org/springframework/boot/maven/ArtifactsLibraries.java | 2 +- .../java/org/springframework/boot/maven/RepackageMojo.java | 2 +- .../springframework/boot/loader/LoaderIntegrationTests.java | 2 +- 13 files changed, 18 insertions(+), 18 deletions(-) diff --git a/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/Restarter.java b/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/Restarter.java index 410b269d1d..b02a92fb31 100644 --- a/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/Restarter.java +++ b/spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/restart/Restarter.java @@ -68,9 +68,9 @@ import org.springframework.util.ReflectionUtils; * {@link #initialize(String[])} directly if your SpringApplication arguments are not * identical to your main method arguments. *

- * By default, applications running in an IDE (i.e. those not packaged as "fat jars") will - * automatically detect URLs that can change. It's also possible to manually configure - * URLs or class file updates for remote restart scenarios. + * By default, applications running in an IDE (i.e. those not packaged as "uber jars") + * will automatically detect URLs that can change. It's also possible to manually + * configure URLs or class file updates for remote restart scenarios. * * @author Phillip Webb * @author Andy Wilkinson diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/dockerfiles.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/dockerfiles.adoc index 1c3d77cff2..a3374debfa 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/dockerfiles.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/dockerfiles.adoc @@ -1,6 +1,6 @@ [[container-images.dockerfiles]] == Dockerfiles -While it is possible to convert a Spring Boot fat jar into a docker image with just a few lines in the Dockerfile, we will use the <> to create an optimized docker image. +While it is possible to convert a Spring Boot uber jar into a docker image with just a few lines in the Dockerfile, we will use the <> to create an optimized docker image. When you create a jar containing the layers index file, the `spring-boot-jarmode-layertools` jar will be added as a dependency to your jar. With this jar on the classpath, you can launch your application in a special mode which allows the bootstrap code to run something entirely different from your application, for example, something that extracts the layers. diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/efficient-images.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/efficient-images.adoc index ad70d6a75e..b7bfbdf9f1 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/efficient-images.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/container-images/efficient-images.adoc @@ -1,8 +1,8 @@ [[container-images.efficient-images]] == Efficient Container Images -It is easily possible to package a Spring Boot fat jar as a docker image. -However, there are various downsides to copying and running the fat jar as is in the docker image. -There’s always a certain amount of overhead when running a fat jar without unpacking it, and in a containerized environment this can be noticeable. +It is easily possible to package a Spring Boot uber jar as a docker image. +However, there are various downsides to copying and running the uber jar as is in the docker image. +There’s always a certain amount of overhead when running a uber jar without unpacking it, and in a containerized environment this can be noticeable. The other issue is that putting your application's code and all its dependencies in one layer in the Docker image is sub-optimal. Since you probably recompile your code more often than you upgrade the version of Spring Boot you use, it’s often better to separate things a bit more. If you put jar files in the layer before your application classes, Docker often only needs to change the very bottom layer and can pick others up from its cache. diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/executable-jar/property-launcher.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/executable-jar/property-launcher.adoc index 675a2bc278..ba6ae905b8 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/executable-jar/property-launcher.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/executable-jar/property-launcher.adoc @@ -64,7 +64,7 @@ When specified as environment variables or manifest entries, the following names | `LOADER_SYSTEM` |=== -TIP: Build plugins automatically move the `Main-Class` attribute to `Start-Class` when the fat jar is built. +TIP: Build plugins automatically move the `Main-Class` attribute to `Start-Class` when the uber jar is built. If you use that, specify the name of the class to launch by using the `Main-Class` attribute and leaving out `Start-Class`. The following rules apply to working with `PropertiesLauncher`: diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/developing-auto-configuration.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/developing-auto-configuration.adoc index 70f020dc5a..a98d92eecf 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/developing-auto-configuration.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/developing-auto-configuration.adoc @@ -272,7 +272,7 @@ When building with Maven, it is recommended to add the following dependency in a ---- -If you have defined auto-configurations directly in your application, make sure to configure the `spring-boot-maven-plugin` to prevent the `repackage` goal from adding the dependency into the fat jar: +If you have defined auto-configurations directly in your application, make sure to configure the `spring-boot-maven-plugin` to prevent the `repackage` goal from adding the dependency into the uber jar: [source,xml,indent=0,subs="verbatim"] ---- diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/getting-started/first-application.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/getting-started/first-application.adoc index 6abd497b49..b0daeba458 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/getting-started/first-application.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/getting-started/first-application.adoc @@ -380,7 +380,7 @@ To gracefully exit the application, press `ctrl-c`. [[getting-started.first-application.executable-jar]] === Creating an Executable Jar We finish our example by creating a completely self-contained executable jar file that we could run in production. -Executable jars (sometimes called "`fat jars`") are archives containing your compiled classes along with all of the jar dependencies that your code needs to run. +Executable jars (sometimes called "`uber jars`" or "`fat jars`") are archives containing your compiled classes along with all of the jar dependencies that your code needs to run. .Executable jars and Java **** diff --git a/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/reacting.adoc b/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/reacting.adoc index 7da583578b..31d1f2c1b3 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/reacting.adoc +++ b/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/docs/asciidoc/reacting.adoc @@ -9,7 +9,7 @@ This section describes those changes. == Reacting to the Java Plugin When Gradle's {java-plugin}[`java` plugin] is applied to a project, the Spring Boot plugin: -1. Creates a {boot-jar-javadoc}[`BootJar`] task named `bootJar` that will create an executable, fat jar for the project. +1. Creates a {boot-jar-javadoc}[`BootJar`] task named `bootJar` that will create an executable, uber jar for the project. The jar will contain everything on the runtime classpath of the main source set; classes are packaged in `BOOT-INF/classes` and jars are packaged in `BOOT-INF/lib` 2. Configures the `assemble` task to depend on the `bootJar` task. 3. Configures the `jar` task to use `plain` as the convention for its archive classifier. diff --git a/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/Library.java b/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/Library.java index f2fe532223..654666ed30 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/Library.java +++ b/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/Library.java @@ -64,7 +64,7 @@ public class Library { * @param unpackRequired if the library needs to be unpacked before it can be used * @param local if the library is local (part of the same build) to the application * that is being packaged - * @param included if the library is included in the fat jar + * @param included if the library is included in the uber jar * @since 2.4.8 */ public Library(String name, File file, LibraryScope scope, LibraryCoordinates coordinates, boolean unpackRequired, @@ -142,7 +142,7 @@ public class Library { } /** - * Return if the library is included in the fat jar. + * Return if the library is included in the uber jar. * @return if the library is included */ public boolean isIncluded() { diff --git a/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/StandardLayers.java b/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/StandardLayers.java index 544c213f3a..22b8a0c02c 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/StandardLayers.java +++ b/spring-boot-project/spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/StandardLayers.java @@ -27,7 +27,7 @@ import java.util.stream.Stream; *

    *
  1. "dependencies" - For non snapshot dependencies
  2. *
  3. "spring-boot-loader" - For classes from {@code spring-boot-loader} used to launch a - * fat jar
  4. + * uber jar *
  5. "snapshot-dependencies" - For snapshot dependencies
  6. *
  7. "application" - For application classes and resources
  8. *
diff --git a/spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jarmode/JarModeLauncher.java b/spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jarmode/JarModeLauncher.java index 42a89a50a3..4424889341 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jarmode/JarModeLauncher.java +++ b/spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jarmode/JarModeLauncher.java @@ -22,7 +22,7 @@ import org.springframework.core.io.support.SpringFactoriesLoader; import org.springframework.util.ClassUtils; /** - * Delegate class used to launch the fat jar in a specific mode. + * Delegate class used to launch the uber jar in a specific mode. * * @author Phillip Webb * @since 2.3.0 diff --git a/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/ArtifactsLibraries.java b/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/ArtifactsLibraries.java index 372f74a1b5..dfeca203d1 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/ArtifactsLibraries.java +++ b/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/ArtifactsLibraries.java @@ -85,7 +85,7 @@ public class ArtifactsLibraries implements Libraries { /** * Creates a new {@code ArtifactsLibraries} from the given {@code artifacts}. * @param artifacts all artifacts that can be represented as libraries - * @param includedArtifacts the actual artifacts to include in the fat jar + * @param includedArtifacts the actual artifacts to include in the uber jar * @param localProjects projects for which {@link Library#isLocal() local} libraries * should be created * @param unpacks artifacts that should be unpacked on launch diff --git a/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/RepackageMojo.java b/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/RepackageMojo.java index 1e3df71dd4..5ca2ecac5a 100644 --- a/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/RepackageMojo.java +++ b/spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/RepackageMojo.java @@ -106,7 +106,7 @@ public class RepackageMojo extends AbstractPackagerMojo { private boolean attach = true; /** - * A list of the libraries that must be unpacked from fat jars in order to run. + * A list of the libraries that must be unpacked from uber jars in order to run. * Specify each library as a {@code } with a {@code } and a * {@code } and they will be unpacked at runtime. * @since 1.1.0 diff --git a/spring-boot-tests/spring-boot-integration-tests/spring-boot-loader-tests/src/intTest/java/org/springframework/boot/loader/LoaderIntegrationTests.java b/spring-boot-tests/spring-boot-integration-tests/spring-boot-loader-tests/src/intTest/java/org/springframework/boot/loader/LoaderIntegrationTests.java index 6e5168574e..9acac3f61d 100644 --- a/spring-boot-tests/spring-boot-integration-tests/spring-boot-loader-tests/src/intTest/java/org/springframework/boot/loader/LoaderIntegrationTests.java +++ b/spring-boot-tests/spring-boot-integration-tests/spring-boot-loader-tests/src/intTest/java/org/springframework/boot/loader/LoaderIntegrationTests.java @@ -39,7 +39,7 @@ import org.springframework.util.Assert; import static org.assertj.core.api.Assertions.assertThat; /** - * Integration tests loader that supports fat jars. + * Integration tests loader that supports uber jars. * * @author Phillip Webb * @author Moritz Halbritter