summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--aai-core/src/main/java/org/onap/aai/introspection/MoxyStrategy.java10
-rw-r--r--aai-core/src/main/resources/dbedgerules/DbEdgeRules_v12.json72
-rw-r--r--aai-schema/src/main/resources/aai_schema/aai_schema_v12.xsd155
-rw-r--r--aai-schema/src/main/resources/oxm/aai_oxm_v12.xml136
4 files changed, 365 insertions, 8 deletions
diff --git a/aai-core/src/main/java/org/onap/aai/introspection/MoxyStrategy.java b/aai-core/src/main/java/org/onap/aai/introspection/MoxyStrategy.java
index ce04fb7f..c5f4570d 100644
--- a/aai-core/src/main/java/org/onap/aai/introspection/MoxyStrategy.java
+++ b/aai-core/src/main/java/org/onap/aai/introspection/MoxyStrategy.java
@@ -292,14 +292,8 @@ public class MoxyStrategy extends Introspector {
keys = this.getKeys();
List<String> results = new ArrayList<>();
for (String key : keys) {
- if (this.getType(key).toLowerCase().contains("long")) {
- key = ((Long)this.getValue(key)).toString();
- } else {
- key = (String)this.getValue(key);
- }
- key = UriUtils.encode(key, "UTF-8");
-
- results.add(key);
+ String value = UriUtils.encode(this.getValue(key).toString(), "UTF-8");
+ results.add(value);
}
return Joiner.on("/").join(results);
diff --git a/aai-core/src/main/resources/dbedgerules/DbEdgeRules_v12.json b/aai-core/src/main/resources/dbedgerules/DbEdgeRules_v12.json
index 4c721566..770124dc 100644
--- a/aai-core/src/main/resources/dbedgerules/DbEdgeRules_v12.json
+++ b/aai-core/src/main/resources/dbedgerules/DbEdgeRules_v12.json
@@ -2459,6 +2459,78 @@
"SVC-INFRA": "${direction}",
"prevent-delete": "NONE",
"default": "true"
+ },
+ {
+ "from": "configuration",
+ "to": "l-interface",
+ "label": "has",
+ "direction": "OUT",
+ "multiplicity": "ONE2MANY",
+ "contains-other-v": "NONE",
+ "delete-other-v": "NONE",
+ "SVC-INFRA": "NONE",
+ "prevent-delete": "NONE",
+ "default": "true"
+ },
+ {
+ "from": "configuration",
+ "to": "pnf",
+ "label": "uses",
+ "direction": "OUT",
+ "multiplicity": "ONE2MANY",
+ "contains-other-v": "NONE",
+ "delete-other-v": "NONE",
+ "SVC-INFRA": "NONE",
+ "prevent-delete": "NONE",
+ "default": "true"
+ },
+ {
+ "from": "forwarder",
+ "to": "p-interface",
+ "label": "forwardsTo",
+ "direction": "OUT",
+ "multiplicity": "ONE2ONE",
+ "contains-other-v": "NONE",
+ "delete-other-v": "NONE",
+ "SVC-INFRA": "NONE",
+ "prevent-delete": "NONE",
+ "default": "true"
+ },
+ {
+ "from": "forwarder",
+ "to": "l-interface",
+ "label": "forwardsTo",
+ "direction": "OUT",
+ "multiplicity": "ONE2ONE",
+ "contains-other-v": "NONE",
+ "delete-other-v": "NONE",
+ "SVC-INFRA": "NONE",
+ "prevent-delete": "NONE",
+ "default": "true"
+ },
+ {
+ "from": "forwarder",
+ "to": "forwarding-path",
+ "label": "belongsTo",
+ "direction": "OUT",
+ "multiplicity": "MANY2ONE",
+ "contains-other-v": "!${direction}",
+ "delete-other-v": "!${direction}",
+ "SVC-INFRA": "NONE",
+ "prevent-delete": "NONE",
+ "default": "true"
+ },
+ {
+ "from": "forwarding-path",
+ "to": "service-instance",
+ "label": "implements",
+ "direction": "OUT",
+ "multiplicity": "MANY2ONE",
+ "contains-other-v": "NONE",
+ "delete-other-v": "!${direction}",
+ "SVC-INFRA": "NONE",
+ "prevent-delete": "NONE",
+ "default": "true"
}
]
}
diff --git a/aai-schema/src/main/resources/aai_schema/aai_schema_v12.xsd b/aai-schema/src/main/resources/aai_schema/aai_schema_v12.xsd
index 9d25a6f6..78f918e5 100644
--- a/aai-schema/src/main/resources/aai_schema/aai_schema_v12.xsd
+++ b/aai-schema/src/main/resources/aai_schema/aai_schema_v12.xsd
@@ -7292,6 +7292,87 @@ xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
</xs:sequence>
</xs:complexType>
</xs:element>
+ <xs:element name="forwarder">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="class">@org.onap.aai.annotations.Metadata(indexedProps="sequence",description="Entity describing a sequenced segment of forwarding path",container="forwarders",dependentOn="forwarding-path")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element name="sequence" type="xs:int">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(isKey=true,description="Unique ID of this segmentation")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element ref="tns:relationship-list" minOccurs="0"/>
+ <xs:element name="resource-version" type="xs:string" minOccurs="0">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Used for optimistic concurrency. Must be empty on create, valid on update and delete.")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="forwarders">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="tns:forwarder" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="forwarding-path">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="class">@org.onap.aai.annotations.Metadata(namespace="network",indexedProps="forwarding-path-id,forwarding-path-name",description="Entity that describes the sequenced forwarding path between interfaces of services or resources",container="forwarding-paths",nameProps="forwarding-path-name",uniqueProps="forwarding-path-id")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element name="forwarding-path-id" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(isKey=true,description="Unique ID of this FP")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="forwarding-path-name" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Name of the FP")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element ref="tns:relationship-list" minOccurs="0"/>
+ <xs:element name="resource-version" type="xs:string" minOccurs="0">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Used for optimistic concurrency. Must be empty on create, valid on update and delete.")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="selflink" type="xs:string" minOccurs="0">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="the self link for this FP")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element ref="tns:forwarders" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="forwarding-paths">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="tns:forwarding-path" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
<xs:element name="network">
<xs:complexType>
<xs:annotation>
@@ -7319,6 +7400,7 @@ xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
<xs:element ref="tns:instance-groups" minOccurs="0"/>
<xs:element ref="tns:zones" minOccurs="0"/>
<xs:element ref="tns:configurations" minOccurs="0"/>
+ <xs:element ref="tns:forwarding-paths" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
</xs:element>
@@ -7628,4 +7710,77 @@ xmlns:jaxb="http://java.sun.com/xml/ns/jaxb"
</xs:sequence>
</xs:complexType>
</xs:element>
+ <xs:element name="operational-environment">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="class">@org.onap.aai.annotations.Metadata(description="It is a logical partition of the cloud which allows to have multiple environments in the production AIC.",indexedProps="operational-environment-id",uniqueProps="operational-environment-id",container="operational-environments",namespace="cloud-infrastructure")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element name="operational-environment-id" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(isKey=true,description="UUID of an operational environment")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="operational-environment-name" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Operational Environment name")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="operational-environment-type" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Operational Environment Type.")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="operational-environment-status" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Status")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="tenant-context" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Tenant Context.")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="workload-context" type="xs:string">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Workload Context.")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element name="resource-version" type="xs:string" minOccurs="0">
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="field">@org.onap.aai.annotations.Metadata(description="Used for optimistic concurrency. Must be empty on create, valid on update and delete.")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ </xs:element>
+ <xs:element ref="tns:relationship-list" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="operational-environments">
+ <xs:complexType>
+ <xs:annotation>
+ <xs:appinfo>
+ <annox:annotate target="class">@org.onap.aai.annotations.Metadata(description="a logical partition of the cloud which allows to have multiple environments in the production AIC.")</annox:annotate>
+ </xs:appinfo>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element ref="tns:operational-environment" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
</xs:schema>
diff --git a/aai-schema/src/main/resources/oxm/aai_oxm_v12.xml b/aai-schema/src/main/resources/oxm/aai_oxm_v12.xml
index 008e7f9b..79bbdf8b 100644
--- a/aai-schema/src/main/resources/oxm/aai_oxm_v12.xml
+++ b/aai-schema/src/main/resources/oxm/aai_oxm_v12.xml
@@ -2872,6 +2872,7 @@
<xml-element java-attribute="instanceGroups" name="instance-groups" type="inventory.aai.onap.org.v12.InstanceGroups" />
<xml-element java-attribute="zones" name="zones" type="inventory.aai.onap.org.v12.Zones" />
<xml-element java-attribute="configurations" name="configurations" type="inventory.aai.onap.org.v12.Configurations" />
+ <xml-element java-attribute="forwardingPaths" name="forwarding-paths" type="inventory.aai.onap.org.v12.ForwardingPaths" />
</java-attributes>
</java-type>
<java-type name="Configurations">
@@ -6356,5 +6357,140 @@
<xml-property name="dependentOn" value="cloud-region" />
</xml-properties>
</java-type>
+
+ <java-type name="OperationalEnvironments">
+ <xml-properties>
+ <xml-property name="description" value="a logical partition of the cloud which allows to have multiple environments in the production AIC." />
+ </xml-properties>
+ <xml-root-element name="operational-environments" />
+ <java-attributes>
+ <xml-element container-type="java.util.ArrayList" java-attribute="operationalEnvironment" name="operational-environment" type="inventory.aai.onap.org.v12.OperationalEnvironment" />
+ </java-attributes>
+ <xml-properties>
+ <xml-property name="maximumDepth" value="0" />
+ </xml-properties>
+ </java-type>
+
+ <java-type name="OperationalEnvironment">
+ <xml-root-element name="operational-environment" />
+ <java-attributes>
+ <xml-element java-attribute="operationalEnvironmentId" name="operational-environment-id" required="true" type="java.lang.String" xml-key="true">
+ <xml-properties>
+ <xml-property name="description" value="UUID of an operational environment" />
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="operationalEnvironmentName" name="operational-environment-name" required="true" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Operational Environment name" />
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="operationalEnvironmentType" name="operational-environment-type" required="true" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Operational Environment Type." />
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="operationalEnvironmentStatus" name="operational-environment-status" required="true" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Status" />
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="tenantContext" name="tenant-context" required="true" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Tenant Context." />
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="workloadContext" name="workload-context" required="true" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Workload Context." />
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="resourceVersion" name="resource-version" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Used for optimistic concurrency. Must be empty on create, valid on update and delete." />
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="relationshipList" name="relationship-list" type="inventory.aai.onap.org.v12.RelationshipList" />
+ </java-attributes>
+ <xml-properties>
+ <xml-property name="description" value="It is a logical partition of the cloud which allows to have multiple environments in the production AIC." />
+ <xml-property name="indexedProps" value="operational-environment-id" />
+ <xml-property name="uniqueProps" value="operational-environment-id" />
+ <xml-property name="container" value="operational-environments" />
+ <xml-property name="namespace" value="cloud-infrastructure" />
+ </xml-properties>
+ </java-type>
+
+ <java-type name="ForwardingPaths">
+ <xml-root-element name="forwarding-paths" />
+ <java-attributes>
+ <xml-element container-type="java.util.ArrayList" java-attribute="forwardingPath" name="forwarding-path" type="inventory.aai.onap.org.v12.ForwardingPath" />
+ </java-attributes>
+ </java-type>
+
+ <java-type name="ForwardingPath">
+ <xml-root-element name="forwarding-path"/>
+ <xml-properties>
+ <xml-property name="namespace" value="network"/>
+ <xml-property name="indexedProps" value="forwarding-path-id,forwarding-path-name"/>
+ <xml-property name="description" value="Entity that describes the sequenced forwarding path between interfaces of services or resources"/>
+ <xml-property name="container" value="forwarding-paths" />
+ <xml-property name="nameProps" value="forwarding-path-name" />
+ <xml-property name="uniqueProps" value="forwarding-path-id" />
+ </xml-properties>
+ <java-attributes>
+ <xml-element java-attribute="forwardingPathId" name="forwarding-path-id" required="true" type="java.lang.String" xml-key="true">
+ <xml-properties>
+ <xml-property name="description" value="Unique ID of this FP"/>
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="forwardingPathName" name="forwarding-path-name" required="true" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Name of the FP"/>
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="relationshipList" name="relationship-list" type="inventory.aai.onap.org.v12.RelationshipList"/>
+ <xml-element java-attribute="resourceVersion" name="resource-version" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Used for optimistic concurrency. Must be empty on create, valid on update and delete."/>
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="selflink" name="selflink" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="the self link for this FP"/>
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="forwarders" name="forwarders" type="inventory.aai.onap.org.v12.Forwarders" />
+ </java-attributes>
+ </java-type>
+
+ <java-type name="Forwarders">
+ <xml-root-element name="forwarders" />
+ <java-attributes>
+ <xml-element container-type="java.util.ArrayList" java-attribute="forwarder" name="forwarder" type="inventory.aai.onap.org.v12.Forwarder" />
+ </java-attributes>
+ </java-type>
+
+ <java-type name="Forwarder">
+ <xml-root-element name="forwarder"/>
+ <xml-properties>
+ <xml-property name="indexedProps" value="sequence"/>
+ <xml-property name="description" value="Entity describing a sequenced segment of forwarding path"/>
+ <xml-property name="container" value="forwarders" />
+ <xml-property name="dependentOn" value="forwarding-path" />
+ </xml-properties>
+ <java-attributes>
+ <xml-element java-attribute="sequence" name="sequence" required="true" type="java.lang.Integer" xml-key="true">
+ <xml-properties>
+ <xml-property name="description" value="Unique ID of this segmentation"/>
+ </xml-properties>
+ </xml-element>
+ <xml-element java-attribute="relationshipList" name="relationship-list" type="inventory.aai.onap.org.v12.RelationshipList"/>
+ <xml-element java-attribute="resourceVersion" name="resource-version" type="java.lang.String">
+ <xml-properties>
+ <xml-property name="description" value="Used for optimistic concurrency. Must be empty on create, valid on update and delete."/>
+ </xml-properties>
+ </xml-element>
+ </java-attributes>
+ </java-type>
</java-types>
</xml-bindings>