aspose file tools*
The moose likes Object Relational Mapping and the fly likes Is hibernate not slow for usage? Is it still suitable for User login Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Is hibernate not slow for usage? Is it still suitable for User login" Watch "Is hibernate not slow for usage? Is it still suitable for User login" New topic
Author

Is hibernate not slow for usage? Is it still suitable for User login

Monica. Shiralkar
Ranch Hand

Joined: Jul 07, 2012
Posts: 639
Hibernate has advantages but is quite slow. Is it suitable for user login etc?

thanks
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

I used it for user login. Nobody complained.
Will Myers
Ranch Hand

Joined: Aug 05, 2009
Posts: 324

I've not found Hibernate any slower than straight JDBC and in some situations can give the illusion of better performance, of course you can use it badly and it will be dog slow
soundar rajan
Greenhorn

Joined: May 08, 2013
Posts: 16
Hibernate having the caching mechanism; we can get some performance improvement after caching the SQLs.

Also we have to define strategies for fetching data from the database based on the requirement either lazy or eager

The EAGER strategy is a requirement on the persistence provider runtime that data must be eagerly fetched.
The LAZY strategy is a hint to the persistence provider runtime that data should be fetched lazily when it is first accessed.

We have to avoid more reference tables when we designing the Data Model for hibernate.
Monica. Shiralkar
Ranch Hand

Joined: Jul 07, 2012
Posts: 639
thanks.I had read this in the section of advantages and disadvantages of Hibernate.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41518
    
  53
Hibernate certainly introduces a non-negligible overhead, for example it tends to cause lots of small queries retrieving IDs to be run against the DB. For an app with 10 users that may not matter; with 1000 users, that may kill the DB. I would think that most ORM systems suffer from similar issues, and should thus be used with care. The SQL they generate ORMs is just not well optimized.

I agree that one must carefully evaluate where (and whether) it makes sense to use built-in caches of the ORM vs. putting in place caches in the application code.


Ping & DNS - my free Android networking tools app
Monica. Shiralkar
Ranch Hand

Joined: Jul 07, 2012
Posts: 639
thank you
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Is hibernate not slow for usage? Is it still suitable for User login