[hibernate-dev] Annotation Processors

Hardy Ferentschik hardy at hibernate.org
Tue Dec 3 10:21:23 EST 2013


On 3 Jan 2013, at 13:29, Steve Ebersole <steve at hibernate.org> wrote:

>>>  And in fact we get a slew of errors from running `javac -proc:only`.  We just happen to eat/ignore them.
>> 
>> Sure, in some cases you might have to run the processors as part of the main compile. Still, imo nothing wrong with the way
>> we do it and it makes the build cleaner.
> 
> "Cleaner" how?  

Cleaner in the sense of having more explicits steps and tasks. But for sure that is subjective.

> Have you seen the hoops we jump through to get this to work?  

Sure, I’ve seen the setup, but I don’t see the hoops.

> Not trying to be argumentative,

Not me either. 

> just that I don't see the benefit "compile but don't really compile" buys us.

Back in the Maven days there were issues with the Maven compiler plugin. It would just swallow all output from
the annotation processing and you could not pass command line arguments to the processor. Also, with Maven you 
had to add the annotation processor to the main dependency list (compared to a compiler plugin scoped dependency).
For all these reason I always preferred the maven-processor-plugin and a dedicated annotation processing task/phase.

I am told that the problem with the compiler plugin is fixed and obviously with Gradle this configuration problem was/is
no issue. 

—Hardy





More information about the hibernate-dev mailing list