• 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
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Bear Bibeault
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • salvin francis
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Frits Walraven
Bartenders:
  • Jj Roberts
  • Carey Brown
  • Scott Selikoff

Mock Question

 
Ranch Hand
Posts: 82
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Which of the following statements are correct about the responsibilities of the EJB container? [Check all correct answers]
The correct answer is:
1. When the container invokes the ejbRemove() method the container removes immediately the entity from the database.
2. After the ejbHome() method completes, the instance remains in the ready state.
3. The container synchronizes the instance's state before it invokes the ejbRemove() method and uses the ejbLoad() method.
4. The container is responsible for providing the implementation of the ejbFind() methods.
5. The container is responsible for calling the ejbCreate() method.
Mock answers - 3,4 and 5
How is option 4 correct? For a BMP can't we provide the implementation.
 
Ranch Hand
Posts: 1066
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If this is a mock exam related to SCBCD exam, I would say option 4 is correct,
as BMP is out of scope. The exam would not contain any questions to related BMP.
It covers only CMP2.0 and the Container is responsible to provide the implementation
for the ejbFind methods and not the bean provider.
By the way, why is option 1 incorrect?
Is it because, the client calls remove() method, Container calls ejbRemove() method.
It waits for the execution of the ejbRemove() method to finish, and then
deletes the row in the database.
So the word "immediately" may not be the perfect word to be used here.
Any comments?
 
rahul V kumar
Ranch Hand
Posts: 82
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Vish Kumar:
If this is a mock exam related to SCBCD exam, I would say option 4 is correct,
as BMP is out of scope. The exam would not contain any questions to related BMP.
It covers only CMP2.0 and the Container is responsible to provide the implementation
for the ejbFind methods and not the bean provider.
By the way, why is option 1 incorrect?
Is it because, the client calls remove() method, Container calls ejbRemove() method.
It waits for the execution of the ejbRemove() method to finish, and then
deletes the row in the database.
So the word "immediately" may not be the perfect word to be used here.
Any comments?


Yes this question is from a mock exam. But can we expect these kind of questions on the real exam ??
When the client calls ejbRemove() method, the container synchronizes the instance�s state before it invokes the ejbRemove method i.e. ejbLoad() is called so that state of the instance at the beginning of the ejbRemove method is the same as it would be at the beginning of a business method.
Refer to page 172 of Spec.
 
CAUTION! Do not touch the blades on your neck propeller while they are active. Tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic