Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 1 | <?xml version="1.0" encoding="UTF-8"?> |
Bruno Sakoto | 5c7c489 | 2021-02-08 21:51:05 -0500 | [diff] [blame] | 2 | <!-- |
| 3 | ============LICENSE_START======================================================= |
| 4 | Copyright (c) 2021 Pantheon.tech. |
| 5 | Modifications Copyright (C) 2021 Bell Canada. |
danielhanrahan | c72a013 | 2024-02-09 17:40:18 +0000 | [diff] [blame] | 6 | Modifications Copyright (C) 2021-2024 Nordix Foundation. |
Bruno Sakoto | 5c7c489 | 2021-02-08 21:51:05 -0500 | [diff] [blame] | 7 | ================================================================================ |
| 8 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 9 | you may not use this file except in compliance with the License. |
| 10 | You may obtain a copy of the License at |
| 11 | |
| 12 | http://www.apache.org/licenses/LICENSE-2.0 |
| 13 | |
| 14 | Unless required by applicable law or agreed to in writing, software |
| 15 | distributed under the License is distributed on an "AS IS" BASIS, |
| 16 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 17 | See the License for the specific language governing permissions and |
| 18 | limitations under the License. |
| 19 | ============LICENSE_END========================================================= |
| 20 | --> |
| 21 | |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 22 | <project xmlns="http://maven.apache.org/POM/4.0.0" |
| 23 | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 24 | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 25 | |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 26 | <!-- Project Metadata --> |
| 27 | <modelVersion>4.0.0</modelVersion> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 28 | <groupId>org.onap.cps</groupId> |
| 29 | <artifactId>cps-parent</artifactId> |
seanbeirne | 3587a62 | 2024-10-17 16:49:30 +0100 | [diff] [blame] | 30 | <version>3.5.5-SNAPSHOT</version> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 31 | <packaging>pom</packaging> |
| 32 | |
| 33 | <properties> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 34 | <!-- Set UTF-8 encoding for consistent builds across platforms --> |
| 35 | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
sourabh_sourabh | 1bb3639 | 2024-11-13 12:54:17 +0000 | [diff] [blame^] | 36 | <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 37 | <!-- Application Configuration --> |
| 38 | <app>org.onap.cps.Application</app> |
| 39 | |
| 40 | <!-- Parent Directory Configuration --> |
| 41 | <parent.directory>${project.basedir}/..</parent.directory> |
| 42 | |
| 43 | <!-- Global properties for version management --> |
| 44 | <bug.pattern.version>1.5.0</bug.pattern.version> |
| 45 | <dependency.check.version>9.2.0</dependency.check.version> |
sourabh_sourabh | ea5b0a8 | 2024-11-11 16:40:59 +0000 | [diff] [blame] | 46 | <git.commit.id.version>9.0.1</git.commit.id.version> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 47 | <gmavenplus.plugin.version>4.0.1</gmavenplus.plugin.version> |
| 48 | <jacoco.version>0.8.11</jacoco.version> |
| 49 | <java.version>17</java.version> |
| 50 | <jsonschema2pojo.maven.plugin.version>1.2.1</jsonschema2pojo.maven.plugin.version> |
| 51 | <maven.checkstyle.plugin.version>3.3.1</maven.checkstyle.plugin.version> |
| 52 | <maven.compiler.plugin.version>3.13.0</maven.compiler.plugin.version> |
| 53 | <maven.compiler.release>17</maven.compiler.release> |
sourabh_sourabh | ea5b0a8 | 2024-11-11 16:40:59 +0000 | [diff] [blame] | 54 | <maven.failsafe.plugin.version>3.5.2</maven.failsafe.plugin.version> |
| 55 | <maven.resources.plugin.version>3.3.1</maven.resources.plugin.version> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 56 | <maven.site.plugin.version>4.0.0-M13</maven.site.plugin.version> |
sourabh_sourabh | ea5b0a8 | 2024-11-11 16:40:59 +0000 | [diff] [blame] | 57 | <maven.surefire.plugin.version>3.3.1</maven.surefire.plugin.version> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 58 | <postgres.version>42.5.1</postgres.version> |
| 59 | <slf4j.simple.version>2.0.6</slf4j.simple.version> |
| 60 | <sonar.version>4.0.0.4121</sonar.version> |
| 61 | <spotbugs.plugin.version>4.8.6.4</spotbugs.plugin.version> |
| 62 | <spotbugs.version>4.8.6</spotbugs.version> |
sourabh_sourabh | ea5b0a8 | 2024-11-11 16:40:59 +0000 | [diff] [blame] | 63 | <spring.boot.maven.plugin.version>3.3.1</spring.boot.maven.plugin.version> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 64 | <swagger.codegen.version>1.2.1</swagger.codegen.version> |
| 65 | |
| 66 | <!-- Reporting paths and coverage --> |
| 67 | <jacoco.execFile>${project.build.directory}/code-coverage/jacoco-ut.exec</jacoco.execFile> |
| 68 | <jacoco.outputDirectory>${project.reporting.outputDirectory}/jacoco-ut</jacoco.outputDirectory> |
Claudio David Gasparini | d45b2dc | 2021-01-13 13:28:07 +0100 | [diff] [blame] | 69 | <jacoco.reportDirectory.aggregate>${project.reporting.outputDirectory}/jacoco-aggregate</jacoco.reportDirectory.aggregate> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 70 | <minimum-coverage>1.00</minimum-coverage> |
Claudio David Gasparini | d45b2dc | 2021-01-13 13:28:07 +0100 | [diff] [blame] | 71 | <sonar.coverage.jacoco.xmlReportPaths> |
ToineSiebelink | 73001f6 | 2021-09-17 15:07:38 +0100 | [diff] [blame] | 72 | ../jacoco-report/target/site/jacoco-aggregate/jacoco.xml |
Claudio David Gasparini | d45b2dc | 2021-01-13 13:28:07 +0100 | [diff] [blame] | 73 | </sonar.coverage.jacoco.xmlReportPaths> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 74 | </properties> |
| 75 | |
sourabh_sourabh | 1bb3639 | 2024-11-13 12:54:17 +0000 | [diff] [blame^] | 76 | <distributionManagement> |
| 77 | <repository> |
| 78 | <id>ecomp-releases</id> |
| 79 | <url>${onap.nexus.url}/content/repositories/releases</url> |
| 80 | </repository> |
| 81 | <snapshotRepository> |
| 82 | <id>ecomp-snapshots</id> |
| 83 | <url>${onap.nexus.url}/content/repositories/snapshots</url> |
| 84 | </snapshotRepository> |
| 85 | </distributionManagement> |
| 86 | |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 87 | <!-- Dependency Management, Profiles, Build, and Plugins --> |
| 88 | |
| 89 | <dependencyManagement> |
| 90 | <dependencies> |
| 91 | <dependency> |
| 92 | <groupId>org.onap.cps</groupId> |
| 93 | <artifactId>cps-dependencies</artifactId> |
| 94 | <version>${project.version}</version> |
| 95 | <type>pom</type> |
| 96 | <scope>import</scope> |
| 97 | </dependency> |
| 98 | <dependency> |
| 99 | <groupId>org.onap.cps</groupId> |
| 100 | <artifactId>cps-bom</artifactId> |
| 101 | <version>${project.version}</version> |
| 102 | <type>pom</type> |
| 103 | <scope>import</scope> |
| 104 | </dependency> |
| 105 | </dependencies> |
| 106 | </dependencyManagement> |
| 107 | |
DylanB95EST | 63132ce | 2021-12-14 16:34:38 +0000 | [diff] [blame] | 108 | <profiles> |
| 109 | <profile> |
| 110 | <id>Windows</id> |
| 111 | <activation> |
| 112 | <os> |
| 113 | <family>Windows</family> |
| 114 | </os> |
| 115 | </activation> |
| 116 | <properties> |
| 117 | <script.executor>python</script.executor> |
| 118 | </properties> |
| 119 | </profile> |
| 120 | <profile> |
| 121 | <id>unix</id> |
| 122 | <activation> |
| 123 | <os> |
| 124 | <family>unix</family> |
| 125 | </os> |
| 126 | </activation> |
| 127 | <properties> |
| 128 | <script.executor>python3</script.executor> |
| 129 | </properties> |
| 130 | </profile> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 131 | <profile> |
| 132 | <id>dependency-vulnerability-check</id> |
| 133 | <build> |
| 134 | <plugins> |
| 135 | <plugin> |
| 136 | <groupId>org.owasp</groupId> |
| 137 | <artifactId>dependency-check-maven</artifactId> |
| 138 | <version>${dependency.check.version}</version> |
| 139 | <executions> |
| 140 | <execution> |
| 141 | <goals> |
| 142 | <goal>aggregate</goal> |
| 143 | </goals> |
| 144 | </execution> |
| 145 | </executions> |
| 146 | </plugin> |
| 147 | </plugins> |
| 148 | </build> |
| 149 | </profile> |
sourabh_sourabh | ea5b0a8 | 2024-11-11 16:40:59 +0000 | [diff] [blame] | 150 | <!-- Performance tests are run with maven-failsafe-plugin using a separate profile, so they will |
| 151 | not affect Jacoco coverage. Heap size is set here to ensure consistent test environment. --> |
| 152 | <profile> |
| 153 | <id>include-performance</id> |
| 154 | <properties> |
| 155 | <failsafeArgLine>-Xms512m -Xmx512m</failsafeArgLine> |
| 156 | </properties> |
| 157 | <build> |
| 158 | <plugins> |
| 159 | <plugin> |
| 160 | <groupId>org.apache.maven.plugins</groupId> |
| 161 | <artifactId>maven-failsafe-plugin</artifactId> |
| 162 | <version>${maven.failsafe.plugin.version}</version> |
| 163 | <configuration> |
| 164 | <includes> |
| 165 | <include>**/*PerfTest.java</include> |
| 166 | </includes> |
| 167 | </configuration> |
| 168 | <executions> |
| 169 | <execution> |
| 170 | <goals> |
| 171 | <goal>integration-test</goal> |
| 172 | <goal>verify</goal> |
| 173 | </goals> |
| 174 | </execution> |
| 175 | </executions> |
| 176 | </plugin> |
| 177 | </plugins> |
| 178 | </build> |
| 179 | </profile> |
DylanB95EST | 63132ce | 2021-12-14 16:34:38 +0000 | [diff] [blame] | 180 | </profiles> |
| 181 | |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 182 | <build> |
| 183 | <resources> |
| 184 | <resource> |
| 185 | <directory>src/main/resources</directory> |
| 186 | <filtering>true</filtering> |
| 187 | </resource> |
| 188 | <resource> |
| 189 | <directory>target/generated-sources/license</directory> |
| 190 | <includes> |
| 191 | <include>third-party-licenses.txt</include> |
| 192 | </includes> |
| 193 | </resource> |
| 194 | <resource> |
| 195 | <directory>target/generated-resources/licenses</directory> |
| 196 | <includes> |
| 197 | <include>*.*</include> |
| 198 | </includes> |
| 199 | <targetPath>third-party-licenses</targetPath> |
| 200 | </resource> |
| 201 | </resources> |
| 202 | <pluginManagement> |
| 203 | <plugins> |
| 204 | <plugin> |
| 205 | <groupId>org.springframework.boot</groupId> |
| 206 | <artifactId>spring-boot-maven-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 207 | <version>${spring.boot.maven.plugin.version}</version> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 208 | <executions> |
| 209 | <execution> |
| 210 | <goals> |
| 211 | <goal>repackage</goal> |
| 212 | </goals> |
| 213 | </execution> |
| 214 | </executions> |
| 215 | </plugin> |
Bruno Sakoto | 6c34718 | 2021-07-22 15:25:23 -0400 | [diff] [blame] | 216 | <plugin> |
mpriyank | ff99139 | 2024-10-16 11:59:49 +0100 | [diff] [blame] | 217 | <groupId>io.github.git-commit-id</groupId> |
| 218 | <artifactId>git-commit-id-maven-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 219 | <version>${git.commit.id.version}</version> |
mpriyank | ff99139 | 2024-10-16 11:59:49 +0100 | [diff] [blame] | 220 | <executions> |
| 221 | <execution> |
| 222 | <id>get-git-info</id> |
| 223 | <goals> |
| 224 | <goal>revision</goal> |
| 225 | </goals> |
| 226 | <phase>package</phase> |
| 227 | </execution> |
| 228 | </executions> |
| 229 | </plugin> |
puthuparambil.aditya | 4759811 | 2020-11-02 11:31:39 +0000 | [diff] [blame] | 230 | <!-- Swagger code generation. --> |
| 231 | <plugin> |
| 232 | <groupId>io.swagger.codegen.v3</groupId> |
| 233 | <artifactId>swagger-codegen-maven-plugin</artifactId> |
Renu Kumari | 4d52001 | 2021-08-30 11:50:43 -0400 | [diff] [blame] | 234 | <executions> |
| 235 | <execution> |
| 236 | <id>openapi-yaml-gen</id> |
| 237 | <goals> |
| 238 | <goal>generate</goal> |
| 239 | </goals> |
| 240 | <phase>compile</phase> |
| 241 | <configuration> |
| 242 | <inputSpec>${project.basedir}/docs/openapi/openapi.yml</inputSpec> |
| 243 | <language>openapi-yaml</language> |
| 244 | </configuration> |
| 245 | </execution> |
| 246 | </executions> |
puthuparambil.aditya | 4759811 | 2020-11-02 11:31:39 +0000 | [diff] [blame] | 247 | </plugin> |
Claudio David Gasparini | 87c74a1 | 2020-11-18 08:38:01 +0100 | [diff] [blame] | 248 | <plugin> |
Claudio David Gasparini | 9f93f79 | 2020-12-18 14:37:27 +0100 | [diff] [blame] | 249 | <groupId>com.github.spotbugs</groupId> |
| 250 | <artifactId>spotbugs-maven-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 251 | <version>${spotbugs.plugin.version}</version> |
Claudio David Gasparini | 9f93f79 | 2020-12-18 14:37:27 +0100 | [diff] [blame] | 252 | <dependencies> |
| 253 | <dependency> |
| 254 | <groupId>com.github.spotbugs</groupId> |
| 255 | <artifactId>spotbugs</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 256 | <version>${spotbugs.version}</version> |
Claudio David Gasparini | 9f93f79 | 2020-12-18 14:37:27 +0100 | [diff] [blame] | 257 | </dependency> |
| 258 | <dependency> |
| 259 | <groupId>${project.groupId}</groupId> |
| 260 | <artifactId>spotbugs</artifactId> |
| 261 | <version>${project.version}</version> |
| 262 | </dependency> |
| 263 | <dependency> |
| 264 | <!-- The SpotBugs Maven plugin uses SLF4J 1.8 beta 2 --> |
| 265 | <groupId>org.slf4j</groupId> |
| 266 | <artifactId>slf4j-simple</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 267 | <version>${slf4j.simple.version}</version> |
Claudio David Gasparini | 9f93f79 | 2020-12-18 14:37:27 +0100 | [diff] [blame] | 268 | </dependency> |
| 269 | </dependencies> |
| 270 | <configuration> |
| 271 | <plugins> |
| 272 | <plugin> |
| 273 | <groupId>jp.skypencil.findbugs.slf4j</groupId> |
| 274 | <artifactId>bug-pattern</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 275 | <version>${bug.pattern.version}</version> |
Claudio David Gasparini | 9f93f79 | 2020-12-18 14:37:27 +0100 | [diff] [blame] | 276 | </plugin> |
| 277 | </plugins> |
| 278 | <!-- |
| 279 | Enables analysis which takes more memory but finds more bugs. |
| 280 | If you run out of memory, changes the value of the effort element |
| 281 | to 'Low'. |
| 282 | --> |
Bruno Sakoto | f549c7c | 2021-05-18 16:02:30 -0400 | [diff] [blame] | 283 | <addSourceDirs>true</addSourceDirs> |
Claudio David Gasparini | 9f93f79 | 2020-12-18 14:37:27 +0100 | [diff] [blame] | 284 | <effort>Max</effort> |
| 285 | <!-- Reports all bugs (other values are medium and max) --> |
| 286 | <threshold>Low</threshold> |
| 287 | <!-- Build doesn't fail if problems are found --> |
Claudio David Gasparini | 9afc8d1 | 2021-01-11 16:42:30 +0100 | [diff] [blame] | 288 | <failOnError>true</failOnError> |
Claudio David Gasparini | 9f93f79 | 2020-12-18 14:37:27 +0100 | [diff] [blame] | 289 | <!-- References the excluded rules --> |
| 290 | <excludeFilterFile>spotbugs-exclude.xml</excludeFilterFile> |
| 291 | <!-- Produces XML report --> |
| 292 | <xmlOutput>true</xmlOutput> |
| 293 | <!-- Configures the directory in which the XML report is created --> |
| 294 | <xmlOutputDirectory>${project.build.directory}/spotbugs</xmlOutputDirectory> |
| 295 | </configuration> |
| 296 | <executions> |
| 297 | <!-- |
| 298 | Ensures that SpotBugs inspects source code when project is compiled. |
| 299 | --> |
| 300 | <execution> |
| 301 | <id>analyze-compile</id> |
| 302 | <phase>compile</phase> |
| 303 | <goals> |
| 304 | <goal>check</goal> |
| 305 | </goals> |
| 306 | </execution> |
| 307 | </executions> |
| 308 | </plugin> |
Bruno Sakoto | f549c7c | 2021-05-18 16:02:30 -0400 | [diff] [blame] | 309 | <plugin> |
| 310 | <groupId>org.jsonschema2pojo</groupId> |
| 311 | <artifactId>jsonschema2pojo-maven-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 312 | <version>${jsonschema2pojo.maven.plugin.version}</version> |
Bruno Sakoto | f549c7c | 2021-05-18 16:02:30 -0400 | [diff] [blame] | 313 | <configuration> |
| 314 | <targetVersion>${java.version}</targetVersion> |
| 315 | </configuration> |
| 316 | <executions> |
| 317 | <execution> |
| 318 | <goals> |
| 319 | <goal>generate</goal> |
| 320 | </goals> |
| 321 | </execution> |
| 322 | </executions> |
| 323 | </plugin> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 324 | </plugins> |
| 325 | </pluginManagement> |
| 326 | <plugins> |
| 327 | <plugin> |
| 328 | <groupId>org.apache.maven.plugins</groupId> |
| 329 | <artifactId>maven-compiler-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 330 | <version>${maven.compiler.plugin.version}</version> |
| 331 | <configuration> |
| 332 | <encoding>${project.build.sourceEncoding}</encoding> |
| 333 | </configuration> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 334 | </plugin> |
| 335 | <plugin> |
| 336 | <groupId>org.apache.maven.plugins</groupId> |
| 337 | <artifactId>maven-checkstyle-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 338 | <version>${maven.checkstyle.plugin.version}</version> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 339 | <executions> |
| 340 | <execution> |
Claudio David Gasparini | 35b2b44 | 2020-12-01 14:53:40 +0100 | [diff] [blame] | 341 | <id>onap-license</id> |
| 342 | <goals> |
| 343 | <goal>check</goal> |
| 344 | </goals> |
| 345 | <phase>process-sources</phase> |
| 346 | <configuration> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 347 | <configLocation>cps-checkstyle/check-license.xml</configLocation> |
Claudio David Gasparini | 35b2b44 | 2020-12-01 14:53:40 +0100 | [diff] [blame] | 348 | <includeResources>false</includeResources> |
| 349 | <includeTestSourceDirectory>true</includeTestSourceDirectory> |
| 350 | <includeTestResources>false</includeTestResources> |
| 351 | <sourceDirectories> |
| 352 | <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory> |
| 353 | </sourceDirectories> |
| 354 | <consoleOutput>false</consoleOutput> |
| 355 | <violationSeverity>warning</violationSeverity> |
| 356 | <failOnViolation>true</failOnViolation> |
| 357 | </configuration> |
| 358 | </execution> |
| 359 | <execution> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 360 | <id>cps-java-style</id> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 361 | <goals> |
| 362 | <goal>check</goal> |
| 363 | </goals> |
| 364 | <phase>process-sources</phase> |
| 365 | <configuration> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 366 | <configLocation>cps-checkstyle/cps-java-style.xml</configLocation> |
Claudio David Gasparini | 35b2b44 | 2020-12-01 14:53:40 +0100 | [diff] [blame] | 367 | <sourceDirectories> |
| 368 | <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory> |
| 369 | </sourceDirectories> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 370 | <includeResources>true</includeResources> |
| 371 | <includeTestSourceDirectory>true</includeTestSourceDirectory> |
| 372 | <includeTestResources>true</includeTestResources> |
| 373 | <consoleOutput>false</consoleOutput> |
| 374 | <violationSeverity>warning</violationSeverity> |
| 375 | <failOnViolation>true</failOnViolation> |
| 376 | </configuration> |
| 377 | </execution> |
| 378 | </executions> |
| 379 | <dependencies> |
| 380 | <dependency> |
Claudio David Gasparini | 35b2b44 | 2020-12-01 14:53:40 +0100 | [diff] [blame] | 381 | <groupId>${project.groupId}</groupId> |
| 382 | <artifactId>checkstyle</artifactId> |
| 383 | <version>${project.version}</version> |
| 384 | </dependency> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 385 | </dependencies> |
| 386 | </plugin> |
| 387 | <!-- Mandatory plugins for using Spock --> |
| 388 | <plugin> |
| 389 | <!-- The gmavenplus plugin is used to compile Groovy code. |
| 390 | To learn more about this plugin, visit https://github.com/groovy/GMavenPlus/wiki --> |
| 391 | <groupId>org.codehaus.gmavenplus</groupId> |
| 392 | <artifactId>gmavenplus-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 393 | <version>${gmavenplus.plugin.version}</version> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 394 | <executions> |
| 395 | <execution> |
| 396 | <goals> |
| 397 | <goal>compileTests</goal> |
| 398 | </goals> |
| 399 | </execution> |
| 400 | </executions> |
| 401 | </plugin> |
| 402 | <!-- Required because names of spec classes don't match default |
| 403 | Surefire patterns (`*Test` etc.) --> |
| 404 | <plugin> |
| 405 | <groupId>org.apache.maven.plugins</groupId> |
| 406 | <artifactId>maven-surefire-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 407 | <version>${maven.surefire.plugin.version}</version> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 408 | <configuration> |
puthuparambil.aditya | 008c0ad | 2020-12-14 15:46:30 +0000 | [diff] [blame] | 409 | <!--suppress UnresolvedMavenProperty --> |
Claudio David Gasparini | 13cc64d | 2020-12-02 18:47:09 +0100 | [diff] [blame] | 410 | <argLine>${surefireArgLine}</argLine> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 411 | <useFile>false</useFile> |
| 412 | <includes> |
| 413 | <include>**/*Spec.java</include> |
| 414 | <include>**/*Test.java</include> <!-- Just in case of having also "normal" JUnit tests --> |
| 415 | </includes> |
Claudio David Gasparini | 13cc64d | 2020-12-02 18:47:09 +0100 | [diff] [blame] | 416 | <excludes> |
danielhanrahan | c72a013 | 2024-02-09 17:40:18 +0000 | [diff] [blame] | 417 | <!-- maven-failsafe-plugin will run performance tests in the integration-test module, |
| 418 | so performance tests will not affect Jacoco coverage (jacoco-report module is configured |
| 419 | to aggregate results from tests run with maven-surefire-plugin only) --> |
| 420 | <exclude>**/*PerfTest.java</exclude> |
Claudio David Gasparini | 13cc64d | 2020-12-02 18:47:09 +0100 | [diff] [blame] | 421 | </excludes> |
Ruslan Kashapov | bf02f20 | 2020-12-17 10:38:53 +0200 | [diff] [blame] | 422 | <environmentVariables> |
| 423 | <!-- |
| 424 | disable privileged container usage to cleanup the test containers; |
| 425 | these will be removed automatically on jvm termination; |
| 426 | see https://www.testcontainers.org/features/configuration/#disabling-ryuk |
| 427 | --> |
| 428 | <TESTCONTAINERS_RYUK_DISABLED>true</TESTCONTAINERS_RYUK_DISABLED> |
Renu Kumari | ff52b94 | 2021-05-27 23:16:32 -0400 | [diff] [blame] | 429 | <TESTCONTAINERS_HUB_IMAGE_NAME_PREFIX>${docker.pull.registry}/</TESTCONTAINERS_HUB_IMAGE_NAME_PREFIX> |
Ruslan Kashapov | bf02f20 | 2020-12-17 10:38:53 +0200 | [diff] [blame] | 430 | </environmentVariables> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 431 | </configuration> |
| 432 | </plugin> |
Claudio David Gasparini | 900ba02 | 2020-11-08 22:18:36 +0100 | [diff] [blame] | 433 | <plugin> |
Claudio David Gasparini | 87c74a1 | 2020-11-18 08:38:01 +0100 | [diff] [blame] | 434 | <groupId>org.jacoco</groupId> |
| 435 | <artifactId>jacoco-maven-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 436 | <version>${jacoco.version}</version> |
Bruno Sakoto | f549c7c | 2021-05-18 16:02:30 -0400 | [diff] [blame] | 437 | <configuration> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 438 | <!-- Exclude all generated classes or specific patterns if necessary --> |
Bruno Sakoto | f549c7c | 2021-05-18 16:02:30 -0400 | [diff] [blame] | 439 | <excludes> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 440 | <exclude>org/onap/cps/events/model/*</exclude> |
Bruno Sakoto | f549c7c | 2021-05-18 16:02:30 -0400 | [diff] [blame] | 441 | <exclude>org/onap/cps/rest/model/*</exclude> |
| 442 | <exclude>org/onap/cps/cpspath/parser/antlr4/*</exclude> |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 443 | <exclude>org/onap/cps/ncmp/rest/model/*</exclude> |
ToineSiebelink | 7fcffe5 | 2023-07-24 12:23:05 +0100 | [diff] [blame] | 444 | <exclude>org/onap/cps/**/*MapperImpl.class</exclude> |
| 445 | <exclude>org/onap/cps/ncmp/rest/stub/*</exclude> |
ToineSiebelink | d7914bc | 2024-07-04 15:15:36 +0100 | [diff] [blame] | 446 | <exclude>org/onap/cps/policyexecutor/stub/model/*</exclude> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 447 | <exclude>**/pom.xml</exclude> |
Bruno Sakoto | f549c7c | 2021-05-18 16:02:30 -0400 | [diff] [blame] | 448 | </excludes> |
| 449 | </configuration> |
Claudio David Gasparini | 87c74a1 | 2020-11-18 08:38:01 +0100 | [diff] [blame] | 450 | <executions> |
| 451 | <execution> |
| 452 | <id>default-prepare-agent</id> |
| 453 | <goals> |
| 454 | <goal>prepare-agent</goal> |
| 455 | </goals> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 456 | <configuration> |
| 457 | <destFile>${jacoco.execFile}</destFile> |
| 458 | <propertyName>surefireArgLine</propertyName> |
| 459 | </configuration> |
Claudio David Gasparini | 87c74a1 | 2020-11-18 08:38:01 +0100 | [diff] [blame] | 460 | </execution> |
| 461 | <execution> |
| 462 | <id>coverage-check</id> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 463 | <phase>test</phase> |
Claudio David Gasparini | 87c74a1 | 2020-11-18 08:38:01 +0100 | [diff] [blame] | 464 | <goals> |
| 465 | <goal>check</goal> |
| 466 | </goals> |
| 467 | <configuration> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 468 | <dataFile>${jacoco.execFile}</dataFile> |
Claudio David Gasparini | 87c74a1 | 2020-11-18 08:38:01 +0100 | [diff] [blame] | 469 | <rules> |
| 470 | <rule> |
| 471 | <element>BUNDLE</element> |
| 472 | <limits> |
| 473 | <limit> |
| 474 | <counter>INSTRUCTION</counter> |
| 475 | <value>COVEREDRATIO</value> |
| 476 | <minimum>${minimum-coverage}</minimum> |
| 477 | </limit> |
| 478 | </limits> |
| 479 | </rule> |
| 480 | </rules> |
| 481 | </configuration> |
| 482 | </execution> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 483 | <execution> |
| 484 | <id>post-unit-test</id> |
| 485 | <phase>test</phase> |
| 486 | <goals> |
| 487 | <goal>report</goal> |
| 488 | </goals> |
| 489 | <configuration> |
sourabh_sourabh | 1bb3639 | 2024-11-13 12:54:17 +0000 | [diff] [blame^] | 490 | <outputEncoding>${project.reporting.outputEncoding}</outputEncoding> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 491 | <!-- Sets the path to the file which contains the execution data. --> |
| 492 | <dataFile>${jacoco.execFile}</dataFile> |
| 493 | <!-- Sets the output directory for the code coverage report. --> |
| 494 | <outputDirectory>${jacoco.outputDirectory}</outputDirectory> |
| 495 | </configuration> |
| 496 | </execution> |
Claudio David Gasparini | 87c74a1 | 2020-11-18 08:38:01 +0100 | [diff] [blame] | 497 | </executions> |
Claudio David Gasparini | 900ba02 | 2020-11-08 22:18:36 +0100 | [diff] [blame] | 498 | </plugin> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 499 | |
| 500 | <!-- Sonar Plugin for Code Quality --> |
Claudio David Gasparini | 7492aea | 2021-01-13 08:34:00 +0100 | [diff] [blame] | 501 | <plugin> |
| 502 | <groupId>org.sonarsource.scanner.maven</groupId> |
| 503 | <artifactId>sonar-maven-plugin</artifactId> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 504 | <version>${sonar.version}</version> |
| 505 | </plugin> |
| 506 | |
| 507 | <!-- Maven Site Plugin for Site Generation --> |
| 508 | <plugin> |
| 509 | <groupId>org.apache.maven.plugins</groupId> |
| 510 | <artifactId>maven-site-plugin</artifactId> |
| 511 | <version>${maven.site.plugin.version}</version> |
| 512 | <executions> |
| 513 | <execution> |
| 514 | <id>default-site</id> |
| 515 | <phase>site</phase> |
| 516 | <goals><goal>site</goal></goals> |
| 517 | </execution> |
| 518 | </executions> |
Claudio David Gasparini | 7492aea | 2021-01-13 08:34:00 +0100 | [diff] [blame] | 519 | </plugin> |
sourabh_sourabh | 1bb3639 | 2024-11-13 12:54:17 +0000 | [diff] [blame^] | 520 | <plugin> |
| 521 | <groupId>org.apache.maven.plugins</groupId> |
| 522 | <artifactId>maven-deploy-plugin</artifactId> |
| 523 | <version>3.1.2</version> |
| 524 | </plugin> |
Claudio David Gasparini | 70c1702 | 2020-10-26 10:12:10 +0100 | [diff] [blame] | 525 | </plugins> |
| 526 | </build> |
sourabh_sourabh | 9eeb8e9 | 2024-10-24 14:24:54 +0100 | [diff] [blame] | 527 | </project> |