Win a copy of 97 Things Every Java Programmer Should Know this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

ejb spec's point clarification..

 
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
 
Ranch Hand
Posts: 183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
 
A berm makes a great wind break. And we all like to break wind once in a while. Like this tiny ad:
Devious Experiments for a Truly Passive Greenhouse!
https://www.kickstarter.com/projects/paulwheaton/greenhouse-1
    Bookmark Topic Watch Topic
  • New Topic