• 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
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

Q from SCBCD Mock exam.

 
Ranch Hand
Posts: 60
  • 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 regarding session beans are true? [Check all correct answers]


1 Invoking javax.ejb.EJBObject.getPrimaryKey() on a session bean results in javax.ejb.EJBException been thrown.
2 Invoking javax.ejb.EJBLocalObject.getPrimaryKey() on a session bean results in javax.ejb.EJBException been thrown.
3 Invoking javax.ejb.EJBHome.remove(java.lang.Object primaryKey) on a session bean results in javax.ejb.RemoveException been thrown.
4 Invoking javax.ejb.EJBLocalHome.remove(java.lang.Object primaryKey) on a session bean results in javax.ejb.RemoveException been thrown.
5 Invoking javax.ejb.EJBHome.remove(java.lang.Object primaryKey) on a session bean results in java.rmi.RemoteException been thrown.

I feel the answer is 2,3.When we use remove(Object key) on Remote Session Bean it throws javax.ejb.RemoveException & for Local SB it throws EJBException.

Can Some one tell me whether My answer is right or not.I am not sure whether my conclusion about this is right or not because in Mock answers they gave 2 & 5.

Thanx in advance.
 
Ranch Hand
Posts: 569
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
answer should be 2,3,4

Bottom of spec P59 and p60 explicitly defines the exceptions should be RemoveException but not RemoteException nor EJBException.
 
Vijaya laxmi
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanx a lot for Alex
 
Ranch Hand
Posts: 209
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You could refer to:
https://coderanch.com/t/159504/java-EJB-SCBCD/certification/Useful-points-exceptions-ejb

 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic