cancel
Showing results for 
Search instead for 
Did you mean: 

How to obtain ySession from different thread using HttpSession id ?

former_member224482
Active Contributor
0 Kudos
156

In one of our scenario we are running a piece of code in a non HttpServletRequest thread.
The only known information is the HttpSession id.

How can be obtain the de.hybris.platform.servicelayer.session.Session using the javax.servlet.http.HttpSession.getId() value ?

There is a deprecated method de.hybris.platform.servicelayer.session.SessionService.getSession(String id) without information about what it has been replaced with.

View Entire Topic
Former Member
0 Kudos

Maybe the pattern you're trying to implement is deprecated, not just the key method?

former_member224482
Active Contributor
0 Kudos

The process is indeed broken by design.
After reading more on the topic such scenario shall not be attempted.

In general, the provider of the session ID shall become responsible for providing the other values out of the session.