-->
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: Customizing Hibernate to store historical data
PostPosted: Thu Mar 03, 2005 12:28 am 
Newbie

Joined: Sat Feb 26, 2005 10:10 pm
Posts: 8
Hibernate version:3.0

Hi,

We are planning on customizing hibernate to store historical data. I am aware of http://blog.hibernate.org/cgi-bin/blosxom.cgi/2004/06/19/ and all the threads in forum related to it. We are not fond of the above prescription because we have a large document that we are trying to store revisions for. The # of attributes for each document is dynamic. And only a small number of attributes can change upon each revision. We are not too concerned about the space required to clone the object for each revision. We are concerned about the time used to insert these dynamic properties because we have many inserts happening at the same time. As an example of scale, we can be concurrently try to 100k inserts in which each insert is 100k (the diff with the older version is already done by insert time).

We are looking onto other possibilities. So far these are some ideas to store revision (not exactly a Hibernate issue):

1) Store full copies of key revisions, and store the commands to gather the revisions in between. For example, store revisions 1, 6, and if 4 is requested, we will re-apply the commands on key revision 1, up to version 4.

2) For the objects with dynamic properties, store the start and end version of each property, based on the parent object's version. We can retrieve an object by looking for attributes whose start version is <= the object's version (I can elaborate on this if anyone is interested).

Q: Are there other ways to store revision that people have seen?
Q: Are their plans for Hibernate to support historical data?

Second part of my question is about the way I plan to extend Hibernate to support historical data for all the objects stored through my storage layer.
a) we plan on extending Basic*Persister, parse the queries, and modify the query that Hibernate generate according to whichever historical strategy we choose. We are attempting to parse and modify the queries during run time, and not hardcode the queries in the mapping file. Am I digging a grave for mysyelf?


Thanks!

Theen-Theen


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.