users@jaxb.java.net

ClassTailor and its use

From: Hari Selvarajan <hari_at_dcis.net>
Date: Mon, 20 Sep 2010 12:28:14 -0700 (PDT)

Greetings,

I came across the use of ClassTailor - and the fact that it generates
classes at runtime - while trying to debug a PermGen problem we're having
with our application. From the discussion here:

http://forums.java.net/jive/message.jspa?messageID=173757

I noticed that there's a system property
(com.sun.xml.bind.v2.bytecode.ClassTailor.noOptimize) that, when set, turns
off the ClassTailor and the classes it generates.

Given that the Sun JVM optimizes reflection by generating classes ("fast
reflection"), I wondered what the classes generated by the ClassTailor
(JaxbAccessor_F and friends) were used for. Other frameworks like Hibernate
have turned off the use of CGLIB, etc. for reflection optimization by
default:

http://opensource.atlassian.com/projects/hibernate/browse/HHH-227

Could someone help me understand what the synthetic classes are used for,
and the impact on performance if I turn off this option? In our application
Jaxb generates several hundred classes, and if the impact on performance by
turning off ClassTailor is minimal, it would save us some precious permgen
space.

Thanks,

- Hari
-- 
View this message in context: http://old.nabble.com/ClassTailor-and-its-use-tp29762778p29762778.html
Sent from the java.net - jaxb users mailing list archive at Nabble.com.