Re: Difference between EJBLocalHome and EJBHome & EJBLocalObject and EJBObject ?
Wednesday, July 30, 2008 01:47 PM
Case 1 :
EJBs are meant to be distributed, that is - an enterprise bean can be deployed in a remote machine and you access it from your local machine. Here, the calling application of yours is residing in your local JVM and the EJB in a remote JVM(remote machine). Hope you are clear abt this JVM thing.
Now, when you just write some EJB for practice, something like your HelloWorldEJB, you deploy it in your own local machine. In this case, your calling program and your EJB reside in the same location, your local JVM( in the same machine ).
In Case 2, you use local home and local object since you know where the EJBs are, not just where they are but since you know that they are deployed where the client or the calling program is running.
Hope this helps ...
I would advise you to go through Google before posting a basic question here. You get lot better answers when you search on your own.