Can different clients access one same stateful session bean? 2003-10-18 - By Le Quang Tu
Back If a client-invoked business method is in progress on an instance when another client-invoked call, from the same or different client, arrives at the same instance of a tateful session bean class, the container may throw the java.rmi.RemoteException to the second client[4], if the client is a remote client, or the javax.ejb.EJBException , if the client is a local client. (from EJB spec ) And the message from Exception is: SessionBean is executing another request.
-- -- Original Message -- -- From: "PavanKumar Keely" <keelypavan@(protected)> To: <J2EEPATTERNS-INTEREST@(protected)> Sent: Saturday, October 18, 2003 11:13 AM Subject: Re: Can different clients access one same stateful session bean?
> I don't think there is any problem implementing this > scenario. Because the remote reference is same the > container treats multiple requests as the requests > from the same client. > > bye and haffun > Keely Pavan > > > --- peng wang <wp0@(protected)> wrote: > > Hi, > > > > Image a scenario like this: there is a client, C1, > > accessing a stateful bean, SB. C1 does some > > operations > > on SB and then C1 sends an event to another client, > > C2, > > the remote ojb reference of SB is carried in the > > event > > (C2 and C1 are in different machines).When C2 > > receives > > the event, C2 get SB reference from event and C2 > > also > > does some operations on the same SB, after that C2 > > send a noticing event back to C1, on receiving the > > noticing event C1 then removes SB and done. > > > > Is the scenario able to realized by using stateful > > session bean? if not, which mechanism should be > > used? > > > > thanks in advance! > > > > wp > > > > __ ____ ____ ____ ____ ____ ______ > > Do you Yahoo!? > > The New Yahoo! Shopping - with improved product > > search > > http://shopping.yahoo.com > > > > > ==================================================================== > > Companion Site: http://www.corej2eepatterns.com > > J2EE BluePrints: > > http://java.sun.com/blueprints/corej2eepatterns > > List Archive: > > > http://archives.java.sun.com/archives/j2eepatterns-interest.html > > Unsubscribing: email "signoff J2EEPATTERNS-INTEREST" > > to listserv@(protected) > > > __ ____ ____ ____ ____ ____ ______ > Do you Yahoo!? > The New Yahoo! Shopping - with improved product search > http://shopping.yahoo.com > > ==================================================================== > Companion Site: http://www.corej2eepatterns.com > J2EE BluePrints: http://java.sun.com/blueprints/corej2eepatterns > List Archive: http://archives.java.sun.com/archives/j2eepatterns-interest.html > Unsubscribing: email "signoff J2EEPATTERNS-INTEREST" to listserv@(protected)
==================================================================== Companion Site: http://www.corej2eepatterns.com J2EE BluePrints: http://java.sun.com/blueprints/corej2eepatterns List Archive: http://archives.java.sun.com/archives/j2eepatterns-interest.html Unsubscribing: email "signoff J2EEPATTERNS-INTEREST" to listserv@(protected)
|
|