Hi everyone, I cleared the cert a month back, but was never satisfied with the way CMR has been handled in most BOOKS. There has always been a confusion in the role of Container Managed Relationships and why exaclty they have been introduced? Also why are only Local Component Interfaces required as return types for CMR? If some one could give a detailed explanation of the above mentioned it would be of extreme help to me in understanding this particular part of EJB's!!!
Best Regards,<br />Rajnish Bhasin.<br />SCJP<br />SCWCD<br />SCBCD
Before EJB 2.0, entity EJB developers had to manually manage relationships between entity beans. The EJB 2.0 specs enable the entity bean container to manage entity relationships based on a referential integrity model. When an entity is added to or removed from a relationship, all other related entities and relationships are updated to maintain referential integrity. The entity beans which participate in a relationship can have remote interfaces, but the view that an entity bean presents to other beans in a relationship should only be the local interface. This will allow beans participating in a relationship to have optimized access to each other's methods by bypassing RMI invocation overheads. Also check out https://coderanch.com/t/159105/java-EJB-SCBCD/certification/elaborate-reason-Local-interface-EJB Thanks