From ada55be1b59899e461dc5177782e381f89cbc407 Mon Sep 17 00:00:00 2001 From: Pamela Dragosh Date: Fri, 5 Apr 2019 21:07:07 -0400 Subject: Remove drools PDP dependency Removing working memory and use of PolicyEngine from drools in these classes. Cleaned up some unused imports and checkstyle. Issue-ID: POLICY-1264 Change-Id: Id059da9689a721b0eafc6b310adcbdad43574ce7 Signed-off-by: Pamela Dragosh --- .../controlloop/actor/so/SoActorServiceProvider.java | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'models-interactions/model-actors/actor.so/src/main') diff --git a/models-interactions/model-actors/actor.so/src/main/java/org/onap/policy/controlloop/actor/so/SoActorServiceProvider.java b/models-interactions/model-actors/actor.so/src/main/java/org/onap/policy/controlloop/actor/so/SoActorServiceProvider.java index eef6e7c12..2a14bb19a 100644 --- a/models-interactions/model-actors/actor.so/src/main/java/org/onap/policy/controlloop/actor/so/SoActorServiceProvider.java +++ b/models-interactions/model-actors/actor.so/src/main/java/org/onap/policy/controlloop/actor/so/SoActorServiceProvider.java @@ -28,7 +28,6 @@ import java.lang.reflect.Type; import java.util.Collections; import java.util.List; import java.util.Map; -import org.drools.core.WorkingMemory; import org.onap.policy.aai.AaiNqExtraProperty; import org.onap.policy.aai.AaiNqInventoryResponseItem; import org.onap.policy.aai.AaiNqResponseWrapper; @@ -374,12 +373,16 @@ public class SoActorServiceProvider implements Actor { * in the asyncSORestCall. * * @param requestId the request Id - * @param wm the working memory + * @param callback callback method * @param request the request + * @param url SO REST URL + * @param user username + * @param password password */ - public static void sendRequest(String requestId, WorkingMemory wm, Object request) { - SoManager soManager = new SoManager(); - soManager.asyncSoRestCall(requestId, wm, lastServiceItemServiceInstanceId, lastVNFItemVnfId, + public static void sendRequest(String requestId, SoManager.SoCallback callback, Object request, + String url, String user, String password) { + SoManager soManager = new SoManager(url, user, password); + soManager.asyncSoRestCall(requestId, callback, lastServiceItemServiceInstanceId, lastVNFItemVnfId, lastVfModuleItemVfModuleInstanceId, (SoRequest) request); } @@ -406,7 +409,7 @@ public class SoActorServiceProvider implements Actor { private void buildRequestParameters(Policy policy, SoRequestDetails request) { // assume null until proven otherwise request.setRequestParameters(null); - + if (policy.getPayload() == null) { return; } @@ -428,7 +431,7 @@ public class SoActorServiceProvider implements Actor { private void buildConfigurationParameters(Policy policy, SoRequestDetails request) { // assume null until proven otherwise request.setConfigurationParameters(null); - + if (policy.getPayload() == null) { return; } -- cgit 1.2.3-korg