It seems that multiple versions of OrgUnitType had been
loaded. The error message should be interpreted as that
the super class of OrgUnitImpl is a different version of
OrgUnitImpl from the version that the cast operator
(i.e. the class generated by Javassist) expects.
If my observation is true, this is not a problem of Javassist
or it cannot be solved with reflection. You should carefully
redesign the delegation scheme by class loaders.