diff --git a/documentation/spring-boot-docs/src/docs/antora/modules/reference/pages/web/spring-session.adoc b/documentation/spring-boot-docs/src/docs/antora/modules/reference/pages/web/spring-session.adoc index 08803567062..12326cf0df7 100644 --- a/documentation/spring-boot-docs/src/docs/antora/modules/reference/pages/web/spring-session.adoc +++ b/documentation/spring-boot-docs/src/docs/antora/modules/reference/pages/web/spring-session.adoc @@ -2,23 +2,16 @@ = Spring Session Spring Boot provides {url-spring-session-site}[Spring Session] auto-configuration for a range of data stores. -When building a servlet web application, the following stores can be auto-configured: +For each data store, a specific Spring Boot starter is provided. -* Redis -* JDBC +When building a servlet web application, the following stores can be auto-configured: -Additionally, {url-spring-boot-for-apache-geode-site}[Spring Boot for Apache Geode] provides {url-spring-boot-for-apache-geode-docs}#geode-session[auto-configuration for using Apache Geode as a session store]. +* Redis (`spring-boot-starter-session-data-redis`) +* JDBC (`spring-boot-starter-session-jdbc`) The servlet auto-configuration replaces the need to use `@Enable*HttpSession`. -If a single Spring Session module is present on the classpath, Spring Boot uses that store implementation automatically. -If you have more than one implementation, Spring Boot uses the following order for choosing a specific implementation: - -. Redis -. JDBC -. If neither Redis nor JDBC are available, we do not configure a javadoc:org.springframework.session.SessionRepository[]. - -When building a reactive web application, the Redis store can be auto-configured. +When building a reactive web application, the Redis store can be auto-configured by depending on `spring-boot-starter-session-data-redis`. This replaces the need to use `@EnableRedisWebSession`. Each store has specific additional settings. @@ -37,4 +30,5 @@ If that property is not set with a servlet web application, the auto-configurati You can take control over Spring Session's configuration using `@Enable*HttpSession` (servlet) or `@EnableRedisWebSession` (reactive). This will cause the auto-configuration to back off. -Spring Session can then be configured using the annotation's attributes rather than the previously described configuration properties. +Alternatively, depend on the relevant Spring Session module directly rather than using one of Spring Boot's starters for Spring Session. +With either approach, Spring Session can then be configured using the annotation's attributes rather than the previously described configuration properties.