thanks... reading about that now :) 2009/2/10 Fabio Maulo <[email protected]>
> 2009/2/10 Paulo Quicoli <[email protected]> > >> Hi Gustavo, >> >> very interesting your articles... i didnt see the code examples yet... but >> what if my Repository is using an Unit Of Working pattern ? Well, something >> like this: >> >> >> http://blogs.hibernatingrhinos.com/nhibernate/archive/2008/10/08/the-repository-pattern.aspx >> >> i would have to change my repositoy approach ? > > > http://fabiomaulo.blogspot.com/2009/01/aspect-conversation-per.html > > Well... your case a showing an issue I'm talking about from long time... > That implementation of Repository is wired to a specific implementation of > "SessionProvider". > We prefer to have a Repository implementation wired only with NH and use > the ICurrentSessionContext fo the session management stuff. > BTW, if you want jump to something else, what you need is only change the > implementation of > private static ISession GetSession() { return SessionProvider.GetSession(); > } > to > protected ISession GetSession() { return factory.GetCurrentSession(); > }Something > about ICurrentSessionContext is available at the bottom of this article > > http://fabiomaulo.blogspot.com/2008/12/implementing-conversation-per-business.html > > and, obviusly, in NHibernate In Action book. > -- > Fabio Maulo > > > > -- Paulo R. Quicoli Editor Técnico - ClubeDelphi Magazine - DevMedia --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "nhusers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~----------~----~----~----~------~----~------~--~---
