>From what I've read and heard, there are essentially 2 issues with giving an EJB both local and remote interfaces:
1.Differences in Remote and Local parameter passing - a.In a Remote call, changes made in the method body to the state of an object referenced by an argument to the method aren't visible to the client. b.In a local call, they are. 2.Optimal granularity of method return values - In a remote situation, we want to minimize network traffic by getting a lot of data in one (course-grained) call, rather than a lot of data in many (fine-grained) call: customer.getCustomerValue(), returning a CustomerValue object that contains name, address, phoneNumber,etc., rather than customer.getName(), customer.getAddress(), customer.getPhoneNumber(), etc. all going accross the wire. In a local situation however, fine-grained calls seem more natural (bit of an opinion). So, provided you don't take advantage of 1.b and come up with an interface that works for local and remote clients with respect to 2., I think you can do it. Mike --- JavaSoft <[EMAIL PROTECTED]> wrote: > Hi all, > is it legal that an entity bean has 4 interfaces ? 2 are Local > interfaces, > and other 2 are remote interfaces. > Because my entity bean is used by 2 clients remotely and locally. The > problem why dont i just make it remotely is because performnce. > Remotely is > slower than locally right ? while one of entity clients is in same > jvm with > the entity bean and need fast performance, thats why i want to use > locally > way to access the entity bean. > > === > thx, > a Java Addicted > > =========================================================================== > To unsubscribe, send email to [EMAIL PROTECTED] and include in > the body > of the message "signoff EJB-INTEREST". For general help, send email > to > [EMAIL PROTECTED] and include in the body of the message "help". > __________________________________________________ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ =========================================================================== To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff EJB-INTEREST". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".
