You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Gabriel Belingueres <be...@gmail.com> on 2008/01/09 22:35:53 UTC

[S2] OpenSessionInView implementation with Spring

Hi,

I'm developing a new application using S2 + Spring 2.0 + Hibernate 3.2.5.

I wanted to know which would be the best way of implementing the Open
Session in View pattern in S2:
Is there any standard implementation for S2?

I''ve seen it implemented as a servlet filter, but I think it would be
good to have it implemented as an S2 interceptor (so we can still have
support for S2 declarative exception handling too.)

Or should rather stick with the Spring's
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter
filter?

Any experiences?

Regards,
Gabriel

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: [S2] OpenSessionInView implementation with Spring

Posted by Al Sutton <al...@alsutton.com>.
I tend to write it as a struts interceptor. That way I don't have to use
Spring, and all of the application specific cross cuts are configured in one
place (the interceptor stack), as opposed to having some as servlet filters
and some as interceptors.

Al.

(Before anyone says it, by application specific cross cuts I mean the cross
cuts where the code is part of the app and not part of a library)

-----Original Message-----
From: Gabriel Belingueres [mailto:belingueres@gmail.com] 
Sent: 09 January 2008 21:36
To: Struts Users Mailing List
Subject: [S2] OpenSessionInView implementation with Spring

Hi,

I'm developing a new application using S2 + Spring 2.0 + Hibernate 3.2.5.

I wanted to know which would be the best way of implementing the Open
Session in View pattern in S2:
Is there any standard implementation for S2?

I''ve seen it implemented as a servlet filter, but I think it would be good
to have it implemented as an S2 interceptor (so we can still have support
for S2 declarative exception handling too.)

Or should rather stick with the Spring's
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter
filter?

Any experiences?

Regards,
Gabriel

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org