summaryrefslogtreecommitdiffstats
path: root/models-tosca/src/test/resources
diff options
context:
space:
mode:
authorrameshiyer27 <ramesh.murugan.iyer@est.tech>2022-02-07 17:07:38 +0000
committerrameshiyer27 <ramesh.murugan.iyer@est.tech>2022-02-10 14:20:42 +0000
commit45b653fc5a8d641452247eca5c80cf580609e9bf (patch)
tree06cfd4529db05dc23cbd63d2fe2e53799eb07bdf /models-tosca/src/test/resources
parent303d42453fbfcf2381f810b10a496b69aa8bc34b (diff)
Add policy metadataSet handling as node templates
Each metadataSet is represented as a 'node_template' in Tosca mapped to a specific node type. Support added for db operations of node templates as independent entities. Detailed documentation available here : https://wiki.onap.org/display/DW/Enable+Handling+of+Policy+Type+Metadata Issue-ID: POLICY-3832 Signed-off-by: zrrmmua <ramesh.murugan.iyer@est.tech> Change-Id: I6c189142b1778ba858aae27cd92d4f136d950208
Diffstat (limited to 'models-tosca/src/test/resources')
-rw-r--r--models-tosca/src/test/resources/nodetemplates/TestCreateMetadataSet.json31
-rw-r--r--models-tosca/src/test/resources/nodetemplates/TestUpdateMetadataSet.json23
2 files changed, 54 insertions, 0 deletions
diff --git a/models-tosca/src/test/resources/nodetemplates/TestCreateMetadataSet.json b/models-tosca/src/test/resources/nodetemplates/TestCreateMetadataSet.json
new file mode 100644
index 000000000..8620d3ef0
--- /dev/null
+++ b/models-tosca/src/test/resources/nodetemplates/TestCreateMetadataSet.json
@@ -0,0 +1,31 @@
+{
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "node_types": {
+ "org.onap.nodetypes.policy.MetadataSet2": {
+ "derived_from": "tosca.nodetypes.Root",
+ "version": "1.0.1"
+ }
+ },
+ "topology_template": {
+ "node_templates": {
+ "apexMetadata_adaptive": {
+ "version": "2.3.3",
+ "type": "org.onap.nodetypes.policy.MetadataSet2",
+ "type_version": "1.0.1",
+ "description": "Metadata set for an Adaptive Policy",
+ "metadata": {
+ "policyModel": {
+ "key": {
+ "name": "AdaptivePolicyModel",
+ "version": "1.2.2"
+ }
+ },
+ "radius": 1.23,
+ "height": 2.13,
+ "length": 46
+ }
+ }
+
+ }
+ }
+} \ No newline at end of file
diff --git a/models-tosca/src/test/resources/nodetemplates/TestUpdateMetadataSet.json b/models-tosca/src/test/resources/nodetemplates/TestUpdateMetadataSet.json
new file mode 100644
index 000000000..7fbad818c
--- /dev/null
+++ b/models-tosca/src/test/resources/nodetemplates/TestUpdateMetadataSet.json
@@ -0,0 +1,23 @@
+{
+ "tosca_definitions_version": "tosca_simple_yaml_1_1_0",
+ "topology_template": {
+ "node_templates": {
+ "apexMetadata_grpc": {
+ "version": "1.2.1",
+ "type": "org.onap.nodetypes.policy.MetadataSet",
+ "type_version": "1.0.0",
+ "description": "Updated Metadata set for GRPC",
+ "metadata": {
+ "policyModel": {
+ "key": {
+ "name": "GrpcPolicyModel",
+ "version": "1.0.1"
+ }
+ },
+ "threshold": 3.15,
+ "state": "active"
+ }
+ }
+ }
+ }
+} \ No newline at end of file