Entity beans encapsulate the persistence logic so it doesn't have to be mixed in with
your business logic
 
Entity beans are shared my multiple sessions, so cached data doesn't have to be retrieved
multiple times
 
When using CMP, the container can manage the mapping to relational databases
 
However, to make things a bit more interesting, they are not always the right answer....
I'm sure you will find MANY discussions on this topic in the archives of this list . In short,
they have a considerable amount of overhead, esp. the finder methods. For bulk loads and
complicated queries to a relational database, you're probably better of with JDBC in a
session bean.
 
Hope this helps,
 
Frank
-----Original Message-----
From: A mailing list for Enterprise JavaBeans development [mailto:[EMAIL PROTECTED]]On Behalf Of Tarun Dewan
Sent: Wednesday, June 21, 2000 12:29 AM
To: [EMAIL PROTECTED]
Subject: Session & Entity EJBs.

I have one question.
 
 
What are the benefits of accessing database through Entity Beans instead of  Session Beans?
 
Any ideas.
 
 
Thanks,
 
Tarun Dewan
 
 
 

Reply via email to