Make targetEntity a property
[policy/models.git] / models-interactions / model-actors / actor.aai / src / main / java / org / onap / policy / controlloop / actor / aai / AaiCustomQueryOperation.java
index 388959d..5480135 100644 (file)
@@ -40,6 +40,7 @@ import org.onap.policy.controlloop.actorserviceprovider.OperationProperties;
 import org.onap.policy.controlloop.actorserviceprovider.impl.HttpOperation;
 import org.onap.policy.controlloop.actorserviceprovider.parameters.ControlLoopOperationParams;
 import org.onap.policy.controlloop.actorserviceprovider.parameters.HttpConfig;
+import org.onap.policy.controlloop.policy.PolicyResult;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -186,6 +187,19 @@ public class AaiCustomQueryOperation extends HttpOperation<String> {
         return AaiUtil.makeHeaders(params);
     }
 
+    @Override
+    public OperationOutcome setOutcome(OperationOutcome outcome, PolicyResult result, Response rawResponse,
+                    String response) {
+
+        super.setOutcome(outcome, result, rawResponse, response);
+
+        if (response != null) {
+            outcome.setResponse(new AaiCqResponse(response));
+        }
+
+        return outcome;
+    }
+
     /**
      * Injects the response into the context.
      */