hi all
        A session bean models a business process. An example of a business process
is verifying your credit card, or checking that your credit card history is
valid. The second type of bean is an entity bean. An entity bean is a
persistent object. A persistent object models data in underlying storage. It
's using object/relational mapping to take that data from your database and
put it in your object. Now, the big difference that you have to realize here
is that session beans and entity beans are solving completely different
kinds of problems. Session beans model business processes, whereas entity
beans are persistent objects.  Entity beans enable you to model data as
objects, rather than as relational rows.
        With entity beans you treat your business data as objects rather than as
relational rows. And it's very handy to treat them as objects because you
can manage them as objects and you can pass the references around to them.
So instead of treating your relational rows, you're actually deploying an
object and you're calling methods on it. A huge benefit here is that your
container can handle the persistence service for you, such as persisting
your employee objects to the database for you. You don't have to write any
database code, such as JDBC code, or SQL/J code. The result? An astounding
code reduction size and
error prone jdbc coding can be avoided.

this is taken from an article, can see more at
http://www.objectwatch.com/eddebate.htm

ramesh

-----Original Message-----
From: A mailing list for Enterprise JavaBeans development
[mailto:[EMAIL PROTECTED]]On Behalf Of EJB G
Sent: Friday, November 30, 2001 3:44 PM
To: [EMAIL PROTECTED]
Subject: Question On Architecture


What's Difference is following two approach
for server-side components.

Approach 1 :
Using Coarsed Grained Session Beans to perform
business logic interacting with database directly.
Approach 2.
Using Session Beans to interact with entity beans
which in turn interact with database.

As far as i know first approach gives better
performance than second one.Then why one should
go for Entity Beans.
We are bit confused whisc approach to follow.

Thanks in Advance.




__________________________________________________
Do You Yahoo!?
Yahoo! GeoCities - quick and easy web site hosting, just $8.95/month.
http://geocities.yahoo.com/ps/info1

===========================================================================
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".

===========================================================================
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".

Reply via email to