This repo demonstrates a way of handling the combination of AspectJ and Immutables annotation processors.
It consists of four modules:
- aspectj -- an implementation of a cross-domain concern, @LogExecutionTime, using AspectJ
- immutables -- an implementation of an immutable model, using Immutables
- mixed-service -- an attempt to use @LogExecutionTime annotation when a module has an immutable model, using Immutables
- pure-service -- an attempt to use @LogExecutionTime annotation and importing another module that uses Immutables
The pure-service module can be compiled, but the mixed-service needs extra configuration of aspectj-maven-plugin excluding immutables from AJC. See this PR for the changes.