try to report more info from annotation processor failure
This commit is contained in:
parent
8dd0ef5198
commit
f111d1a1a1
|
@ -208,7 +208,12 @@ public class JPAMetaModelEntityProcessor extends AbstractProcessor {
|
|||
createMetaModelClasses();
|
||||
}
|
||||
catch (Exception e) {
|
||||
context.logMessage( Diagnostic.Kind.ERROR, "Error generating JPA metamodel: " + e.getMessage() );
|
||||
final Throwable cause = e.getCause();
|
||||
final String message =
|
||||
cause != null && cause != e
|
||||
? e.getMessage() + " caused by " + cause.getMessage()
|
||||
: e.getMessage();
|
||||
context.logMessage( Diagnostic.Kind.ERROR, "Error generating JPA metamodel: " + message );
|
||||
}
|
||||
}
|
||||
return ALLOW_OTHER_PROCESSORS_TO_CLAIM_ANNOTATIONS;
|
||||
|
|
Loading…
Reference in New Issue