Quantcast
Channel: Active questions tagged redis+java - Stack Overflow
Viewing all articles
Browse latest Browse all 2204

Can Spring Session be turned off in Spring Boot 3?

$
0
0

In my Spring Boot 2.7.4 project, I use Spring Session with Redis by including these dependencies:

<dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-data-redis</artifactId><version>${spring-boot-version}</version></dependency><dependency><groupId>org.springframework.session</groupId><artifactId>spring-session-data-redis</artifactId></dependency>

This, along with a handful of application property settings to specify host, port, etc., this works fine.

Setting the following property allows Spring Session to be switched off. This is very convenient when running the service in an IDE in a development environment, for example, where you may not have access to a running Redis instance.

spring.session.store-type=NONE

However, I have just upgraded to Spring Boot 3.0.4 and have found that this property is no longer supported. I would be very grateful if anyone can suggest an alternative way to switch off Spring Session for development work, while still leaving the dependencies and configuration in place ready for formal deployments.


Viewing all articles
Browse latest Browse all 2204

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>