springBootUtility thin command
The springBootUtility thin
command creates a thin application and library cache from a fat Spring Boot application.
This command stores the dependent library JAR files of the application to the target library cache and packages the remaining application artifacts into a thin application JAR file. When a read-only parent library cache is specified, the command creates a target library cache that contains only the libraries that are not available in the parent cache. This action creates efficient Docker layers for Spring Boot applications.
Usage examples
Create the thin Spring Boot application with the springBootUtility thin
command and the necessary options:
path_to_liberty/wlp/bin/springBootUtility thin \ --sourceAppPath=hellospringboot.jar \ --targetLibCachePath=path_to_liberty/wlp/usr/shared/resources/lib.index.cache \ --targetThinAppPath=path_to_liberty/wlp/usr/servers/helloserver/dropins/spring/hellospringboot.jar
Options
Option | Description |
---|---|
--sourceAppPath=path |
The path of the source application file to thin. This option is required. |
--parentLibCachePath=directory |
The directory path of the parent read-only library cache. The parent library cache is searched first to locate existing libraries. If the library is not found, the library is stored in the writable library cache that is specified by the |
--targetLibCachePath=directory |
The directory path that is used to save the library cache. If this option is not specified, a |
--targetThinAppPath=file |
The path that is used to save the thin application file. If this option is not specified, a new file is created with the |