Spring Boot programming model support

Liberty supports the Spring Boot application programming model to develop Spring applications.

Open Liberty For the most current information about deploying Spring Boot applications to Liberty, see the Open Liberty website.

Background

Spring Boot is designed to get you up and running as quickly as possible. For more information, see the Spring Boot project site.

A typical Spring Boot application is a stand-alone JAR file that can run without deployment to an application server. This stand-alone file can simplify the development of Spring Boot applications. However, when you deploy the application to a production environment, you do not have the benefits of an application server.

The Spring Boot application JAR file format is a supported application type in Liberty. You can deploy Spring Boot applications to Liberty without packaging them as a WAR file. Liberty provides tools for optimizing the deployment of Spring Boot applications to containers, such as Docker.

Attention: Liberty support for Spring Boot is integrated with support for the web container by using the Liberty Java or Jakarta Servlet and Java or Jakarta Server Pages features. The Transport Security or WebSocket features can be enabled if HTTPS or WebSocket support is needed. All other server configuration is handled by Spring Boot application properties. For more information about the available versions of these features, see Liberty features.

For example, security properties can be set by using spring.security.* application properties. The Liberty Spring Boot features, , do not integrate with the functions that are provided by other Liberty features, such as Application Security and Jakarta RESTful Web Services (formerly JAX-RS) . If an application needs functions similar to what is provided by these Liberty features, the Spring Boot project provides Spring Boot starters that can be included in the application. Including Spring Boot starters like spring-boot-starter-security or third-party starters like cxf-spring-boot-starter-jaxrs in an application allows it to use technologies that are provided by the starter instead of using Liberty features.

Spring Boot starters

Table 1. Spring Boot support
Spring Boot starter Liberty feature Liberty Liberty Core
Spring Boot 1.5
spring-boot-starter springBoot-1.5
spring-boot-starter-web springBoot-1.5 and servlet-3.1, servlet-4.0, or jsp-2.3
spring-boot-starter-websocket springBoot-1.5 and websocket-1.0 or websocket-1.1
Spring Boot 2.0
spring-boot-starter springBoot-2.0
spring-boot-starter-web springBoot-2.0 and servlet-3.1, servlet-4.0, or jsp-2.3
spring-boot-starter-websocket springBoot-2.0and websocket-1.0 or websocket-1.1
spring-boot-starter-webflux springBoot-2.0 and servlet-3.1, servlet-4.0, or jsp-2.3

Spring Boot 3.0

spring-boot-starter springBoot-3.0 [23.0.0.9 and later] [23.0.0.9 and later]
spring-boot-starter-web springBoot-3.0 and servlet-6.0, servlet-6.1, or jsp-2.3 [23.0.0.9 and later] [23.0.0.9 and later]
spring-boot-starter-websocket springBoot-3.0 and websocket-2.0 [23.0.0.9 and later] [23.0.0.9 and later]
spring-boot-starter-webflux springBoot-3.0 and servlet-6.0, servlet-6.1, or jsp-2.3 [23.0.0.9 and later] [23.0.0.9 and later]

In addition to the starters that are listed, other Spring Boot starters are available for Spring Boot applications. More starters that are included in the application do not require you to enable more Liberty features.