Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No session repository could be auto-configured, check your configuration (session store type is 'null')

What does this spring boot start up error mean?

2016-07-04 21:53:53 [restartedMain] ERROR o.s.boot.SpringApplication - Application startup failed    org.springframework.beans.factory.BeanCreationException: Error creating bean with name org.springframework.boot.autoconfigure.session.SessionAutoConfiguration$SessionRepositoryValidator': Invocation of init method failed; nested exception is java.lang.IllegalArgumentException: No session repository could be auto-configured, check your configuration (session store type is 'null') 
like image 229
Stephen Isienyi Avatar asked Jul 05 '16 03:07

Stephen Isienyi


1 Answers

You have Spring Session on your classpath and no store was provided. We can't take that decision for you as if your classpath changes, the store type may change according to our preferences and you'd lose them without any sort of warning.

Historically we only supported redis so if you have that we'll use it transparently. Please set spring.session.store-type to the store you want to use for Spring Session. If Spring Session is on your classpath and you don't want to use it right now, set spring.session.store-type=none

Update: given the number of upvotes, this looks like a confusing error message so I've opened #9284 to improve it.

like image 188
Stephane Nicoll Avatar answered Sep 26 '22 14:09

Stephane Nicoll