-->
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: DAO v.s. abstracting long sessions
PostPosted: Mon Jan 30, 2006 5:56 pm 
Newbie

Joined: Mon Jan 30, 2006 5:14 pm
Posts: 8
Location: Amsterdam, Netherlands
Hi,

DAOs abstract client code from making (Hibernate) specific data access calls.

For long sessions, however, it looks like there is no abstraction from storing the Hibernate session in e.g. the Web session context. Assuming a requirement of different persistence frameworks, wouldn't it make sense to add such an abstraction level too (i.e. abstract from Hibernate session + transaction, e.g. by adding a thin layer on top of Hibernate ) ?

Note: we are currently targeting for Hibernate 3.0, taking a "flattened" approach bas on the Hibernate 3.1 DAO factory approach.

When adopting Hibernate 3.1 later, it looks like the TransactionInterceptor can be useful; however this only supports session per request ?

Regards,

- Fernand.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 10, 2006 6:12 am 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
Go to the regular user forum if you want design advice, this is a forum about the book content only.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 10, 2006 10:45 am 
Newbie

Joined: Mon Jan 30, 2006 5:14 pm
Posts: 8
Location: Amsterdam, Netherlands
Thanks Christian,

will do that (actually: just did it).

Thanks,

- Fernand.


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.