-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Uses for Hibernate
PostPosted: Fri Apr 02, 2004 4:33 pm 
Newbie

Joined: Wed Mar 31, 2004 6:42 pm
Posts: 4
Would you folks use hibernate in a read only scenario? By this, I mean, is hibernate the appropriate tool for querying a database without worrying about writing data to the database? I'm new to the technology and love how it works for persisting objects I build. What I want to know is, should I be using hibernate to grab data from the database and build my objects for me?


Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 02, 2004 6:46 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 3:00 pm
Posts: 1816
Location: Austin, TX
Personally, I'd say it depends on the nature of the usage. I would say definitely not for decision support type usages. But if its simple reporting or something along those lines it still makes sense to a degree.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Apr 03, 2004 1:38 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 7:19 pm
Posts: 2364
Location: Brisbane, Australia
If your requirements don't change (much) you may just want a simplified database wrapper such as IBatis.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Apr 03, 2004 4:54 am 
Hibernate Team
Hibernate Team

Joined: Thu Dec 18, 2003 9:55 am
Posts: 1977
Location: France
i'm working on a "read only" project, we'll bench both full jdbc and hibernate prototypes.
The goal is to retrieve a lot of data and "give it" to a web service.

JDBC proto:
+ optimized queries given by BDA
+ give exactly what is needed
- if tomorrow they ask us to add other table fields.... ughhh have to study again the 50 lines query
- have to know about caching since the data are updated 2 times per day

Hibernate proto:
+ short time of development
+ pluggable cache, and with it incredible performances if the objects have been loaded...
+ you can easily update graph of object definition (so the future needs)
+/- you can optimized sql generated by knowing all about HQL (not always easy but forum helps a lot)
+/- you can reuse the optimized dba query by using SQLQuery API, but in this case.... "why using hibernate?"
- you may need to map non business objets, i'm thinking about parameter tables, for example many-to-one doesn't allow a "where attribute" which could filter an association on a parameter which is only updated every 2 years, so you have to map it. But i'm looking at the formula option... it could solve this need

If this can help you....


Anthony


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.