I am having an issue in my application I don't know how to handle.
It's a web application. On each request before the response is sent security is checked to ensure the user is authorized to see the page. The User class uses lazy initialization on its collections, which are a collection of Groups the user belongs to and a collection of Pages the user can see that are not covered by their Group policies.
The issue I am having only happens if the user goes into the Admin area and attempts to edit themselves. Their user object is now persisted in the session. When the security runs it tries to persist the User object from the HttpSession and I get the exception referenced in the subject line. Even if I do a session.clear() beforehand, I get a "dirty collection reference" error on some actions.
Thanks,
Karl
|