summaryrefslogtreecommitdiffstats
path: root/main/pom.xml
diff options
context:
space:
mode:
authorlapentafd <francesco.lapenta@est.tech>2023-01-30 12:04:35 +0000
committerFrancesco Davide Lapenta <francesco.lapenta@est.tech>2023-01-31 17:04:13 +0000
commitc4f23fa97e161133db6692f6331dbea13077e47b (patch)
tree44bb3fe15e45cf4ef41db89ea0d419bdd4f3c04c /main/pom.xml
parent1e82ff4b693e2920dfde67cdfc30bf0648f1b097 (diff)
Removing old swagger annotation in xacml-pdp
This commit removes the Swagger V2 annotations on the Rest Controllers in policy-xacml-pdp. The OpeApi annotations (Swagger v3 annotations) are on a generated Java Interface. Issue-ID: POLICY-3465 Change-Id: Ibdeacff9582bb95a21d9fcb7dd8bd3688fa165df Signed-off-by: lapentafd <francesco.lapenta@est.tech>
Diffstat (limited to 'main/pom.xml')
-rw-r--r--main/pom.xml53
1 files changed, 52 insertions, 1 deletions
diff --git a/main/pom.xml b/main/pom.xml
index af1c8c5c..799f1b71 100644
--- a/main/pom.xml
+++ b/main/pom.xml
@@ -70,7 +70,7 @@
<dependency>
<groupId>org.onap.policy.common</groupId>
<artifactId>utils-test</artifactId>
- <version>${policy.common.version}</version>
+ <version>${policy.common.version}</version>
<scope>test</scope>
</dependency>
<dependency>
@@ -133,6 +133,12 @@
<artifactId>assertj-core</artifactId>
<scope>test</scope>
</dependency>
+ <!-- Swagger v3 annotations -->
+ <dependency>
+ <groupId>io.swagger.core.v3</groupId>
+ <artifactId>swagger-annotations</artifactId>
+ <version>2.2.7</version>
+ </dependency>
</dependencies>
<build>
@@ -153,6 +159,51 @@
</excludes>
</resource>
</resources>
+ <plugins>
+ <!-- Controllers interfaces generation -->
+ <plugin>
+ <groupId>io.swagger.codegen.v3</groupId>
+ <artifactId>swagger-codegen-maven-plugin</artifactId>
+ <version>3.0.27</version>
+ <executions>
+ <execution>
+ <id>code-gen</id>
+ <goals>
+ <goal>generate</goal>
+ </goals>
+ <configuration>
+ <inputSpec>${project.basedir}/src/main/resources/openapi/openapi.yaml</inputSpec>
+ <invokerPackage>org.onap.policy.pdpx.main.rest</invokerPackage>
+ <modelPackage>org.onap.policy.pdpx.main.rest.model</modelPackage>
+ <apiPackage>org.onap.policy.pdpx.main.rest</apiPackage>
+ <language>jaxrs-spec</language>
+ <generateModels>false</generateModels>
+ <generateSupportingFiles>false</generateSupportingFiles>
+ <sortParamsByRequiredFlag>false</sortParamsByRequiredFlag>
+ <importMappings>
+ HealthCheckReport=org.onap.policy.common.endpoints.report.HealthCheckReport,
+ DecisionException=org.onap.policy.models.decisions.concepts.DecisionException,
+ DecisionRequest=org.onap.policy.models.decisions.concepts.DecisionRequest,
+ DecisionResponse=org.onap.policy.models.decisions.concepts.DecisionResponse,
+ ErrorResponse=org.onap.policy.models.errors.concepts.ErrorResponse,
+ StatisticsReport=org.onap.policy.pdpx.main.rest.model.StatisticsReport,
+ DecisionProvider=org.onap.policy.pdpx.main.rest.provider.DecisionProvider,
+ HealthCheckProvider=org.onap.policy.pdpx.main.rest.provider.HealthCheckProvider,
+ StatisticsProvider=org.onap.policy.pdpx.main.rest.provider.StatisticsProvider,
+ Request=com.att.research.xacml.api.Request,
+ Response=javax.ws.rs.core.Response
+ </importMappings>
+ <configOptions>
+ <sourceFolder>src/gen/java</sourceFolder>
+ <dateLibrary>java11</dateLibrary>
+ <interfaceOnly>true</interfaceOnly>
+ <useTags>true</useTags>
+ </configOptions>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
</build>
</project>