SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
I think, therefore I exist -- Rene Descartes
SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
While designing the home interface how do you choose between home business methods and home finder methods. I know the later retrieves the remote references and client will have to do remote calls to get the data, which will have network overhead. Some say that just to give the data to the client we can use home business methods to return objects other than remote references. Then what is the use of home finders?
SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
To get to the data he wants, he iterates through the collection and calls business methods of the remote interfaces. This can be network heavy. If we have 5000 remote interfaces in the collection, it will be atleast so many number of remote calls!!!
I think, therefore I exist -- Rene Descartes
Now the question is when to choose between entity home finders and entity home business methods. If the home business methods returning a collection of data are reducing the network traffic, why do you want to use finders, except for findbyprimarykey?
SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
2) Second solution is to have a HOME business method say getPersonsBySex. This will return a collection of Person objects. Now the client can call getters on these any number of times, and these will not be remote.(Although the data is stale. But stale data is better than network overhead!)
I think, therefore I exist -- Rene Descartes
I stress again the difference is in HOME business methods and HOME finders methods!!!
I think, therefore I exist -- Rene Descartes
SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
I think, therefore I exist -- Rene Descartes
SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
I think, therefore I exist -- Rene Descartes
SCJP1.2<br />SCWCD1.4<br />SCBCD1.3
Don't get me started about those stupid light bulbs. |