Hi,
Version: 1.2.0.GA
.NET: 2.0
I am attempting to do a deep clone of my domain object by initially doing a "MemberwiseClone" and then adjusting the properties / relationships per my business rules.
This was working great for the first day... but now I am getting data integrity errors due to NHibernate viewing the newly cloned object as "already associated with a session". This happens on the "Save" call when NHibernate does a "GetEntry" on the IdentityMap in SessionImpl. From what I understand, this will perform an "==" operation, so I am not sure how this "cloned" object can reference another object in memory.
Also, I believe that this became a problem when the object I am cloning was a NHibernate Proxy, rather than the underlying implementation.
Thanks in advance,
Aaron
_________________ Thanks,
Aaron
|