Last active
July 11, 2018 15:10
-
-
Save SergiiVlasiuk/7cff77bc4435dc07de979b3879d29775 to your computer and use it in GitHub Desktop.
Change spring security multithread strategy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Import( {WebConfiguration.class, SwaggerConfiguration.class, AuthorizationConfiguration.class, | |
DataSourceConfiguration.class}) | |
@EnableJpaAuditing | |
public class MainConfiguration { | |
@PostConstruct | |
void init() { | |
TimeZone.setDefault(TimeZone.getTimeZone(Constants.DEFAULT_TIME_ZONE_ID)); | |
SecurityContextHolder.setStrategyName(MODE_INHERITABLETHREADLOCAL); | |
} | |
// .... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment