Merge "adding saving simple function at designer"
[ccsdk/cds.git] / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3 Copyright (C) 2019 Bell Canada
4 Modification Copyright © 2018-2019 AT&T Intellectual Property.
5
6 Unless otherwise specified, all software contained herein is licensed
7 under the Apache License, Version 2.0 (the License);
8 you may not use this software except in compliance with the License.
9 You may obtain a copy of the License at
10
11     http://www.apache.org/licenses/LICENSE-2.0
12
13 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18 -->
19
20 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
21     <modelVersion>4.0.0</modelVersion>
22
23     <parent>
24         <groupId>org.onap.ccsdk.parent</groupId>
25         <artifactId>spring-boot-starter-parent</artifactId>
26         <version>2.1.0-SNAPSHOT</version>
27         <relativePath/>
28     </parent>
29
30     <groupId>org.onap.ccsdk.cds</groupId>
31     <artifactId>cds-aggregator</artifactId>
32     <version>1.1.0-SNAPSHOT</version>
33     <packaging>pom</packaging>
34
35     <name>Aggregator</name>
36     <description>CCSDK Controller Design Studio</description>
37     <url>https://wiki.onap.org</url>
38     <organization>
39         <name>ONAP</name>
40     </organization>
41
42     <modules>
43         <module>ms</module>
44         <module>cds-ui</module>
45         <module>components</module>
46     </modules>
47
48     <properties>
49         <!--Don't set any language to let sonar enable multi-language support-->
50         <sonar.language/>
51         <!--Provide src/main as source path so both src/main/java and src/main/kotlin are scanned-->
52         <sonar.sources>src/main</sonar.sources>
53         <!--Provide src/test as source path for test so both src/test/java and src/test/kotlin are scanned-->
54         <sonar.tests>src/test</sonar.tests>
55         <!--Only include java and kt files to the scan-->
56         <sonar.inclusions>**/*.java,**/*.kt</sonar.inclusions>
57         <!--Specify path to load jacoco XLM report, as Sonar can't load Kotlin coverage from binary report-->
58         <sonar.coverage.jacoco.xmlReportPaths>${project.reporting.outputDirectory}/jacoco-ut/jacoco.xml
59         </sonar.coverage.jacoco.xmlReportPaths>
60         <jacoco.version>0.8.3</jacoco.version>
61
62         <!-- Properties for POM Format -->
63         <format.skipValidate>false</format.skipValidate>
64         <format.skipExecute>true</format.skipExecute>
65         <java.version>11</java.version>
66         <maven-surefire-plugin.version>3.0.0-M5</maven-surefire-plugin.version>
67         <maven-failsafe-plugin.version>3.0.0-M5</maven-failsafe-plugin.version>
68
69         <!-- docker related properties -->
70         <docker.verbose>true</docker.verbose>
71         <docker.skip.push>false</docker.skip.push>
72         <docker.push.phase>deploy</docker.push.phase>
73         <ccsdk.build.timestamp>${maven.build.timestamp}</ccsdk.build.timestamp>
74         <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
75
76         <ccsdk.cds.version>${project.version}</ccsdk.cds.version>
77     </properties>
78
79     <build>
80         <pluginManagement>
81             <plugins>
82                 <!--TODO: This plugin is broken. Find replacement-->
83                 <!-- Plugin to Format/Validate POM Files -->
84                 <plugin>
85                     <groupId>org.codehaus.mojo</groupId>
86                     <artifactId>tidy-maven-plugin</artifactId>
87                     <version>1.1.0</version>
88                     <executions>
89                         <execution>
90                             <id>format-pom</id>
91                             <phase>process-sources</phase>
92                             <goals>
93                                 <goal>pom</goal>
94                             </goals>
95                             <configuration>
96                                 <skip>${format.skipExecute}</skip>
97                             </configuration>
98                         </execution>
99                         <execution>
100                             <id>validate-pom</id>
101                             <phase>validate</phase>
102                             <goals>
103                                 <goal>check</goal>
104                             </goals>
105                             <configuration>
106                                 <skip>${format.skipValidate}</skip>
107                             </configuration>
108                         </execution>
109                     </executions>
110                 </plugin>
111
112                 <!-- Plugin to Format/Validate Kotlin Files -->
113                 <plugin>
114                     <groupId>org.apache.maven.plugins</groupId>
115                     <artifactId>maven-antrun-plugin</artifactId>
116                     <version>${maven-antrun-plugin.version}</version>
117                     <executions>
118                         <execution>
119                             <id>validate-kotlin</id>
120                             <phase>validate</phase>
121                             <configuration>
122                                 <target name="ktlint">
123                                     <java taskname="ktlint" dir="${project.basedir}" fork="true" failonerror="true" classname="com.pinterest.ktlint.Main" classpathref="maven.plugin.classpath">
124                                         <arg value="src/**/*.kt"/>
125                                         <arg value="Scripts/**/*.kt"/>
126                                     </java>
127                                 </target>
128                                 <skip>${format.skipValidate}</skip>
129                             </configuration>
130                             <goals>
131                                 <goal>run</goal>
132                             </goals>
133                         </execution>
134                         <execution>
135                             <id>format-kotlin</id>
136                             <phase>process-sources</phase>
137                             <configuration>
138                                 <target name="ktlint">
139                                     <java taskname="ktlint" dir="${project.basedir}" fork="true" failonerror="true" classname="com.pinterest.ktlint.Main" classpathref="maven.plugin.classpath">
140                                         <arg value="-F"/>
141                                         <arg value="src/**/*.kt"/>
142                                         <arg value="Scripts/**/*.kt"/>
143                                     </java>
144                                 </target>
145                                 <skip>${format.skipExecute}</skip>
146                             </configuration>
147                             <goals>
148                                 <goal>run</goal>
149                             </goals>
150                         </execution>
151                     </executions>
152                     <dependencies>
153                         <dependency>
154                             <groupId>com.pinterest</groupId>
155                             <artifactId>ktlint</artifactId>
156                             <version>0.39.0</version>
157                         </dependency>
158                     </dependencies>
159                 </plugin>
160
161                 <!-- Plugin to identify root path of the project -->
162                 <plugin>
163                     <groupId>org.commonjava.maven.plugins</groupId>
164                     <artifactId>directory-maven-plugin</artifactId>
165                     <version>0.3</version>
166                     <executions>
167                         <execution>
168                             <phase>validate</phase>
169                             <id>directories</id>
170                             <goals>
171                                 <goal>highest-basedir</goal>
172                             </goals>
173                             <configuration>
174                                 <property>baseDirPath</property>
175                             </configuration>
176                         </execution>
177                     </executions>
178                 </plugin>
179
180                 <!-- Plugin to Format/Validate Java Classes -->
181                 <plugin>
182                     <groupId>net.revelc.code.formatter</groupId>
183                     <artifactId>formatter-maven-plugin</artifactId>
184                     <version>2.12.0</version>
185                     <executions>
186                         <execution>
187                             <id>format-java</id>
188                             <goals>
189                                 <goal>format</goal>
190                             </goals>
191                             <phase>process-sources</phase>
192                             <configuration>
193                                 <lineEnding>LF</lineEnding>
194                                 <skip>${format.skipExecute}</skip>
195                                 <sourceDirectory>${project.basedir}</sourceDirectory>
196                                 <configFile>${baseDirPath}/ONAP-Java-Code-Style.xml</configFile>
197                                 <includes>
198                                     <include>src/**/*.java</include>
199                                 </includes>
200                             </configuration>
201                         </execution>
202                         <execution>
203                             <id>validate-java</id>
204                             <goals>
205                                 <goal>validate</goal>
206                             </goals>
207                             <phase>validate</phase>
208                             <configuration>
209                                 <lineEnding>LF</lineEnding>
210                                 <skip>${format.skipValidate}</skip>
211                                 <sourceDirectory>${project.basedir}</sourceDirectory>
212                                 <configFile>${baseDirPath}/ONAP-Java-Code-Style.xml</configFile>
213                                 <includes>
214                                     <include>src/**/*.java</include>
215                                 </includes>
216                             </configuration>
217                         </execution>
218                     </executions>
219                     <dependencies>
220                         <dependency>
221                             <groupId>com.fasterxml.jackson.core</groupId>
222                             <artifactId>jackson-annotations</artifactId>
223                             <version>${jackson-bom.version}</version>
224                         </dependency>
225                     </dependencies>
226                 </plugin>
227
228                 <plugin>
229                     <groupId>org.apache.maven.plugins</groupId>
230                     <artifactId>maven-surefire-plugin</artifactId>
231                     <version>${maven-surefire-plugin.version}</version>
232                     <configuration>
233                         <!-- Sets the VM argument line used when unit tests are run. -->
234                         <argLine>${surefireArgLine}</argLine>
235                         <!-- Excludes integration tests when unit tests are run. -->
236                         <excludes>
237                             <exclude>**/IT*.java</exclude>
238                         </excludes>
239                     </configuration>
240                 </plugin>
241                 <plugin>
242                     <groupId>org.apache.maven.plugins</groupId>
243                     <artifactId>maven-failsafe-plugin</artifactId>
244                     <version>${maven-failsafe-plugin.version}</version>
245                     <executions>
246                         <!-- Ensures that both integration-test and verify goals of the Failsafe Maven plugin are executed. -->
247                         <execution>
248                             <id>integration-tests</id>
249                             <goals>
250                                 <goal>integration-test</goal>
251                                 <goal>verify</goal>
252                             </goals>
253                             <configuration>
254                                 <!-- Sets the VM argument line used when integration tests are run. -->
255                                 <argLine>${failsafeArgLine}</argLine>
256                             </configuration>
257                         </execution>
258                     </executions>
259                 </plugin>
260                 <plugin>
261                     <groupId>org.jetbrains.kotlin</groupId>
262                     <artifactId>kotlin-maven-plugin</artifactId>
263                     <version>${kotlin.maven.version}</version>
264                     <configuration>
265                         <jvmTarget>${java.version}</jvmTarget>
266                     </configuration>
267                 </plugin>
268                 <plugin>
269                     <groupId>org.apache.maven.plugins</groupId>
270                     <artifactId>maven-compiler-plugin</artifactId>
271                     <version>${maven-compiler-plugin.version}</version>
272                     <configuration>
273                         <release>${java.version}</release>
274                         <!--explicitly remove source and target-->
275                         <source combine.self="override"/>
276                         <target combine.self="override"/>
277                     </configuration>
278                 </plugin>
279             </plugins>
280         </pluginManagement>
281         <plugins>
282             <plugin>
283                 <groupId>org.jacoco</groupId>
284                 <artifactId>jacoco-maven-plugin</artifactId>
285                 <version>${jacoco.version}</version>
286             </plugin>
287             <plugin>
288                 <groupId>org.codehaus.mojo</groupId>
289                 <artifactId>tidy-maven-plugin</artifactId>
290             </plugin>
291             <plugin>
292                 <groupId>org.apache.maven.plugins</groupId>
293                 <artifactId>maven-antrun-plugin</artifactId>
294             </plugin>
295             <plugin>
296                 <groupId>org.commonjava.maven.plugins</groupId>
297                 <artifactId>directory-maven-plugin</artifactId>
298             </plugin>
299             <plugin>
300                 <groupId>net.revelc.code.formatter</groupId>
301                 <artifactId>formatter-maven-plugin</artifactId>
302             </plugin>
303             <plugin>
304                 <groupId>org.apache.maven.plugins</groupId>
305                 <artifactId>maven-surefire-plugin</artifactId>
306             </plugin>
307             <plugin>
308                 <groupId>org.apache.maven.plugins</groupId>
309                 <artifactId>maven-failsafe-plugin</artifactId>
310             </plugin>
311             <plugin>
312                 <groupId>org.apache.maven.plugins</groupId>
313                 <artifactId>maven-compiler-plugin</artifactId>
314             </plugin>
315         </plugins>
316     </build>
317
318     <profiles>
319         <profile>
320             <id>blackduck</id>
321             <activation>
322                 <property>
323                     <name>blackduck-scan</name>
324                 </property>
325             </activation>
326             <build>
327                 <plugins>
328                     <plugin>
329                         <groupId>com.blackducksoftware.integration</groupId>
330                         <artifactId>hub-maven-plugin</artifactId>
331                         <version>1.4.0</version>
332                         <inherited>false</inherited>
333                         <configuration>
334                             <hubProjectName>${project.name}</hubProjectName>
335                             <outputDirectory>${project.basedir}</outputDirectory>
336                         </configuration>
337                         <executions>
338                             <execution>
339                                 <id>create-bdio-file</id>
340                                 <phase>package</phase>
341                                 <goals>
342                                     <goal>createHubOutput</goal>
343                                 </goals>
344                             </execution>
345                         </executions>
346                     </plugin>
347                 </plugins>
348             </build>
349         </profile>
350
351         <!-- Profile to format skip validate or execute -->
352         <profile>
353             <id>format</id>
354             <properties>
355                 <format.skipValidate>true</format.skipValidate>
356                 <format.skipExecute>false</format.skipExecute>
357             </properties>
358         </profile>
359         <profile>
360             <id>dependency-list</id>
361             <build>
362                 <plugins>
363                     <plugin>
364                         <groupId>com.github.ferstl</groupId>
365                         <artifactId>depgraph-maven-plugin</artifactId>
366                         <executions>
367                             <execution>
368                                 <phase>validate</phase>
369                                 <inherited>false</inherited>
370                                 <goals>
371                                     <goal>aggregate</goal>
372                                 </goals>
373                             </execution>
374                         </executions>
375                     </plugin>
376                     <plugin>
377                         <groupId>org.codehaus.mojo</groupId>
378                         <artifactId>build-helper-maven-plugin</artifactId>
379                         <executions>
380                             <execution>
381                                 <id>attach-artifacts</id>
382                                 <phase>package</phase>
383                                 <inherited>false</inherited>
384                                 <goals>
385                                     <goal>attach-artifact</goal>
386                                 </goals>
387                                 <configuration>
388                                     <artifacts>
389                                         <artifact>
390                                             <file>${dependency-list.file}</file>
391                                             <type>txt</type>
392                                             <classifier>dependencies</classifier>
393                                         </artifact>
394                                     </artifacts>
395                                 </configuration>
396                             </execution>
397                         </executions>
398                     </plugin>
399                 </plugins>
400             </build>
401         </profile>
402     </profiles>
403 </project>