[hibernate-dev] HCANN, AnnotationFactory and TCCL

Steve Ebersole steve at hibernate.org
Thu May 28 00:34:44 EDT 2015


WildFly consuming ORM 5.0 is still hitting one last TCCL issue with HCANN.
It happens in
the org.hibernate.annotations.common.annotationfactory.AnnotationFactory#create
method trying to build the "annotation proxy class".

There are a few possible approaches to resolve this...

The simplest potentially effects other HCANN consumers, so we'd obviously
all need to agree.  Anyway, the simplest approach is to use the ClassLoader
for annotation @interface Class rather than the TCCL.  I do not see a
problem with that, but it would change some semantic.

The only other workable approach (without redesign of HCANN) I could think
of is to basically make a copy of AnnotationFactory and copy it into ORM.

Sure I could overload AnnotationFactory#create to optionally accept a
ClassLoader, but that introduces a hard dependency on new specific version
of HCANN.

Open to other suggestions.  Thoughts?


More information about the hibernate-dev mailing list