Entity Bean Best Practices

  • Fine-grained versus coarse-grained Entity beans— Many designers make the mistake of modeling all their entities as EJBs. The decision of what entities to model as EJBs and at what level of granularity is a critical issue to overall system performance.

  • Modeling technique— Use the appropriate modeling techniques for your job. Use JDBC, JDO, EJBs, or other data access techniques as appropriate.

  • Business logic in Entity beans— Entity beans should encapsulate additional business logic such as marking an account to be closed, determining the type or level of users, or the total for an order. Advanced features of the WebLogic Query Language make this easier. This enforces the MVC architecture.

  • Optimize data access— It's important ...

Get BEA WebLogic Server™ 8.1 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.