Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » J2EE Pattern »

Re: EJB Calling a Servlet

Sean Brydon

2003-07-16

Replies:

Hi,
I think you are asking about where/how to store session state, and you
are considering using the EJB tier with stateful session beans. This
question is common and is addressed at
http://java.sun.com/blueprints/qanda/app_arch/index.html
hope that helps,
Sean

Rajarshi Ghosh wrote:

>I think you can use your session bean to maintain the client session.
>When you get the first call from the client you can create a stateful
>session bean specific to your client[you can pass your unique client
>parameters to the ejbCreate(..)method of stateful session bean]. If you
>anyway want to use the sessionID then you could create it in the
>servlet(first time) and could pass it to the session bean, thereon the
>session bean maintains the client session.
>
>Regards,
>Rajarshi Ghosh
>
>-----Original Message-----
>From: An interest list for Sun Java Center J2EE Pattern Catalog
>[mailto:J2EEPATTERNS-INTEREST@(protected)
>Sent: Monday, July 14, 2003 1:06 PM
>To: J2EEPATTERNS-INTEREST@(protected)
>Subject: Re: EJB Calling a Servlet
>
>
>thanks.
>
>but, i was thinking already transfer the session tracking
>from the httpsession to a stateful session bean. i will
>just expose same methods on the web original code and just change its
>implementation so that i will have a minimal code modifications. my
>problem now is how will i relate the session id returned to the JSP or
>servlet. i mean inorder to maintain that session id, how i will going to
>handle the tracking from the servlet point of view.
>
>thanks in advance.
>
>
>
>Hai Huynh Kim wrote:
>
>
>
>>I don't think that is a problem. Make sure you will go though this
>>session bean for all interations in further. It looks like the session
>>bean take role of the browser in servlet model.
>>
>>Hai
>>
>>-----Original Message-----
>>From: P i P O [mailto:wsellado@(protected)]
>>Sent: Thursday, July 10, 2003 10:11 AM
>>To: J2EEPATTERNS-INTEREST@(protected)
>>Subject: EJB Calling a Servlet
>>
>>
>>i know this is strange but.....i am
>>just trying to adjust on the current
>>system. a servlet is handling the login and
>>logout which also initializes all the
>>session for users. and here...i want to have
>>a session bean that could login using that
>>servlet. any idea from u? thanks in advance.
>>
>>pipo
>>
>>====================================================================
>>Community Web Site (Core J2EE Patterns Catalog - Online Version):
>>http://java.sun.com/blueprints/corej2eepatterns
>>Getting Started (Beta Version):
>>http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns
>>/
>>Get the book:
>>http://www.amazon.com/exec/obidos/ASIN/0130648841/corej2eepatte-20
>>List Archive:
>>http://archives.java.sun.com/archives/j2eepatterns-interest.html
>>Unsubscribing:
>>email "signoff J2EEPATTERNS-INTEREST" to listserv@(protected)
>>
>>Community Web Site (Core J2EE Patterns Catalog - Online Version):
>>http://java.sun.com/blueprints/corej2eepatterns
>>Getting Started (Beta Version):
>>http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns
>>/
>>Get the book:
>>http://www.amazon.com/exec/obidos/ASIN/0130648841/corej2eepatte-20
>>List Archive:
>>http://archives.java.sun.com/archives/j2eepatterns-interest.html
>>Unsubscribing:
>>email "signoff J2EEPATTERNS-INTEREST" to listserv@(protected)
>>
>>
>>
>>
>>
>
>--
>Wilfredo Sellado, AbtikBoys
>Software Design Engineer
>NEC Telecom Software Phils., Inc.
>Asiatown I.T. Park
>Apas, Cebu City 6000, Philippines
>Office  : +63(32)233-9142 [local 311]
>Residence: +63(32)495-7510
>Mobile  : +63(916)709-2632
>Email   : <wsellado@(protected)>
>
>====================================================================
>Community Web Site (Core J2EE Patterns Catalog - Online Version):
>http://java.sun.com/blueprints/corej2eepatterns
>Getting Started (Beta Version):
>http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/
>Get the book:
>http://www.amazon.com/exec/obidos/ASIN/0130648841/corej2eepatte-20
>List Archive:
>http://archives.java.sun.com/archives/j2eepatterns-interest.html
>Unsubscribing:
> email "signoff J2EEPATTERNS-INTEREST" to listserv@(protected)
>
>====================================================================
>Community Web Site (Core J2EE Patterns Catalog - Online Version):
> http://java.sun.com/blueprints/corej2eepatterns
>Getting Started (Beta Version):
> http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/
>Get the book:
> http://www.amazon.com/exec/obidos/ASIN/0130648841/corej2eepatte-20
>List Archive:
> http://archives.java.sun.com/archives/j2eepatterns-interest.html
>Unsubscribing:
> email "signoff J2EEPATTERNS-INTEREST" to listserv@(protected)
>
>

====================================================================
Community Web Site (Core J2EE Patterns Catalog - Online Version):
http://java.sun.com/blueprints/corej2eepatterns
Getting Started (Beta Version):
http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/
Get the book:
http://www.amazon.com/exec/obidos/ASIN/0130648841/corej2eepatte-20
List Archive:
http://archives.java.sun.com/archives/j2eepatterns-interest.html
Unsubscribing:
email "signoff J2EEPATTERNS-INTEREST" to listserv@(protected)


©2008 junlu.com - Jax Systems, LLC, U.S.A.