I'm getting an AssertionFailure on flush. I know why. It's because of some auditing in a post update listener. When a many-to-one property changes, I get the old and new Id of the changed property, something like this:
var id = ((IEntity) old).Id.ToString(); This code has been working in production for a good while. But now I have added a lazy collection to old. It seems that calling Id initializes not only the entity but it's collection also. Now, I'm not sure why the collection would be initialized, but that's not my question. What I'm wondering is, is there anyway to get just the Id from from proxy without it being initialized? I would guess that NH does this internally sometimes? By the way, I have a workaround, FlushFixEventListener, which has been described previously on this list. However it makes me feel a little queasy. -- 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.
