-
EJB3: Stateful session bean servicing stateless webservice bean (3 messages)
- Posted by: Bj??rn B??rresen
- Posted on: August 24 2006 10:26 EDT
I'm looking into writing a login/session handling system in EJB3. This is what I'm thinking: Entity Bean -> Session Facade -> Session Bean (business logic, stateful) -> WebService implementation (stateless session bean). But what I don't understand is; how does the stateless webservice session bean know which stateful session bean to contact? How does this happen? Also, this problem has to have been solved before -- how to generate unique sessionID for the client etc. Does anyone have info/links that could be of help?Threaded Messages (3)
- Re: EJB3: Stateful session bean servicing stateless webservice bean by Bhagvan K on August 27 2006 20:18 EDT
- Re: EJB3: Stateful session bean servicing stateless webservice b by Bj??rn B??rresen on August 28 2006 03:46 EDT
- Re: EJB3: Stateful session bean servicing stateless webservice b by Yuriy Dumchikov on March 01 2008 00:45 EST
-
Re: EJB3: Stateful session bean servicing stateless webservice bean[ Go to top ]
- Posted by: Bhagvan K
- Posted on: August 27 2006 20:18 EDT
- in response to Bj??rn B??rresen
to answer your question, you need to have separate authenticate/security session bean whose acls are non restrictive for a guest to pass in his credentials... once authenticated against LDAP/Database/NTLM, you can get a handle creating a stateful session bean, the handle info is stored in httpsession or any secondary data source... Bhagvan K http://www.jroller.com/page/bhagvank -
Re: EJB3: Stateful session bean servicing stateless webservice b[ Go to top ]
- Posted by: Bj??rn B??rresen
- Posted on: August 28 2006 03:46 EDT
- in response to Bhagvan K
Thanks for your reploy Bhagvan! You say a a statefull session bean handle is stored in HTTPSession .. that sounds like what I want to do. But what I don't understand is the lookup the webservice bean does to find the stateful session bean for a particular client. Cause the client needs to go through the webservice no matter what (this is going to be an API open to authenticated users). Do you have some example code of that, or maybe a link explaining it? -
Re: EJB3: Stateful session bean servicing stateless webservice b[ Go to top ]
- Posted by: Yuriy Dumchikov
- Posted on: March 01 2008 00:45 EST
- in response to Bhagvan K
Only Stateless Session Bean can be exposed as a Web Service