I've got a mixed Scala/Java maven project where the application code, unit and integration tests are written in Java but performance tests are written in Scala.
The Scala performance tests depend on a couple Java Integration Test classes that have @Data
Lombok annotations. In order for getters and setters to work I must compile JavaThenScala
, which I can do through IntelliJ Scala Compiler settings.
My question is - Is there a way I can set my maven plugins to do the JavaThenScala
compilation without adjusting the IntelliJ settings since I would like to deploy the code elsewhere?
I am trying to use the compileOrder
configuration but it doesn't seem to do the trick for me.
My maven plugins:
<build>
<plugins>
<plugin>
<groupId>met.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<version>4.0.0</version>
<configuration>
<compileOrder>JavaThenScala</compileOrder>
</configuration>
</plugin>
<plugin>
<groupId>io.gatling</groupId>
<artifactId>gatling-maven-plugin</artifactId>
<version>3.1.1</version>
</plugin>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>