Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

quesiton abt using DAO with entity bean

 
Maneshi tuli
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi ,
what is the benifit of using DAO with enetity bean ?
reduece dependenies on database
reduce dependencies on application server

As i think , it reduce the coupling between database and bean .but whitzlab says answer 2 is correct.
Its confusing . Plz can any body help in explaing this.
 
Deepak Pant
Ranch Hand
Posts: 446
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Manesshi,

DAO is used in following two scenarions:
(a) With BMP Entity Beans
(b) With SLSB or SFSB

In both the cases it is primarily used to reduce the Applications dependence on a particular database.

If you are using CMP then most of the times, Application Servers provide additional capabilities which locks down the dependence on the application server. For example: In BEA you can create ready only or read mostly beans for providing caching mechanisms. Using such an implementation locks your code down to BEA.

Hence both the choices are correct.

Hope this helps,
Deepak
 
Michael N.Tang
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
DAO abstracts the consistency container independent and so as application server independent. The first answere is meaningless because with or without DAO, your application still depends on the database.

-Michael

[ February 27, 2005: Message edited by: Michael WhateverMakeTheNameUnique ]
[ February 27, 2005: Message edited by: Michael WhateverMakeTheNameUnique ]
 
Nicholas Cheung
Ranch Hand
Posts: 4982
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Michael,

I am afraid your name is still violates the naming policy.

Could you please change it accordingly at My Profile?

Nick
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic