when i use mono-repo to manage my projects, i try to use springdoc to colloect swagger.json then get a problem.
spring-boot-maven-plugin configs as follow:
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>start</goal>
<goal>stop</goal>
</goals>
</execution>
</executions>
<configuration>
<jmxPort>9002</jmxPort>
<jvmArguments>-Dspring.application.admin.enabled=true</jvmArguments>
<maxAttempts>3000</maxAttempts>
<wait>1000</wait>
</configuration>
</plugin>
when i have two projects run in order, lasted one will got java.rmi.server.ExportException: Port already in use: 9002;
The first one also occupies port 9002.
Comment From: snicoll
Are you running Maven with -T (parallel build)? If you do, then each module should have a unique port as they may execute integration tests at the same time.
Comment From: glmapper
Thank you. I have solved this problem in other ways