• 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:
  • Tim Cooke
  • Campbell Ritchie
  • paul wheaton
  • Ron McLeod
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:

EJB Timed out

 
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What happens when a business method is invoked on a bean that has timed out ?
Please help me for the question.
Ruilin
 
ruilin yang
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In the mock test, the answer for the following question is misleading from the test.
For a CMP Entity bean, what should the ejbCreate method return ? EJB specification) ?
According to the book I read, the answer is: null. However, the mock indicate the answer is: Remote interface.
Please comment.
Ruilin

 
ruilin yang
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The Mock Exam at the following site needs to be examined and corrected for answers. Otherwise it is misleading users. http://www.stormpages.com/jnagal/mock.html
I believe the owner of the mock examine is trying to help people. I feel thankful to him/her. However, its problems need to be fixed immediately.
best regards,
Ruilin
 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The only bean that will timeout is statefull session bean
state "Does not exists and referenced"
"... Attempted invocations on a session object
that does not exist result in java.rmi.NoSuchObjectException...."
see Section 5.6 EJB 1.1. Specification
 
ruilin yang
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for you reply.
The mock examine indicates the answer is:
ObjectNotFound Exception.
 
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
When a stateful session bean is in the passive state and it times out, if a client makes a reference to it.
Does the container try to restore the stateful sesion bean from the stored session data or does it throw an rmi.NoSuchObject exception???
Please comment.
 
Sergey Opanasets
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My understanding is: if an object times out, it is destroyed by the container.
So it really does not matter whether it was in passivated state or not.
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by ruilin yang:
In the mock test, the answer for the following question is misleading from the test.
For a CMP Entity bean, what should the ejbCreate method return ? EJB specification) ?
According to the book I read, the answer is: null. However, the mock indicate the answer is: Remote interface.
Please comment.
Ruilin


According to EJB spec. 1.1, ejbCreate() must return the primary key type (sec. 10.6.4).
 
Ranch Hand
Posts: 181
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi guys I took the partI. I did not find any question specific to EJB API, although I know it. So, don't spend time on the details. In EJB 1.1 ejbCreate() return PK. If it is CMP PK is null.
 
Jun Hong
Ranch Hand
Posts: 181
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The mock exam your guys talking about is misleading.
 
reply
    Bookmark Topic Watch Topic
  • New Topic