aboutsummaryrefslogtreecommitdiffstats
path: root/examples/examples-onap-vcpe/pom.xml
diff options
context:
space:
mode:
authorliamfallon <liam.fallon@est.tech>2019-12-19 21:42:34 -0600
committerliamfallon <liam.fallon@est.tech>2020-01-08 10:19:06 +0000
commit7a8e49a16020f7d04724803659f365236987c5ed (patch)
tree3b858f1c7f150ab6076dd61ba62c069607843d82 /examples/examples-onap-vcpe/pom.xml
parent004f3557013cb1919754a7318b0005e00b6867de (diff)
Update vCPE example to use Avro schemas
THis change updates the vCPE example to show how the example can work towards the APPC using Avro schemas only. This means that Policies can be adapted to changes in controller APIs using Avro alone. This example works with the old and new format policy-models. Issue-ID: POLICY-2043 Change-Id: I42ac0eac5203eaa37316cf6c460c67f7e8d6deb2 Signed-off-by: liamfallon <liam.fallon@est.tech>
Diffstat (limited to 'examples/examples-onap-vcpe/pom.xml')
-rw-r--r--examples/examples-onap-vcpe/pom.xml41
1 files changed, 40 insertions, 1 deletions
diff --git a/examples/examples-onap-vcpe/pom.xml b/examples/examples-onap-vcpe/pom.xml
index 9f6c285c4..e6917ef2f 100644
--- a/examples/examples-onap-vcpe/pom.xml
+++ b/examples/examples-onap-vcpe/pom.xml
@@ -1,7 +1,7 @@
<!--
============LICENSE_START=======================================================
Copyright (C) 2018 Ericsson. All rights reserved.
- Copyright (C) 2019 Nordix Foundation.
+ Modifications Copyright (C) 2019-2020 Nordix Foundation.
================================================================================
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
@@ -34,6 +34,8 @@
<properties>
<policymodel.name>ONAPvCPEPolicyModel</policymodel.name>
<toscapolicy.name>ONAPvCPEToscaPolicy</toscapolicy.name>
+ <policymodelstandalone.name>ONAPvCPEPolicyModelStandalone</policymodelstandalone.name>
+ <toscapolicystandalone.name>ONAPvCPEToscaPolicyStandalone</toscapolicystandalone.name>
<apex-domains-onap-vcpe-dir>${project.basedir}/src</apex-domains-onap-vcpe-dir>
</properties>
@@ -134,6 +136,43 @@
</arguments>
</configuration>
</execution>
+ <!-- Generate the Standalone APEX Policy JSON from the APEX CLI command -->
+ <execution>
+ <id>generate-standalone-policy</id>
+ <phase>compile</phase>
+ <goals>
+ <goal>java</goal>
+ </goals>
+ <configuration>
+ <mainClass>org.onap.policy.apex.auth.clieditor.ApexCommandLineEditorMain</mainClass>
+ <classpathScope>compile</classpathScope>
+ <arguments>
+ <argument>--command-file=${project.basedir}/src/main/resources/policy/${policymodelstandalone.name}.apex</argument>
+ <argument>--output-model-file=${project.build.directory}/classes/${policymodelstandalone.name}.json</argument>
+ <argument>--log-file=${project.build.directory}/${policymodelstandalone.name}_policygeneration.log</argument>
+ <argument>--working-dir=${project.basedir}</argument>
+ </arguments>
+ </configuration>
+ </execution>
+ <!-- Generate the standalone APEX ToscaPolicy JSON file-->
+ <execution>
+ <id>generate-standalone-tosca-policy</id>
+ <phase>compile</phase>
+ <goals>
+ <goal>java</goal>
+ </goals>
+ <configuration>
+ <mainClass>org.onap.policy.apex.auth.clieditor.tosca.ApexCliToscaEditorMain</mainClass>
+ <classpathScope>compile</classpathScope>
+ <arguments>
+ <argument>--command-file=${project.basedir}/src/main/resources/policy/${policymodelstandalone.name}.apex</argument>
+ <argument>--output-tosca-file=${project.build.directory}/classes/${toscapolicystandalone.name}.json</argument>
+ <argument>--log-file=${project.build.directory}/${policymodelstandalone.name}_policygeneration.log</argument>
+ <argument>--apex-config-file=${project.basedir}/src/main/resources/examples/config/ONAPvCPEStandalone/ApexConfig.json</argument>
+ <argument>--tosca-template-file=${project.basedir}/src/main/resources/tosca/ToscaTemplate.json</argument>
+ </arguments>
+ </configuration>
+ </execution>
</executions>
</plugin>
</plugins>