Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-12521

Component annotation processors fails incremental compilation in IntelliJ

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 11.0.7.Final, 12.0.0.Final
    • 11.0.5.Final, 12.0.0.Final
    • Build
    • None

      The component annotation processor maps multiple input Java classes to a single generated class/resource. It uses the sourceElements parameter of Filer.createSourceFiles() to attach all those input classes to the generated class/resource.

      IntelliJ used to ignore the source information, but 2020.3 Beta is now using it to delete the generated class/resource whenever one of the input classes changes. But because some of the input classes are not being compiled, the annotation processor is unable to generate the class/resource from scratch.

      E.g. when any core annotated component class changes, the CoreModuleImpl class and the META-INF/services/org.infinispan.factories.impl.ModuleMetadataBuilder are removed. The annotation processor then fails with

      @InfinispanModule annotation not found in any class, please perform a clean build. Found components [...]
      

              dberinde@redhat.com Dan Berindei (Inactive)
              dberinde@redhat.com Dan Berindei (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: