Re: EmptyInterceptor SetSession / Session Factory Breaking Changes

"Fabio Maulo" <[email protected]>
Newsgroups gmane.comp.windows.dotnet.nhibernate.devel
Message-ID <[email protected]>
2008/6/19 Ayende Rahien <[email protected]>:

> This method allow to the interceptor to know what the session it it
> attached to.It is important if you have interceptors that needs to access
> their parent session.
>
>
Do you think it is useful for any kind of session or only when the user
specify an interceptor for a session ?
session-scoped (and *only *session scoped)

The comment about "session-scoped interceptor" is not a minor thing. Like
you know the user have the ability to set the interceptor at the
sessionFactory level (mean in configuration) and this interceptor will be
used for all sessions. In this scenario we can't assign the session to the
interceptor because the interceptor must be tread-safe and multi-session.
We can add the feature but it is very important to write something in the
documentation to let know to our user that it work only for
session-scoped-interceptor that mean:
sessionFactory.OpenSession(new MyInterceptor());

*The user can't use a static instance or a singleton.*
If we agree I need help to write a documentation chunk to explain how use
this feature.
-- 
Fabio Maulo

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php

_______________________________________________
Nhibernate-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nhibernate-development
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.