-->
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.  [ 3 posts ] 
Author Message
 Post subject: Design question - custom persister?
PostPosted: Mon Feb 07, 2005 2:17 am 
Newbie

Joined: Sat Feb 05, 2005 8:11 am
Posts: 16
Location: Melbourne, Australia
I've read your fine book pretty much from cover to cover, and am just getting ready to get my hands dirty, but first I have one important question which wasn't answered by the text.

In my preliminary design, I have two classes/tables which will contain nothing but balances, being aged balances for the Client class and the Debt class. These will be among the most volatile tables in the system - most of the others contain static, rarely updated info or are mostly insert-only.

For this reason, in SQL terms, I had in mind to perform all the updates to these tables using SQL expressions, something like this...

UPDATE DB_BALANCE SET PAID = (PAID+ 23.45), COMMISSION = (COMMISSION + 2.35), ...

Obviously, this beans bypassing the normal persistence mechanisms, and until today I had in mind to do this by making my balance classes immutable and updating them in hand-written DAO classes. But today, I came across the ClassPersister interface, and I'm wondering whether perhaps I shouldn't write my own custom ClassPersisters instead.

So that's the question. Should I write custom ClassPersisters, or is there some better way of doing this that I've missed so far?

Oh, and if I do write my own ClassPersisters, what is the best persister to extend?

Running Hibernate version 2.1.

TIA for any and all suggestions,
Luke


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 07, 2005 1:39 pm 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
There is a better chance to get an answer to this in the normal User forum. I only answer questions about the book and CaveatEmptor here.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 07, 2005 6:20 pm 
Newbie

Joined: Sat Feb 05, 2005 8:11 am
Posts: 16
Location: Melbourne, Australia
Whups! Sorry about that. Feel free to delete this thread.

Cheers,
Luke


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