From 00b77b9ed6de5779212fecd30b71ebb615f89c3c Mon Sep 17 00:00:00 2001 From: mmis Date: Fri, 14 Sep 2018 09:00:25 +0100 Subject: Aligned decoder with forwarder for opt. policies Changed decoder for optimization policies to generate instance of OptimizationPolicy (instead of PdpxPolicy) as expected by the forwarder. Without this change there is a mismatch between the decoder and the forwarder. Added parameters for configuring the static elements of the optimization policies and setting of these elements. Issue-ID: POLICY-927 Change-Id: Ib91a905dc89eed13622fb88e4dd19b3cb9f62c75 Signed-off-by: mmis --- .../src/main/resources/etc/defaultConfig.json | 62 ++++++++++++++-------- 1 file changed, 40 insertions(+), 22 deletions(-) (limited to 'packages/policy-distribution-tarball') diff --git a/packages/policy-distribution-tarball/src/main/resources/etc/defaultConfig.json b/packages/policy-distribution-tarball/src/main/resources/etc/defaultConfig.json index 4a0013c2..01aefb24 100644 --- a/packages/policy-distribution-tarball/src/main/resources/etc/defaultConfig.json +++ b/packages/policy-distribution-tarball/src/main/resources/etc/defaultConfig.json @@ -10,15 +10,35 @@ "SDCReceptionHandler":{ "receptionHandlerType":"SDC", "receptionHandlerClassName":"org.onap.policy.distribution.reception.handling.sdc.SdcReceptionHandler", - "pssdConfiguration":{ - "asdcAddress": "localhost", + "receptionHandlerConfigurationName":"sdcConfiguration", + "pluginHandlerParameters":{ + "policyDecoders":{ + "CsarDecoder":{ + "decoderType":"CsarDecoder", + "decoderClassName":"org.onap.policy.distribution.reception.decoding.pdpx.PolicyDecoderCsarPdpx", + "decoderConfigurationName": "csarToOptimizationPolicyConfiguration" + } + }, + "policyForwarders":{ + "PAPEngineForwarder":{ + "forwarderType":"PAPEngine", + "forwarderClassName":"org.onap.policy.distribution.forwarding.xacml.pdp.XacmlPdpPolicyForwarder", + "forwarderConfigurationName": "xacmlPdpConfiguration" + } + } + } + } + }, + "receptionHandlerConfigurationParameters":{ + "sdcConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.reception.handling.sdc.SdcReceptionHandlerConfigurationParameterGroup", + "parameters":{ + "asdcAddress": "sdc-be.onap:8443", "messageBusAddress": [ - "a.com", - "b.com", - "c.com" + "message-router.onap" ], - "user": "tbdsdc-1480", - "password": "tbdsdc-1480", + "user": "sdc-1480", + "password": "sdc-1480", "pollingInterval":20, "pollingTimeout":30, "consumerId": "policy-id", @@ -33,21 +53,19 @@ "activeserverTlsAuth": false, "isFilterinEmptyResources": true, "isUseHttpsWithDmaap": false - }, - "pluginHandlerParameters":{ - "policyDecoders":{ - "TOSCADecoder":{ - "decoderType":"ToscaDecoder", - "decoderClassName":"org.onap.policy.distribution.reception.decoding.pdpx.PolicyDecoderToscaPdpx" - } - }, - "policyForwarders":{ - "PAPEngineForwarder":{ - "forwarderType":"PAPEngine", - "forwarderClassName":"org.onap.policy.distribution.forwarding.xacml.pdp.XacmlPdpPolicyForwarder", - "forwarderConfigurationName": "xacmlPdpConfiguration" - } - } + } + } + }, + "policyDecoderConfigurationParameters":{ + "csarToOptimizationPolicyConfiguration":{ + "parameterClassName":"org.onap.policy.distribution.reception.decoding.pdpx.PolicyDecoderCsarPdpxConfigurationParameterGroup", + "parameters":{ + "policyNamePrefix": "oofCasablanca", + "onapName": "OOF", + "version": "1.0", + "priority": "3", + "riskType": "Test", + "riskLevel": "2" } } }, -- cgit 1.2.3-korg