aboutsummaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authorliamfallon <liam.fallon@ericsson.com>2018-11-10 00:39:12 +0000
committerliamfallon <liam.fallon@ericsson.com>2018-11-12 11:07:31 +0000
commit32497610bd7bc721bb73f0d753fc1426bba677e2 (patch)
tree44167f3feb03c84b3cff784d9758b03528f1eb0b /client
parent53d8916cc60d97e2ce7ae345f8cc25f5602567da (diff)
Clean up eclipse and document warnings
Parent versions in some POMs only called on the test profile were incorrect Warnings in Eclipse on POM including from outside its project are fixed Some checkstyle fixes Some javadoc warnings fixed Issue-ID: POLICY-954 Change-Id: I640bc842dc79a9fa580015abb9a76c84a7845efe Signed-off-by: liamfallon <liam.fallon@ericsson.com>
Diffstat (limited to 'client')
-rw-r--r--client/client-common/pom.xml25
-rw-r--r--client/client-common/src/main/assembly/assembly.xml32
-rw-r--r--client/client-deployment/pom.xml120
-rw-r--r--client/client-editor/pom.xml106
-rw-r--r--client/client-editor/src/main/java/org/onap/policy/apex/client/editor/rest/handling/ApexEditorRestResource.java50
-rw-r--r--client/client-full/pom.xml164
-rw-r--r--client/client-full/src/main/java/org/onap/policy/apex/client/full/rest/ApexServicesRestMain.java1
-rw-r--r--client/client-monitoring/pom.xml105
8 files changed, 337 insertions, 266 deletions
diff --git a/client/client-common/pom.xml b/client/client-common/pom.xml
index 7c679ad41..92174c87f 100644
--- a/client/client-common/pom.xml
+++ b/client/client-common/pom.xml
@@ -26,32 +26,9 @@
</parent>
<artifactId>client-common</artifactId>
- <packaging>pom</packaging>
+ <packaging>jar</packaging>
<name>${project.artifactId}</name>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-assembly-plugin</artifactId>
- <executions>
- <execution>
- <id>make shared resources</id>
- <goals>
- <goal>single</goal>
- </goals>
- <phase>package</phase>
- <configuration>
- <descriptors>
- <descriptor>src/main/assembly/assembly.xml</descriptor>
- </descriptors>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
-
<profiles>
<profile>
<id>apexSite</id>
diff --git a/client/client-common/src/main/assembly/assembly.xml b/client/client-common/src/main/assembly/assembly.xml
deleted file mode 100644
index ddc56e57f..000000000
--- a/client/client-common/src/main/assembly/assembly.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<!--
- ============LICENSE_START=======================================================
- Copyright (C) 2016-2018 Ericsson. All rights reserved.
- ================================================================================
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
- SPDX-License-Identifier: Apache-2.0
- ============LICENSE_END=========================================================
--->
-<assembly>
- <id>resources</id>
- <formats>
- <format>zip</format>
- </formats>
- <includeBaseDirectory>false</includeBaseDirectory>
- <fileSets>
- <fileSet>
- <directory>src/main/resources</directory>
- <outputDirectory></outputDirectory>
- </fileSet>
- </fileSets>
-</assembly> \ No newline at end of file
diff --git a/client/client-deployment/pom.xml b/client/client-deployment/pom.xml
index 41e0e0508..02ecb4ae6 100644
--- a/client/client-deployment/pom.xml
+++ b/client/client-deployment/pom.xml
@@ -17,7 +17,8 @@
SPDX-License-Identifier: Apache-2.0
============LICENSE_END=========================================================
-->
-<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">
+<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">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.policy.apex-pdp.client</groupId>
@@ -39,9 +40,6 @@
<groupId>org.onap.policy.apex-pdp.client</groupId>
<artifactId>client-common</artifactId>
<version>${project.version}</version>
- <classifier>resources</classifier>
- <type>zip</type>
- <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.containers</groupId>
@@ -73,65 +71,36 @@
<defaultGoal>install</defaultGoal>
<outputDirectory>${project.build.directory}/classes</outputDirectory>
<plugins>
+ <!-- Copy common resources to this client's webapp directory -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
- <id>unpack-client-deployment-shared-resources-war</id>
- <goals>
- <goal>unpack-dependencies</goal>
- </goals>
+ <id>unpack-examples</id>
<phase>validate</phase>
- <configuration>
- <outputDirectory>${project.build.directory}/${project.artifactId}-${project.version}</outputDirectory>
- <includeArtifacIds>client-common</includeArtifacIds>
- <includeGroupIds>${project.groupId}</includeGroupIds>
- <excludeTransitive>true</excludeTransitive>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <executions>
- <execution>
- <id>copy-common-resources-to-jar</id>
- <phase>initialize</phase>
<goals>
- <goal>copy-resources</goal>
+ <goal>unpack</goal>
</goals>
<configuration>
- <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
- <filtering>false</filtering>
- <resources>
- <resource>
- <directory>../client-common/src/main/resources</directory>
- </resource>
- </resources>
- <overwrite>true</overwrite>
- </configuration>
- </execution>
- <execution>
- <id>copy-local-resources-to-jar</id>
- <phase>generate-sources</phase>
- <goals>
- <goal>copy-resources</goal>
- </goals>
- <configuration>
- <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
- <filtering>false</filtering>
- <resources>
- <resource>
- <directory>src/main/resources/webapp</directory>
- </resource>
- </resources>
- <overwrite>true</overwrite>
+ <artifactItems>
+ <artifactItem>
+ <groupId>org.onap.policy.apex-pdp.client</groupId>
+ <artifactId>client-common</artifactId>
+ <version>${project.version}</version>
+ <type>jar</type>
+ <overWrite>false</overWrite>
+ <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
+ <excludes>META-INF/</excludes>
+ </artifactItem>
+ </artifactItems>
+ <overWriteReleases>true</overWriteReleases>
+ <overWriteSnapshots>true</overWriteSnapshots>
</configuration>
</execution>
</executions>
</plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
@@ -163,14 +132,18 @@
</filter>
</filters>
<transformers>
- <transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
- <transformer implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
<resource>reference.conf</resource>
</transformer>
- <transformer implementation="org.apache.maven.plugins.shade.resource.DontIncludeResourceTransformer">
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.DontIncludeResourceTransformer">
<resource>log4j.properties</resource>
</transformer>
- <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>org.onap.policy.apex.client.deployment.rest.ApexDeploymentRestMain</mainClass>
</transformer>
</transformers>
@@ -224,6 +197,45 @@
<profiles>
<profile>
+ <id>only-eclipse</id>
+ <activation>
+ <property>
+ <name>m2e.version</name>
+ </property>
+ </activation>
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.eclipse.m2e</groupId>
+ <artifactId>lifecycle-mapping</artifactId>
+ <version>1.0.0</version>
+ <configuration>
+ <lifecycleMappingMetadata>
+ <pluginExecutions>
+ <pluginExecution>
+ <pluginExecutionFilter>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <versionRange>[2.0,)</versionRange>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ </pluginExecutionFilter>
+ <action>
+ <ignore />
+ </action>
+ </pluginExecution>
+ </pluginExecutions>
+ </lifecycleMappingMetadata>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+ </profile>
+
+ <profile>
<id>apexSite</id>
<activation>
<property>
diff --git a/client/client-editor/pom.xml b/client/client-editor/pom.xml
index 47ce007ac..4bae1013d 100644
--- a/client/client-editor/pom.xml
+++ b/client/client-editor/pom.xml
@@ -48,9 +48,6 @@
<groupId>org.onap.policy.apex-pdp.client</groupId>
<artifactId>client-common</artifactId>
<version>${project.version}</version>
- <classifier>resources</classifier>
- <type>zip</type>
- <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.containers</groupId>
@@ -99,65 +96,37 @@
<defaultGoal>install</defaultGoal>
<outputDirectory>${project.build.directory}/classes</outputDirectory>
<plugins>
+ <!-- Copy common resources to this client's webapp directory -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
- <id>unpack-client-editor-shared-resources</id>
- <goals>
- <goal>unpack-dependencies</goal>
- </goals>
+ <id>unpack-examples</id>
<phase>validate</phase>
- <configuration>
- <outputDirectory>${project.build.directory}/${project.artifactId}-${project.version}</outputDirectory>
- <includeArtifacIds>client-common</includeArtifacIds>
- <includeGroupIds>${project.groupId}</includeGroupIds>
- <excludeTransitive>true</excludeTransitive>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <executions>
- <execution>
- <id>copy-common-resources-to-jar</id>
- <phase>initialize</phase>
<goals>
- <goal>copy-resources</goal>
+ <goal>unpack</goal>
</goals>
<configuration>
- <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
- <filtering>false</filtering>
- <resources>
- <resource>
- <directory>../client-common/src/main/resources</directory>
- </resource>
- </resources>
- <overwrite>true</overwrite>
- </configuration>
- </execution>
- <execution>
- <id>copy-local-resources-to-jar</id>
- <phase>generate-sources</phase>
- <goals>
- <goal>copy-resources</goal>
- </goals>
- <configuration>
- <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
- <filtering>false</filtering>
- <resources>
- <resource>
- <directory>src/main/resources/webapp</directory>
- </resource>
- </resources>
- <overwrite>true</overwrite>
+ <artifactItems>
+ <artifactItem>
+ <groupId>org.onap.policy.apex-pdp.client</groupId>
+ <artifactId>client-common</artifactId>
+ <version>${project.version}</version>
+ <type>jar</type>
+ <overWrite>false</overWrite>
+ <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
+ <excludes>META-INF/</excludes>
+ <excludes>webapp/css/styles.css, webapp/css/interfaceAssets.css</excludes>
+ </artifactItem>
+ </artifactItems>
+ <overWriteReleases>true</overWriteReleases>
+ <overWriteSnapshots>true</overWriteSnapshots>
</configuration>
</execution>
</executions>
</plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
@@ -250,6 +219,45 @@
<profiles>
<profile>
+ <id>only-eclipse</id>
+ <activation>
+ <property>
+ <name>m2e.version</name>
+ </property>
+ </activation>
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.eclipse.m2e</groupId>
+ <artifactId>lifecycle-mapping</artifactId>
+ <version>1.0.0</version>
+ <configuration>
+ <lifecycleMappingMetadata>
+ <pluginExecutions>
+ <pluginExecution>
+ <pluginExecutionFilter>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <versionRange>[2.0,)</versionRange>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ </pluginExecutionFilter>
+ <action>
+ <ignore />
+ </action>
+ </pluginExecution>
+ </pluginExecutions>
+ </lifecycleMappingMetadata>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+ </profile>
+
+ <profile>
<id>apexSite</id>
<activation>
<property>
diff --git a/client/client-editor/src/main/java/org/onap/policy/apex/client/editor/rest/handling/ApexEditorRestResource.java b/client/client-editor/src/main/java/org/onap/policy/apex/client/editor/rest/handling/ApexEditorRestResource.java
index e5660c9fa..fdd310150 100644
--- a/client/client-editor/src/main/java/org/onap/policy/apex/client/editor/rest/handling/ApexEditorRestResource.java
+++ b/client/client-editor/src/main/java/org/onap/policy/apex/client/editor/rest/handling/ApexEditorRestResource.java
@@ -122,8 +122,8 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Load the model from a JSON string for this session.
*
- * @param jsonString the JSON string to be parsed. The returned value(s) will be similar to {@link AxPolicyModel},
- * with merged {@linkplain AxKeyInfo} for the root object.
+ * @param jsonString the JSON string to be parsed. The returned value(s) will be similar to {@code AxPolicyModel},
+ * with merged {@code AxKeyInfo} for the root object.
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -162,7 +162,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Creates the new model model for this session.
*
- * @param jsonString the JSON string to be parsed containing the new model. See {@linkplain BeanModel}
+ * @param jsonString the JSON string to be parsed containing the new model. See {@code BeanModel}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -175,7 +175,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Update the model for this session.
*
- * @param jsonString the JSON string to be parsed containing the updated model. See {@linkplain BeanModel}
+ * @param jsonString the JSON string to be parsed containing the updated model. See {@code BeanModel}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -187,7 +187,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Gets the key for the model for this session. If successful the model key will be available in the first message
- * in the result. See {@linkplain AxKey}
+ * in the result. See {@code AxKey}
*
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
@@ -200,7 +200,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Retrieve the model for this session. If successful the model will be available in the first message in the
- * result. The returned value will be similar to a {@link AxPolicyModel}, with merged {@linkplain AxKeyInfo} for the
+ * result. The returned value will be similar to a {@code AxPolicyModel}, with merged {@code AxKeyInfo} for the
* root object.
*
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
@@ -215,7 +215,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Download the model for this session as a String.
*
- * @return the model represented as a JSON string. See {@linkplain AxPolicyModel}
+ * @return the model represented as a JSON string. See {@code AxPolicyModel}
*/
@GET
@Path("Model/Download")
@@ -242,7 +242,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* List key information with the given key names/versions. If successful the result(s) will be available in the
- * result messages. See {@linkplain AxKeyInfo}
+ * result messages. See {@code AxKeyInfo}
*
* @param name the name to search for. If null or empty, then all names will be queried
* @param version the version to search for. If null then all versions will be searched for.
@@ -259,7 +259,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Creates a context schema with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanContextSchema}
+ * @param jsonString the JSON string to be parsed. See {@code BeanContextSchema}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -272,7 +272,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Update a context schema with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanContextSchema}
+ * @param jsonString the JSON string to be parsed. See {@code BeanContextSchema}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -284,8 +284,8 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* List context schemas with the given key names/versions. If successful the result(s) will be available in the
- * result messages. The returned value(s) will be similar to {@link AxContextSchema}, with merged
- * {@linkplain AxKeyInfo} for the root object.
+ * result messages. The returned value(s) will be similar to {@code AxContextSchema}, with merged
+ * {@code AxKeyInfo} for the root object.
*
* @param name the name to search for. If null or empty, then all names will be queried
* @param version the version to search for. If null then all versions will be searched for.
@@ -333,7 +333,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Creates a context album with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanContextAlbum}
+ * @param jsonString the JSON string to be parsed. See {@code BeanContextAlbum}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -346,7 +346,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Update a context album with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanContextAlbum}
+ * @param jsonString the JSON string to be parsed. See {@code BeanContextAlbum}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -358,8 +358,8 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* List context albums with the given key names/versions. If successful the result(s) will be available in the
- * result messages. The returned value(s) will be similar to {@link AxContextAlbum}, with merged
- * {@linkplain AxKeyInfo} for the root object.
+ * result messages. The returned value(s) will be similar to {@code AxContextAlbum}, with merged
+ * {@code AxKeyInfo} for the root object.
*
* @param name the name to search for. If null or empty, then all names will be queried
* @param version the version to search for. If null then all versions will be searched for.
@@ -407,7 +407,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Creates an event with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanEvent}
+ * @param jsonString the JSON string to be parsed. See {@code BeanEvent}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -420,7 +420,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Update an event with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanEvent}
+ * @param jsonString the JSON string to be parsed. See {@code BeanEvent}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -432,7 +432,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* List events with the given key names/versions. If successful the result(s) will be available in the result
- * messages. The returned value(s) will be similar to {@link AxEvent}, with merged {@linkplain AxKeyInfo} for the
+ * messages. The returned value(s) will be similar to {@code AxEvent}, with merged {@code AxKeyInfo} for the
* root object.
*
* @param name the name to search for. If null or empty, then all names will be queried
@@ -477,7 +477,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Creates a task with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanTask}
+ * @param jsonString the JSON string to be parsed. See {@code BeanTask}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -490,7 +490,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Update a task with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanTask}
+ * @param jsonString the JSON string to be parsed. See {@code BeanTask}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -502,7 +502,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* List tasks with the given key names/versions. If successful the result(s) will be available in the result
- * messages. The returned value(s) will be similar to {@link AxTask}, with merged {@linkplain AxKeyInfo} for the
+ * messages. The returned value(s) will be similar to {@code AxTask}, with merged {@code AxKeyInfo} for the
* root object.
*
* @param name the name to search for. If null or empty, then all names will be queried
@@ -548,7 +548,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* Creates a policy with the information in the JSON string passed.
*
- * @param jsonString the JSON string to be parsed See {@linkplain BeanPolicy}
+ * @param jsonString the JSON string to be parsed See {@code BeanPolicy}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -562,7 +562,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
* Update a policy with the information in the JSON string passed.
*
* @param firstStatePeriodic indicates if periodic event should be created and added to model
- * @param jsonString the JSON string to be parsed. See {@linkplain BeanPolicy}
+ * @param jsonString the JSON string to be parsed. See {@code BeanPolicy}
* @return an ApexAPIResult object. If successful then {@link ApexApiResult#isOk()} will return true. Any
* messages/errors can be retrieved using {@link ApexApiResult#getMessages()}
*/
@@ -580,7 +580,7 @@ public class ApexEditorRestResource implements RestCommandHandler {
/**
* List policies with the given key names/versions. If successful the result(s) will be available in the result
- * messages. The returned value(s) will be similar to {@link AxPolicy}, with merged {@linkplain AxKey Info} for the
+ * messages. The returned value(s) will be similar to {@code AxPolicy}, with merged {@code AxKeyInfo} for the
* root object.
*
* @param name the name to search for. If null or empty, then all names will be queried
diff --git a/client/client-full/pom.xml b/client/client-full/pom.xml
index a157d7657..ae987c55c 100644
--- a/client/client-full/pom.xml
+++ b/client/client-full/pom.xml
@@ -17,7 +17,8 @@
SPDX-License-Identifier: Apache-2.0
============LICENSE_END=========================================================
-->
-<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">
+<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">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.policy.apex-pdp.client</groupId>
@@ -60,51 +61,92 @@
<include>webapp/**/*.*</include>
</includes>
</resource>
- <resource>
- <directory>../client-monitoring/target/classes/webapp</directory>
- <includes>
- <include>**/*.*</include>
- </includes>
- <targetPath>webapp/monitoring</targetPath>
- </resource>
- <resource>
- <directory>../client-editor/target/classes/webapp</directory>
- <includes>
- <include>**/*.*</include>
- </includes>
- <targetPath>webapp/editor</targetPath>
- </resource>
- <resource>
- <directory>../client-deployment/target/classes/webapp</directory>
- <includes>
- <include>**/*.*</include>
- </includes>
- <targetPath>webapp/deployment</targetPath>
- </resource>
</resources>
<defaultGoal>install</defaultGoal>
<outputDirectory>${project.build.directory}/classes</outputDirectory>
<plugins>
+ <!-- Copy sub-clients this client's webapp directory -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
- <id>unpack-client-editor-shared-resources</id>
+ <id>unpack-examples</id>
+ <phase>validate</phase>
<goals>
- <goal>unpack-dependencies</goal>
+ <goal>unpack</goal>
</goals>
- <phase>generate-resources</phase>
<configuration>
- <outputDirectory>${project.build.directory}/${project.artifactId}-${project.version}</outputDirectory>
- <includeArtifacIds>client-common</includeArtifacIds>
- <includeGroupIds>${project.groupId}</includeGroupIds>
- <excludeTransitive>true</excludeTransitive>
+ <artifactItems>
+ <artifactItem>
+ <groupId>org.onap.policy.apex-pdp.client</groupId>
+ <artifactId>client-monitoring</artifactId>
+ <version>${project.version}</version>
+ <type>jar</type>
+ <overWrite>false</overWrite>
+ <outputDirectory>${project.build.directory}/classes/webapp/monitoring-temp</outputDirectory>
+ <excludes>META-INF/, org/</excludes>
+ </artifactItem>
+ <artifactItem>
+ <groupId>org.onap.policy.apex-pdp.client</groupId>
+ <artifactId>client-deployment</artifactId>
+ <version>${project.version}</version>
+ <type>jar</type>
+ <overWrite>false</overWrite>
+ <outputDirectory>${project.build.directory}/classes/webapp/deployment-temp</outputDirectory>
+ <excludes>META-INF/, org/</excludes>
+ </artifactItem>
+ <artifactItem>
+ <groupId>org.onap.policy.apex-pdp.client</groupId>
+ <artifactId>client-editor</artifactId>
+ <version>${project.version}</version>
+ <type>jar</type>
+ <overWrite>false</overWrite>
+ <outputDirectory>${project.build.directory}/classes/webapp/editor-temp</outputDirectory>
+ <excludes>META-INF/, org/</excludes>
+ </artifactItem>
+ </artifactItems>
+ <overWriteReleases>true</overWriteReleases>
+ <overWriteSnapshots>true</overWriteSnapshots>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <version>1.8</version>
+ <executions>
+ <execution>
+ <phase>initialize</phase>
+ <configuration>
+ <target>
+ <copy todir="${project.build.directory}/classes/webapp/deployment">
+ <fileset dir="${project.build.directory}/classes/webapp/deployment-temp/webapp"
+ includes="**" />
+ </copy>
+ <copy todir="${project.build.directory}/classes/webapp/monitoring">
+ <fileset dir="${project.build.directory}/classes/webapp/monitoring-temp/webapp"
+ includes="**" />
+ </copy>
+ <copy todir="${project.build.directory}/classes/webapp/editor">
+ <fileset dir="${project.build.directory}/classes/webapp/editor-temp/webapp"
+ includes="**" />
+ </copy>
+ <delete dir="${project.build.directory}/classes/webapp/deployment-temp"/>
+ <delete dir="${project.build.directory}/classes/webapp/monitoring-temp"/>
+ <delete dir="${project.build.directory}/classes/webapp/editor-temp"/>
+ </target>
</configuration>
+ <goals>
+ <goal>run</goal>
+ </goals>
</execution>
</executions>
</plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
@@ -136,14 +178,18 @@
</filter>
</filters>
<transformers>
- <transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
- <transformer implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
<resource>reference.conf</resource>
</transformer>
- <transformer implementation="org.apache.maven.plugins.shade.resource.DontIncludeResourceTransformer">
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.DontIncludeResourceTransformer">
<resource>log4j.properties</resource>
</transformer>
- <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
+ <transformer
+ implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>org.onap.policy.apex.client.full.rest.ApexServicesRestMain</mainClass>
</transformer>
</transformers>
@@ -197,6 +243,58 @@
<profiles>
<profile>
+ <id>only-eclipse</id>
+ <activation>
+ <property>
+ <name>m2e.version</name>
+ </property>
+ </activation>
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.eclipse.m2e</groupId>
+ <artifactId>lifecycle-mapping</artifactId>
+ <version>1.0.0</version>
+ <configuration>
+ <lifecycleMappingMetadata>
+ <pluginExecutions>
+ <pluginExecution>
+ <pluginExecutionFilter>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <versionRange>[2.0,)</versionRange>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ </pluginExecutionFilter>
+ <action>
+ <ignore />
+ </action>
+ </pluginExecution>
+ <pluginExecution>
+ <pluginExecutionFilter>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <versionRange>[1.0,)</versionRange>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ </pluginExecutionFilter>
+ <action>
+ <ignore />
+ </action>
+ </pluginExecution>
+ </pluginExecutions>
+ </lifecycleMappingMetadata>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+ </profile>
+
+ <profile>
<id>apexSite</id>
<activation>
<property>
diff --git a/client/client-full/src/main/java/org/onap/policy/apex/client/full/rest/ApexServicesRestMain.java b/client/client-full/src/main/java/org/onap/policy/apex/client/full/rest/ApexServicesRestMain.java
index 7b9f4187d..02670511c 100644
--- a/client/client-full/src/main/java/org/onap/policy/apex/client/full/rest/ApexServicesRestMain.java
+++ b/client/client-full/src/main/java/org/onap/policy/apex/client/full/rest/ApexServicesRestMain.java
@@ -199,6 +199,7 @@ public class ApexServicesRestMain {
}
}
}
+
/**
* Main method, main entry point for command.
*
diff --git a/client/client-monitoring/pom.xml b/client/client-monitoring/pom.xml
index 61c1775b7..17f2cc178 100644
--- a/client/client-monitoring/pom.xml
+++ b/client/client-monitoring/pom.xml
@@ -39,9 +39,6 @@
<groupId>org.onap.policy.apex-pdp.client</groupId>
<artifactId>client-common</artifactId>
<version>${project.version}</version>
- <classifier>resources</classifier>
- <type>zip</type>
- <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.containers</groupId>
@@ -73,65 +70,36 @@
<defaultGoal>install</defaultGoal>
<outputDirectory>${project.build.directory}/classes</outputDirectory>
<plugins>
+ <!-- Copy common resources to this client's webapp directory -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
- <id>unpack-client-monitoring-shared-resources</id>
- <goals>
- <goal>unpack-dependencies</goal>
- </goals>
+ <id>unpack-examples</id>
<phase>validate</phase>
- <configuration>
- <outputDirectory>${project.build.directory}/${project.artifactId}-${project.version}</outputDirectory>
- <includeArtifacIds>client-common</includeArtifacIds>
- <includeGroupIds>${project.groupId}</includeGroupIds>
- <excludeTransitive>true</excludeTransitive>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <executions>
- <execution>
- <id>copy-common-resources-to-jar</id>
- <phase>initialize</phase>
<goals>
- <goal>copy-resources</goal>
+ <goal>unpack</goal>
</goals>
<configuration>
- <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
- <filtering>false</filtering>
- <resources>
- <resource>
- <directory>../client-common/src/main/resources</directory>
- </resource>
- </resources>
- <overwrite>true</overwrite>
- </configuration>
- </execution>
- <execution>
- <id>copy-local-resources-to-jar</id>
- <phase>generate-sources</phase>
- <goals>
- <goal>copy-resources</goal>
- </goals>
- <configuration>
- <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
- <filtering>false</filtering>
- <resources>
- <resource>
- <directory>src/main/resources/webapp</directory>
- </resource>
- </resources>
- <overwrite>true</overwrite>
+ <artifactItems>
+ <artifactItem>
+ <groupId>org.onap.policy.apex-pdp.client</groupId>
+ <artifactId>client-common</artifactId>
+ <version>${project.version}</version>
+ <type>jar</type>
+ <overWrite>false</overWrite>
+ <outputDirectory>${project.build.directory}/classes/webapp</outputDirectory>
+ <excludes>META-INF/</excludes>
+ </artifactItem>
+ </artifactItems>
+ <overWriteReleases>true</overWriteReleases>
+ <overWriteSnapshots>true</overWriteSnapshots>
</configuration>
</execution>
</executions>
</plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
@@ -224,6 +192,45 @@
<profiles>
<profile>
+ <id>only-eclipse</id>
+ <activation>
+ <property>
+ <name>m2e.version</name>
+ </property>
+ </activation>
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.eclipse.m2e</groupId>
+ <artifactId>lifecycle-mapping</artifactId>
+ <version>1.0.0</version>
+ <configuration>
+ <lifecycleMappingMetadata>
+ <pluginExecutions>
+ <pluginExecution>
+ <pluginExecutionFilter>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <versionRange>[2.0,)</versionRange>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ </pluginExecutionFilter>
+ <action>
+ <ignore />
+ </action>
+ </pluginExecution>
+ </pluginExecutions>
+ </lifecycleMappingMetadata>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+ </profile>
+
+ <profile>
<id>apexSite</id>
<activation>
<property>