Enlightensoft's Blog

Helping in your each step

  • Categories

  • Authors

Issue with createCriteria result set, class name appended by _$$_javassist_

Posted by Pankil Patel on November 8, 2011

Issue:  _$$_javassist_ is appended after class name, when you are using createCriteria(xyz.class) which have <set> or <bag> (one-to-many) relationship with Object that having <composite-id> instead of <id>.

Resolution: Instead of Using createCriteria(xyz.class), use EntityName for Criteria Query.

Ex: DetachedCriteria detachedCriteria = DetachedCriteria.forEntityName(“xyzSearch”);

Impact of Issue:

  1. For java, if you are using any code which have  comparison with class name it will fail in that case.
  2. If you are using any communication by RMI like: Spring BlazeDS for Flex & Java, It will not able to cast the Object in proper format & will give result in generics Object format.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: