Hi,
I use 'my.hibernate.properties' -- not the standard 'hibernate.properties' -- as Hibernate configuration filename.
I want to disable CGLIB for debugging purposes. I add to my.hibernate.properties the line:
Code:
hibernate.cglib.use_reflection_optimizer=false
My code for building a Configuration object is:
Code:
Properties fileProps = new Properties();
InputStream is = class.getResourceAsStream("/my.hibernate.properties");
props.putAll(fileProps);
Configuration _hibernateConf = new Configuration()
.setProperties(props)
.addClass(Myclass1.class)
.addClass(Myclass2.class)
...
CGLIB does not get disabled. The only workaround I found was to create a standard hibernate.properties with the disabling line, then it works ok.
Regards,
Adrian.