Resources are generated randomly in YAML file using swagger-maven-plugin
Hello SmartBear community,
I am using swagger-maven-plugin to generate a YAML file based on openAPI annotations.
https://github.com/swagger-api/swagger-core/tree/master/modules/swagger-maven-plugin
All methods in every resource Java class are annoted properly, but each time I generate the YAML file, all the methods in every resource Java class are generated randomly.
I would like that all the methods in a Java resource class to be generated in the order in which they appear in the class.
I tried several parameters from here, but none of them work
https://github.com/swagger-api/swagger-core/tree/master/modules/swagger-maven-plugin#parameters
Do you have any suggestion in how to solve this (I would like that all the methods in a Java resource class to be generated in the order in which they appear in the class.) ?
My pom.xml looks like this:
<plugin>
<groupId>io.swagger.core.v3</groupId>
<artifactId>swagger-maven-plugin</artifactId>
<version>2.0.8</version>
<configuration>
<openapiFilePath>${project.basedir} --this is a PATH to my configuration.yaml file</openapiFilePath>
<outputFileName>result</outputFileName>
<outputFormat>JSONANDYAML</outputFormat>
<outputPath>${project.build.directory}</outputPath>
<prettyPrint>true</prettyPrint>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>resolve</goal>
</goals>
</execution>
</executions>
</plugin>
Thanks a million for any hints.
frantuma Do you have any solution? :)
Bogdan