-->
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.  [ 1 post ] 
Author Message
 Post subject: is the BLOB type always dirty for Hibernate?
PostPosted: Tue Apr 08, 2014 2:28 pm 
Newbie

Joined: Tue Apr 08, 2014 2:07 pm
Posts: 1
Hi guys,

This is the scenario:

I have an application based in Hibernate 3.3.1 + Spring 2.5.6 + SQL Server 2008 I have several tables which contain a blob like a property/column in the database.
Well, until now I did not realized because I did not have so many entries in the database. Now there is one of these tables which contain the blob like a property with 70000 entries and somehow sometimes we need to read almost of the entries at once for manipulating purpose.
When the read happened all these blobs for every entry are marked as "dirty" so next time I am doing anything with that table is updating all the entries that were retrieved before with the consequences of too much time and too many "updates" against the database. Really, I am not changing these blobs at all, just it seems like reading them is enough for hibernate to interpret that they must be updated later on.
Then I see 70000 calls to the database (MSSQL Monitor tool) like this:

Code:
update setPropertyWithBlob= ? where ID = ?;


That´s crazy.

I tried almost everything like deactivating caching, lazy-loads, ...

I will appreciate any help I can get !!

Thanks so much in advance


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

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.