• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

ejbcertificate mock exam question.

 
Ranch Hand
Posts: 351
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Which of the following rules must the bean provider comply with when defining an entity bean class that uses container-managed persistence? [Check all correct answers]

1. The Bean Provider must ensure that the Java types assigned to the cmp-fields are restricted to the following Java primitive types and Java serializable types.

2. The Bean Provider does not need to be concerned about the cmp-fields types as the container is able to save any Java type.

3. The accessor methods for the container-managed relationship fields must not be exposed in the remote interface of an entity bean.

4. The local interface types of the entity bean and of related entity bean's must be exposed through the remote interface of the entity bean.

1 and 3 are marked right. I am not getting what the fourth option is really. Can someone help me with the fourth option? In the answer explanation, the fourth option is just negated -changing the must to must NOT!

Thanks in Advance!

Regards,
Leena
 
Leena Diwan
Ranch Hand
Posts: 351
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is one more doubt from ejbcetificate.com, thought I better not start a new topic under a similar title.

Which of the following statements are true when a session bean's client receives a java.rmi.RemoteException?

One correct answer is - The client calls the session bean from another JVM.

I did not get this at all. Did not read anything of this sort in the HFEJB.
Someone can help?

Regards,
Leena
 
Ranch Hand
Posts: 211
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Leena Diwan:
4. The local interface types of the entity bean and of related entity bean's must be exposed through the remote interface of the entity bean.



The local interface types of an entity bean (Bean A) and the local interface types of another entity bean (Bean B) that is related to the former bean (Bean A) must be exposed through the remote interface of the entity bean (Bean A)
 
Keerthi P
Ranch Hand
Posts: 211
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Leena Diwan:
There is one more doubt from ejbcetificate.com, thought I better not start a new topic under a similar title.

Which of the following statements are true when a session bean's client receives a java.rmi.RemoteException?

One correct answer is - The client calls the session bean from another JVM.

I did not get this at all. Did not read anything of this sort in the HFEJB.
Someone can help?

Regards,
Leena



That's what EJB is all about and is what differentiates it from a plain JavaBean. OK, atleast *remoteness* is one of the properties of EJB, apart from transaction, security, bla bla bla...

If your bean is a SessionBean and if it has a Remote component interface, you should be able to call its methods from a client that is "remote" - a java program (or a CORBA compliant client) that runs in different machine or in a seperate JVM (the java.exe instance).
 
Leena Diwan
Ranch Hand
Posts: 351
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Keerthi P:


The local interface types of an entity bean (Bean A) and the local interface types of another entity bean (Bean B) that is related to the former bean (Bean A) must be exposed through the remote interface of the entity bean (Bean A)



Is it like -
1. client(actual client or SB as a client)
2. Entity Bean A available remotely
3. Entity Bean B available locally and related to Bean A

A. Bean A's 'remote' interface must expose Bean B's interface type to the client.
Like Movie entity bean having getDirector() and Director entity bean having getMovies()?
B. Both the entity beans mustn't be local for a relation?

Originally posted by Keerthi P:


I did not get you.

Regards,
Leena
 
Leena Diwan
Ranch Hand
Posts: 351
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Keerthi P:

If your bean is a SessionBean and if it has a Remote component interface, you should be able to call its methods from a client that is "remote" - a java program (or a CORBA compliant client) that runs in different machine or in a seperate JVM (the java.exe instance).



Thanks for this explanation. I was seeing this in a different light.
I thought of it - 'The client calls the session bean from another JVM other than the one for the earlier call.'

When it actually meant 'The client calls the session bean from another JVM other than itself.'

Thank you.

Regards,
Leena
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic