Closed Lopfest closed 2 years ago
Maybe you found a solution because I have faced the same problem?
Nope, I have stopped using it. It would be nice to have a plugin that creates the documentation in compile phase like it was with kongchen's swagger-maven-plugin.
@Lopfest The plugin just saves the file during integration test phase. If you use the plugin along with openapi-diff-maven then change the phase of openapi-diff-maven from 'integration-test' to 'verify'. In my case zombie process appeared when the openapi-diff-maven was preventing the post-integration-test to run stop goal.
not reproducible.
If i run: mvn integration-test the process still running ...
mvn -v Apache Maven 3.8.5 (3599d3414f046de2324203b78ddcf9b5e4388aa0) Maven home: /opt/apache-maven-3.8.5
java -version openjdk version "1.8.0_342"
uname -a Linux xx-note 5.4.0-107-generic #121~18.04.1-Ubuntu SMP Thu Mar 24 17:21:33 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>start</goal>
<goal>stop</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-maven-plugin</artifactId>
<version>1.4</version>
<executions>
<execution>
<phase>integration-test</phase>
<goals>
<goal>generate</goal>
</goals>
</execution>
</executions>
</plugin>
@ricardojlrufino see the documentation, as you are missing additional configuration:
If you are still running the issue after updating your configuration, Provide a Minimal, Reproducible Example - with HelloController that reproduces the problem.
Had the same problem when building locally in IntelliJ. Looks like the process doesn´t terminate if openapi.json is opened in the editor. When closing the editor tab before building the process terminates correctly. Maybe it helps...
Dependencies used:
springdoc-openapi-ui 1.6.12
springdoc-openapi-maven-plugin 1.4
Regards Tobias
When executing the verify maven phase and generating the openapi.json file, maven finishes with success, however the java process associated with it running on port 9001 is not exited and you have to kill it every time you want to run verify phase again.
Dependencies used: