spring-projects / spring-projects/spring-session
Spring Session is null after oauth success callback
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.9k
- Forks
- 1.2k
- Avg merge
- 4h 27m
- Merged PRs (30d)
- 55
Description
Hi guys,
I am using following configuration for a Spring Microservices application:
- Spring Session (Backed by Redis Server)
- Form login
- Social Login (Facebook + Twitter ) using spring-social plugin.
Form Login is working fine with both HttpSession as well as SpringSession using Redis.
In case of Social Login, SpringSession is always null. When I use HttpSession it works fine.
I am using following configuration to enable SpringSession:
@EnableRedisHttpSession
public class SpringSessionConfig {
@Bean
public LettuceConnectionFactory connectionFactory() {
return new LettuceConnectionFactory();
}
@Bean
public HttpSessionStrategy httpSessionStrategy() {
return new HeaderHttpSessionStrategy();
}
}
@Configuration
public class SpringSessionFilterInitializer extends AbstractHttpSessionApplicationInitializer {
public SpringSessionFilterInitializer() {
super(SpringSessionConfig.class);
}
}
Can Anyone help me in getting the right direction?
Thanks in advance.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the SpringSessionConfig and SpringSessionFilterInitializer configuration shown in the issue, then reproduce the social-login callback using Redis-backed Spring Session. Compare its session handling with the working form-login and HttpSession paths. Done means the session remains available after the Facebook or Twitter OAuth success callback.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, redis, spring
- Domain
- authentication
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100