Community
Participate
Working Groups
Build Identifier: 2.2.0.v20110202-r8913 Currently EclipseLink only supports the creation of an Canonical Metamodel if JPA or Eclipselink Annotations are used. org.eclipse.persistence.internal.jpa.modelgen.CanonicalModelProcessor extends javax.annotation.processing.AbstractProcessor, so if only orm.xml and/or eclipselink-orm.xml are used to define mappings, CanonicalModelProcessor will not get triggered and no metamodel will be created. The JPA 2.0 Spec does not define that a JPA implementor has to provide any means to generate a canonical metamodel. Still, it would be useful to have to possibility to generate the metamodel even if no JPA/EclipseLink Annotations are used, allowing users to define their mapping solely in mapping files like orm.xml or eclipselink-orm.xml without losing the option to generate a canonical metamodel. Reproducible: Always Steps to Reproduce: 1. Create a JPA/Eclipselink project, using no JPA/EclipseLink annotations at all, just the orm.xml and/or eclipselink-orm.xml file to define mappings 2. Try to run the CanonicalModelProcessor 3. The CanonicalModelProcessor was not triggered at all, thus no metamodel was generated
Workaround is to put one javax.persistence or one org.eclipse.persistence.annotations annotation somewhere in your model.
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink