-->
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.  [ 7 posts ] 
Author Message
 Post subject: Article comparing Hibernate with Toplink
PostPosted: Tue Jan 27, 2004 4:22 pm 
Newbie

Joined: Tue Jan 27, 2004 4:18 pm
Posts: 3
I recently had a chance to use Hibernate and Toplink on two very similar J2EE projects. I wrote a brief document summarizing my experience with these two systems. The article is a bit high-level but I tried to put in code fragments in case people want to more details.

The URL is: http://www.calextech.com/articles/HibernateToplink.pdf

I'd appreciate any comments that people might have.

Bruce Kissinger


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 27, 2004 4:24 pm 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
I get a 403.

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject: 403 error
PostPosted: Tue Jan 27, 2004 4:37 pm 
Newbie

Joined: Tue Jan 27, 2004 4:18 pm
Posts: 3
Sorry - our web server blocks certain hosts or ISPs because of frequent hacking attempts. I opened the server up a little bit more - you should be able to get to it now.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 27, 2004 4:54 pm 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
- Figure 3 looks like a Hibernate query, not Toplink

- Toplinks Expression builder is much more like Hibernates Criteria queries, there are good usecases for both a string based query language and an object-oriented query/expression API

- You don't have to check for (id == 0), Hibernate does this for you, check saveOrUpdate() and unsaved-value

I don't agree with all of your conclusions. For example, I find Toplinks mapping workbench buggy (it crashed every time I tried to use it) and I think most developers are faster with a good XML editor and a DTD. To be frank, this overview is not really what I would need before I make a decision for either framework.

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 27, 2004 4:57 pm 
Newbie

Joined: Tue Jan 27, 2004 4:18 pm
Posts: 3
Thanks for the feedback!

Actually - I tried using saveOrUpdate() and it didn't work. That's why I resorted to handling the save() or update() manually.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 27, 2004 6:43 pm 
Hibernate Team
Hibernate Team

Joined: Tue Sep 09, 2003 2:10 pm
Posts: 3246
Location: Passau, Germany
Most likely you didn't use unsaved-value or set it to a wrong value.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 28, 2004 10:30 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
Hi!

This answer comes from the top of Val Thorens and with a "strained" leg so i got the time to answer :)

I have looked forward to see someone (other than me) compare Hibernate with Toplink, and now you have done it i'll comment on it...

1. You write Toplink supports any database that has an JDBC interface and "only" list a fixed set of databases for Hibernate. Hibernate ALSO supports any database that has an JDBC interface - but you are not guarenteed to get all the features (think of the JDBC interface for CSV files) .... the same goes for Toplink.

2. The "complex objects relationships" mark is very vague....all those names is specific for both hibernate and toplink - you can't just compare them on their name since some of these are different in the two products.

3. The Toplink screenshot is unreadable (very blurry) ?
(and i must say that i have not yet succesfully used toplinks gui ... always fell back to tune by hand the xml...but i guess it is a matter of taste)

4. Query'ing ...you should list the different query possibilities in the two products! Hibernate has HQL, Criteria and Native SQL ....Toplink got QBE, Native SQL and I also think they got some kind of Stored Procedure support - but their docs are kinda vague on this point.

5. You say Toplink supports composite keys directly....and implies Hibernate does not by saying you need to implement equals() and hashcode()....is Toplink doing something magically since it does not require this on it's objects? .....

6. ...and I don't yet know of a graphical mapping tool being developed...what is the specific tool you are referring to ?

7. Hibernate also have commercial support!

The Topic is interesting, but i don't think the article brings anything new to the table and it does not even compare the two products - it only lists what is possible in (almost) all ORM's i know off....it's not enough to even start deciding anything - sorry :)

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 7 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.