Why evicted object still remains as hibernate proxy?
I am invoking session.clear();
and in the next line I see on my debugger that one of the objects is still a hibernate proxy.
Is there any good explanation for such hibernate behaviour?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
session.evict does can not alter the content of the variable which is copied on the stack when calling evict hence the variable still points to the proxy.
AFAIK to ensure that you get reference equality it will return the initialised proxy evertime you session.get with the same id.