This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Little Book of Impediments (e-book only) and have Tom Perry on-line!
See this thread for details.
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

Entity Beans and DAO

 
muhilan govin
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ranchers,

Entity Beans finder methods have performance issue. So I planned to use DAOs to directly read from DB using JDBC and SQL and return TOs.

But I do need to create/update Entities. Is it fine to use DAOs to query and create TOs for search operations and use entity beans when it comes to creation and update?

Basically can the "same" Entity take up role as TO in finder methods and as Entity Beans during create scenarios? Without using EJB 3, would this be a good soln? Do we have real time systems implemented this way?


Thanks and regards,
Muhilan
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you doing SCEA5? If so, is "Entity Bean" really what you want to be promoting?
 
muhilan govin
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am doing the assignment on J2EE 1.4 where Entity Beans(EJB 2.1) are considered.

Thanks and regards,
Muhilan

 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My most sincere apologies for the SCEA5 assumption.

I think you need a political answer, as opposed to a pragmatic answer.

On the Sun exam, Sun wants you to use their technology, and demonstrate that you understand how it works. Your reservations about EJBs might be correct, but the SCEA exam is no place for you to start asserting your prejudices against entity beans, even if your prejudices are founded in fact. Don't wave your finger in the nose of the SCEA exam people.

So, I'd use the finders where using a finder is appropriate. Demonstrate that you know when and how to use them. That is what Sun wants to see, even if it might not be the best thing to do in the real world.

Sometimes you gotta play by the other people's rules.

-Cameron McKenzie
 
muhilan govin
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Sir. Nice reply... Btw I am changing my design :-) i dont want to risk my 375 dollars!!!

Regards,
Muhilan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic