• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Enthuware question doubt

 
Omar Al Kababji
Ranch Hand
Posts: 357
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
this is the question:


Which of the following are true regarding the implementation of an EJB 3.0 JMS Message Driven Bean?

1) The class must have, directly or indirectly, a non abstract onMessage method.
2) It may implement finalize() method
3) It must implement setMessageDrivenContext() method.
4) None of these.


According to the exam simulator the correct answer is (1).

I agree that it is right if I am implementing the MessageListener interface, then i will have to implement its onMessage() method. but what if I am implementing some other type of message listener (as it is said that you can use other JCA connector .. bla bla bla) that has some other method, which its not called onMessage(). at this point the correct answer would be (4).

what do you think ??

 
Deepika Joshi
Ranch Hand
Posts: 268
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You are right if you consider JCA.
But question is not talking about JCA at the moment, and if you think about default, you choice is correct.

JCA is an option but Messagelistener is default, so there is no ambiguity about question.

Thanks.
 
Ralph Jaus
Ranch Hand
Posts: 342
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The question is
Which of the following are true regarding the implementation of an EJB 3.0 JMS Message Driven Bean?

The keyword here is JMS those message listener inferface consists of onMessage(). So (1) is correct.
 
Omar Al Kababji
Ranch Hand
Posts: 357
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic