why we use home interface in EJB. In RMI we dont have any concept like home interface.why we particularly go for Home Interface
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Anonymous
Posted On:   Tuesday, April 29, 2003 04:32 AM

Both RMI and EJB are distributed applications. In EJB we use Home interface which is not avaliable in RMI. There must be several reasons for using Home Interface of EJB. can any one give reason for this?

Re: why we use home interface in EJB. In RMI we dont have any concept like home interface.why we particularly go for Home Interface

Posted By:   Nick_Maiorano  
Posted On:   Tuesday, April 29, 2003 06:49 PM

Vishnu,



By posing this question, you seem to be comparing RMI and EJB as if they were the same type of technology and they are definately not. RMI is a lower level technology that allows java objects to be distributed across multiple JVMs. Essentially, RMI abstracts sockets and inter-JVM communications.



EJB, on the other hand, is a technology built atop of RMI but does so much more than allow java objects to be distributed. It is a framework that allows you to build enterprise applications by (among other things) abstracting transactions, database access and concurent processing.



Having said this, the answer to your question is the following. The home interface is EJB's way of creating an object. Home interfaces act as factories to create session beans and entity beans. These factories are provided by the application container and take care of many low level details. Since RMI is a lower level technology, it does not offer the home interface. You would have to create it yourself.

About | Sitemap | Contact