-->
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.  [ 2 posts ] 
Author Message
 Post subject: commit executes update in background and hangs
PostPosted: Tue Jan 26, 2010 6:55 pm 
Newbie

Joined: Sun Jan 24, 2010 5:58 pm
Posts: 3
Hi,

I am fairly new to Hibernate and currently running into the following issue. When executing a simple query using criteria the program hangs when trying to commit. I.e.

tx = session.beginTransaction();

List x = session.createCriteria (Books.class)
.setFetchMode("authors",FetchMode.JOIN)
.setResultTransformer(Criteria.DISTINCT_ROOT_ENTITY).list();

tx.commit();

So, in fact the query gets executed (what I have seen from the log file, thanks to show_sql), but then Hibernate runs an update on that table. For what reason ever .... and this is where I (and the code) gets stuck.

What bother me most is that it has been working before .....

Any help, hint or just a direction where to look is greatly appreciated.

Thanks, Carsten


Top
 Profile  
 
 Post subject: Re: commit executes update in background and hangs
PostPosted: Wed Jan 27, 2010 3:52 am 
Expert
Expert

Joined: Tue Jun 16, 2009 3:36 am
Posts: 990
Hm,

it would be very helpful to know more details about this 'phantom'-update.
Please try to enable P6spy logging (P6spy is free) and report which
update hibernate is executing.

Guenther


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.