Files
spring-boot-rest/spring-5/src/test/java/com/baeldung/sessionattrs/TestConfig.java
Chris Oberle 95f0340318 BAEL-1533 Making a Spring MVC Form Remember Values
- add example code
- update pom dependency to spring boot starter 2.0.0.RC2
- update import in SpringApplicationException
2018-02-24 15:59:23 -05:00

18 lines
583 B
Java

package com.baeldung.sessionattrs;
import org.springframework.beans.factory.config.CustomScopeConfigurer;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.support.SimpleThreadScope;
@Configuration
public class TestConfig {
@Bean
public CustomScopeConfigurer customScopeConfigurer() {
CustomScopeConfigurer configurer = new CustomScopeConfigurer();
configurer.addScope("session", new SimpleThreadScope());
return configurer;
}
}