File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Object Relational Mapping and the fly likes ClassCastException from Domain object to CGLIB??? Why is it trying to cast that way Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "ClassCastException from Domain object to CGLIB??? Why is it trying to cast that way" Watch "ClassCastException from Domain object to CGLIB??? Why is it trying to cast that way" New topic
Author

ClassCastException from Domain object to CGLIB??? Why is it trying to cast that way

Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17250
    
    6

Anyone ever come across the scenario where you eager fetched some Domains so that they are the real domain object, that later when accessing them Hibernate tried to cast them to CGLib Proxies instead?

Our Domain objects are Groovy, so it is possible that Groovy is doing something weird accessing the class attribute.

Thanks

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: ClassCastException from Domain object to CGLIB??? Why is it trying to cast that way