Win a copy of Head First Android this week in the Android 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Rob Spoor
  • Bear Bibeault
Saloon Keepers:
  • Jesse Silverman
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Al Hobbs
  • salvin francis

test question

 
Ranch Hand
Posts: 154
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Below is a question from a mock test for IBM 484. I dont think I understand the question well enough.
Given an Order entity EJB and a single class loader, which of the following is a Singleton? (choose one only)

A. OrderHomeRemote

B. OrderBean

C. OrderRemote

D. Order

Although I dont understand the question very well, A and C dont make sense at all. Since there is nothing called a OrderHomeRemote and OrderRemote. I would rather choose D because there can be many instances of the bean and making it a singleton makes little sense.
Am I on the right track? Any ideas?
PK
 
Ranch Hand
Posts: 649
Mac
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would say this is a very vaugu question. Without any giving any scenario
making anything singleton never makes sense.
 
author
Posts: 361
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howdy Folks,
I remember this question from the pre-assessment/sample test.
And I have passed the 484 back in August!
I think the best answer is "A", by process of elimination:
  • "D" is kind of stupid (they are trying to catch you).
  • "B" cannot be correct... the containers has a pool to work with.
  • "C" cannot be correct... there will be a remote for every client.


  • Ta da!
     
    Ranch Hand
    Posts: 35
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    Hi Prakash...
    The answer for this question is A.I don't know what the test IBM 484 is about.But i learnt EJB using WSAD.So if u look the redbooks on WSAD,we will be given sample code as to how to locate beans using JNDI.There the utlity class uses a method called singleton, which is used to call the beans. There we have to specify the remote home interface as a parameter in calling the bean.
    So obviously the answer is A, which is the home remote interface name of the order entity bean.
    Hope this clears a bit.
    Radha.
     
    With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
    reply
      Bookmark Topic Watch Topic
    • New Topic