From 59b90519eda3b95b0cfc49b6349a591c7d0c78e2 Mon Sep 17 00:00:00 2001 From: liamfallon Date: Mon, 7 Feb 2022 17:56:44 +0000 Subject: Remove JAXB and XML, use GSON for JSON This review converst apex-pdp to use GSON for JSON handling. In order to preserve backward compatibility with the JAXB format of JSON, custom handling of maps was required. Therefore, the policy-common StandardCoder could not be used. There are a lot of small changes, removing annotations from concepts and tweaking of test data. However, this cleans up the code base so it is worth doing. Issue-ID: POLICY-1820 Change-Id: I213fa64f6d7f3f1df8d10f111d9fbedbe80f9fe0 Signed-off-by: liamfallon --- .../src/test/resources/json/ContextModel.json | 156 --------------------- 1 file changed, 156 deletions(-) delete mode 100644 model/context-model/src/test/resources/json/ContextModel.json (limited to 'model/context-model/src/test/resources') diff --git a/model/context-model/src/test/resources/json/ContextModel.json b/model/context-model/src/test/resources/json/ContextModel.json deleted file mode 100644 index 2c93ef1c2..000000000 --- a/model/context-model/src/test/resources/json/ContextModel.json +++ /dev/null @@ -1,156 +0,0 @@ -{ - "apexContextModel" : { - "key" : { - "name" : "contextModel", - "version" : "0.0.1" - }, - "keyInformation" : { - "key" : { - "name" : "KeyInfoMapKey", - "version" : "0.0.1" - }, - "keyInfoMap" : { - "keyInfoEntry" : [ { - "key" : { - "name" : "StringType", - "version" : "0.0.1" - }, - "UUID" : "00000000-0000-0000-0000-000000000000", - "description" : "axContextType0" - }, { - "key" : { - "name" : "MapType", - "version" : "0.0.1" - }, - "UUID" : "00000000-0000-0000-0000-000000000001", - "description" : "axContextType1" - }, { - "key" : { - "name" : "contextMap0", - "version" : "0.0.1" - }, - "UUID" : "00000000-0000-0000-0000-000000000002", - "description" : "contextMap0" - }, { - "key" : { - "name" : "contextMap1", - "version" : "0.0.1" - }, - "UUID" : "00000000-0000-0000-0000-000000000003", - "description" : "contextMap1" - }, { - "key" : { - "name" : "context", - "version" : "0.0.1" - }, - "UUID" : "00000000-0000-0000-0000-000000000004", - "description" : "axContext" - }, { - "key" : { - "name" : "contextModel", - "version" : "0.0.1" - }, - "UUID" : "00000000-0000-0000-0000-000000000005", - "description" : "contextModel" - }, { - "key" : { - "name" : "KeyInfoMapKey", - "version" : "0.0.1" - }, - "UUID" : "00000000-0000-0000-0000-000000000006", - "description" : "keyInformation" - } ] - } - }, - "context" : { - "key" : { - "name" : "context", - "version" : "0.0.1" - }, - "contextMaps" : { - "entry" : [ { - "key" : "contextMap0", - "value" : { - "key" : { - "name" : "contextMap0", - "version" : "0.0.1" - }, - "scope" : "APPLICATION", - "mapType" : "BAG", - "contextMap" : { - "contextItem" : [ { - "key" : "axContextItem0_0", - "contextType" : { - "key" : { - "name" : "StringType", - "version" : "0.0.1" - }, - "javaType" : "org.onap.policy.apex.core.contextmodel.concepts.TestContextItem000" - }, - "isWritable" : true, - "valueString" : "" - }, { - "key" : "axContextItem0_1", - "contextType" : { - "key" : { - "name" : "MapType", - "version" : "0.0.1" - }, - "javaType" : "org.onap.policy.apex.core.contextmodel.concepts.TestContextItem00A" - }, - "isWritable" : true, - "valueString" : "" - }, { - "key" : "axContextItem0_2", - "contextType" : { - "key" : { - "name" : "StringType", - "version" : "0.0.1" - }, - "javaType" : "org.onap.policy.apex.core.contextmodel.concepts.TestContextItem000" - }, - "isWritable" : true, - "valueString" : "" - }, { - "key" : "axContextItem0_3", - "contextType" : { - "key" : { - "name" : "MapType", - "version" : "0.0.1" - }, - "javaType" : "org.onap.policy.apex.core.contextmodel.concepts.TestContextItem00A" - }, - "isWritable" : true, - "valueString" : "" - } ] - } - } - }, { - "key" : "contextMap1", - "value" : { - "key" : { - "name" : "contextMap1", - "version" : "0.0.1" - }, - "scope" : "GLOBAL", - "mapType" : "SAMETYPE", - "templateContextItem" : { - "key" : "axTemplateContextItem", - "contextType" : { - "key" : { - "name" : "MapType", - "version" : "0.0.1" - }, - "javaType" : "org.onap.policy.apex.core.contextmodel.concepts.TestContextItem00A" - }, - "isWritable" : true - }, - "contextMap" : { - "contextItem" : [ ] - } - } - } ] - } - } - } -} \ No newline at end of file -- cgit 1.2.3-korg