diff options
Diffstat (limited to 'cps-ncmp-rest/pom.xml')
-rw-r--r-- | cps-ncmp-rest/pom.xml | 33 |
1 files changed, 27 insertions, 6 deletions
diff --git a/cps-ncmp-rest/pom.xml b/cps-ncmp-rest/pom.xml index 8c84546b23..8db3628a94 100644 --- a/cps-ncmp-rest/pom.xml +++ b/cps-ncmp-rest/pom.xml @@ -116,8 +116,9 @@ <plugins> <!-- Swagger code generation. --> <plugin> - <groupId>io.swagger.codegen.v3</groupId> - <artifactId>swagger-codegen-maven-plugin</artifactId> + <groupId>org.openapitools</groupId> + <artifactId>openapi-generator-maven-plugin</artifactId> + <version>6.6.0</version> <executions> <execution> <id>ncmp-code-gen</id> @@ -129,13 +130,16 @@ <invokerPackage>org.onap.cps.ncmp.rest.controller</invokerPackage> <modelPackage>org.onap.cps.ncmp.rest.model</modelPackage> <apiPackage>org.onap.cps.ncmp.rest.api</apiPackage> - <language>spring</language> + <generatorName>spring</generatorName> <generateSupportingFiles>false</generateSupportingFiles> + <generateAliasAsModel>true</generateAliasAsModel> <configOptions> <sourceFolder>src/gen/java</sourceFolder> <dateLibrary>java11</dateLibrary> <interfaceOnly>true</interfaceOnly> <useTags>true</useTags> + <openApiNullable>false</openApiNullable> + <skipDefaultInterface>true</skipDefaultInterface> </configOptions> </configuration> </execution> @@ -149,13 +153,15 @@ <invokerPackage>org.onap.cps.ncmp.rest.controller</invokerPackage> <modelPackage>org.onap.cps.ncmp.rest.model</modelPackage> <apiPackage>org.onap.cps.ncmp.rest.api</apiPackage> - <language>spring</language> + <generatorName>spring</generatorName> <generateSupportingFiles>false</generateSupportingFiles> <configOptions> <sourceFolder>src/gen/java</sourceFolder> <dateLibrary>java11</dateLibrary> <interfaceOnly>true</interfaceOnly> <useTags>true</useTags> + <openApiNullable>false</openApiNullable> + <skipDefaultInterface>true</skipDefaultInterface> </configOptions> </configuration> </execution> @@ -167,15 +173,30 @@ <phase>compile</phase> <configuration> <inputSpec>${project.basedir}/docs/openapi/openapi-inventory.yml</inputSpec> - <language>openapi-yaml</language> + <generatorName>openapi-yaml</generatorName> <configOptions> <outputFile>openapi-inventory.yaml</outputFile> </configOptions> </configuration> </execution> + <execution> + <id>ncmp-openapi-yaml-gen</id> + <goals> + <goal>generate</goal> + </goals> + <phase>compile</phase> + <configuration> + <inputSpec>${project.basedir}/docs/openapi/openapi.yml</inputSpec> + <generatorName>openapi-yaml</generatorName> + <configOptions> + <outputFile>openapi.yaml</outputFile> + </configOptions> + </configuration> + </execution> </executions> </plugin> <plugin> + <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-resources-plugin</artifactId> <executions> <execution> @@ -189,7 +210,7 @@ </outputDirectory> <resources> <resource> - <directory>${project.basedir}/target/generated-sources/swagger/</directory> + <directory>${project.basedir}/target/generated-sources/openapi/</directory> <includes> <include>openapi*.yaml</include> </includes> |