• 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

Doubt in EJB 3 Spec.

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

I have a doubt in the specification.

"The class that
implements the session bean’s business interface and the class that implements a session
bean’s component interface delegate an invocation of a business method to the matching business
method that is implemented in the session bean class"

--As given in the "ejb-3_0-fr-spec-ejbcore.pdf" on page 71.

I am unable to understand what does the spec mean when it is talking about a "business interface" and a "component interface". In all the examples that i have seen till now, i have always come across cases where we create a business interface, declare it as remote or local, then we create a session bean that implements the business interface. So i am clearly in a fix when the spec mentions anything about a component interface. Has it got something to do with EJB 2.1?

Or is the spec trying to tell me something about container intervention in the calling of a session bean method.

I would be glad if someone could just tell me as to what does the spec mean by the above mentioned line.

Thanks in advance. :>

 
Ranch Hand
Posts: 10198
3
Mac PPC Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I guess it should talk about the style of declaring the interfaces...when it says Business interface, it should mean the EJB 3 style of declaring them and when it says Component Interface, it should be the old EJB 2.x style of declaring them. Well ranchers is this right?
 
ryan sukale
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Jothi,

Thanks for the reply. The problem is that i have no knowledge about EJB 2.x. Maybe that's why i was confused. Anyways, i read the spec form the beginning all over again and i suppose that what you are saying is correct. At least that way i got to revise the first 70 pages before moving ahead! lol
 
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ryan, what Jothi said is correct. EJB3.x is backward compatible so it also supports EJB2.x style of EJBs. In EJB2.x to define the remote/local interfaces of the bean, the bean interfaces had to extend from specific interfaces (javax.ejb.EJBObject/javax.ejb.EJBLocalObject). Such interfaces are referred to as the component interfaces. In simple terms, component interfaces refer to the EJB2.x view of the bean.
 
ryan sukale
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you guys for your help. I finally got it.

Regards,
Ryan Sukale
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,
I needed help on EJB 3.
Just wanted to know the book to be read and please someone could share Enthuware exam simulator.....
 
Jaikiran Pai
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Mohsin,

Welcome to JavaRanch Please create your own separate thread in this forum, since this thread was opened to discuss a different topic.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic