File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes ejb spec's point clarification.. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "ejb spec Watch "ejb spec New topic
Author

ejb spec's point clarification..

mallika shah
Ranch Hand

Joined: May 11, 2006
Posts: 164
Can someone please clarify the meaning of this paragraph taken from specs..

A message-driven bean instance has no state for a specific client. However, the instance variables of the
message-driven bean instance can contain state across the handling of client messages. Examples of
such state include an open database connection and a reference to an enterprise bean.

This portion is confusing for me "However, the instance variables of the
message-driven bean instance can contain state across the handling of client messages"

its the same for stateless session benas.Please clarify with an example if possible..

thanks,
mallika
Benoît de Chateauvieux
Ranch Hand

Joined: Aug 10, 2007
Posts: 183
Hi mallika,

It means that a MDB or a SB Stateless can have instance variable (connections, counters, etc.). Those instance variable are the State of the EJB.

But they don't maintain conversational state with a specific client.
No conversational state means that if you receive 2 messages o 2 calls to a SB Stateless, you can't be sure that the same instance of EJB will serve you.

Hope it helps,

Beno�t


SCJP5 | SCBCD5 | SCEA5 Part 1
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: ejb spec's point clarification..