From: Gavin_King/Cirrus%<CI...@ci...> - 2002-05-16 01:48:04
|
I have just been doing some new performance tests. I am very pleased with the results. Hibernate's performance is still very competitive with handcoded JDBC in my test environment. Well, with a single caveat (the point of this post): The "atomic Session" feature is a total performance killer. I should have realised this earlier but I was always performance testing using hibernate.atomic_session=false. Atomic sessions allow the application to continue using a session, even when some kind of exception is thrown from the persistence layer. I can't think of a really good reason why applications whould need this feature. Atomic sessions are currently ENABLED BY DEFAULT. Everyone who wants to see performance potentially double should DISABLE atomic sessions by setting the system property (not a SessionFactory property): hibernate.atomic_session=false I will rip out this feature in the next version of hibernate, since the performance cost is ridiculous for a feature of such debatable value. Gavin |