From: NHibernate J. <nh...@gm...> - 2009-07-09 15:22:07
|
[ http://nhjira.koah.net/browse/NH-1847?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18390#action_18390 ] Fabio Maulo commented on NH-1847: --------------------------------- With know which is the method used to re-associate the entity to a new session and without know which is the cascade used in the mapping this patch does not have sense. Applying it may mean obscure a wrong mapping. > EvictVisitor fix for non session associated collections > ------------------------------------------------------- > > Key: NH-1847 > URL: http://nhjira.koah.net/browse/NH-1847 > Project: NHibernate > Issue Type: Patch > Components: Core > Affects Versions: 2.0.0.GA, 2.0.1.GA, 2.1.0.Alpha3 > Reporter: Gediminas Guoba > > Hello, > Could you please apply a change to NHibernate.Event.Default.EvictVisitor class > method private void EvictCollection(IPersistentCollection collection) > and change line: > if (ce.LoadedPersister != null && ce.LoadedKey != null) > to > if (ce != null && ce.LoadedPersister != null && ce.LoadedKey != null) > Issue: > I have an object "A" whitch was reassociated with session. This object has a collection. When I trying to Evict object "A" from session I'm getting exception "Object is not set..." because collection is not reassociated with the session (I'm not sure if it is possible, because Lock method only allows proxy entities). > Thanks in advance, > Geddis -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://nhjira.koah.net/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |