• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

conversational state

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I tried mock exam on ejbcertificate.com and i was confused with one question


Question : - Which one of the following statements regarding a session bean's conversational state is true?

1. Stateless and stateful session beans both maintain conversational state.
2. An object reference to the java:comp/env JNDI context that is stored in session bean's conversational state is not perserved when the session bean is passivated.
3. The conversational state of a session bean with container-managed transaction demarcation is automatically rolled back to its initial state if a system exception is thrown by a business method.
4. A session bean's conversational state can hold an open socket connection.
5. Non-transient fields of a session bean's conversational state are lost when a session bean is passivated


Correct ANSWER 4

I think answer 1 is also correct. A stateless has also a conversational state, but not between methods (see also EJB Spec 7.3)
What is the correct definition of "conversational state"?

Regards,

Michael Meyer
 
Ranch Hand
Posts: 98
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HI Michael,

'Having conversational State ' is different from 'Maintaining the conversational State'.

Both Statefull and Stateless session beans can have conversation data. But only Stateful beans can maintain it.

In case of the stateless bean , if your are calling second time , there are chance you can get some other bean to serve your request.

~With SMile
VK
 
Michael Meyer
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Karthikeyan,

thanks for your answer.
I should stop my preparation for two days ;-)

Regards,

Michael
 
There were millions of the little blood suckers. But thanks to this tiny ad, I wasn't bitten once.
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic