diff options
Diffstat (limited to 'controlloop/common/model-impl/so')
-rw-r--r-- | controlloop/common/model-impl/so/pom.xml | 6 | ||||
-rw-r--r-- | controlloop/common/model-impl/so/src/main/java/org/onap/policy/so/SOManager.java | 12 |
2 files changed, 15 insertions, 3 deletions
diff --git a/controlloop/common/model-impl/so/pom.xml b/controlloop/common/model-impl/so/pom.xml index faeb12130..a18030eb7 100644 --- a/controlloop/common/model-impl/so/pom.xml +++ b/controlloop/common/model-impl/so/pom.xml @@ -53,5 +53,11 @@ <artifactId>rest</artifactId> <version>${project.version}</version> </dependency> + <dependency> + <groupId>org.onap.policy.drools-pdp</groupId> + <artifactId>policy-management</artifactId> + <version>${project.version}</version> + <scope>provided</scope> + </dependency> </dependencies> </project> diff --git a/controlloop/common/model-impl/so/src/main/java/org/onap/policy/so/SOManager.java b/controlloop/common/model-impl/so/src/main/java/org/onap/policy/so/SOManager.java index f967414c1..2f5ffdc3e 100644 --- a/controlloop/common/model-impl/so/src/main/java/org/onap/policy/so/SOManager.java +++ b/controlloop/common/model-impl/so/src/main/java/org/onap/policy/so/SOManager.java @@ -25,6 +25,7 @@ import java.util.HashMap; import java.util.Map; import org.onap.policy.so.util.Serialization; +import org.onap.policy.drools.system.PolicyEngine; import org.onap.policy.rest.RESTManager; import org.onap.policy.rest.RESTManager.Pair; import org.drools.core.WorkingMemory; @@ -134,9 +135,14 @@ public final class SOManager { @Override public void run() { - String serverRoot = "http://localhost:6667"; // TODO - String username = "username"; // TODO - String password = "password"; // TODO + + /* + * TODO: What if these are null? + */ + String serverRoot = PolicyEngine.manager.getEnvironmentProperty("so.url"); + String username = PolicyEngine.manager.getEnvironmentProperty("so.username"); + String password = PolicyEngine.manager.getEnvironmentProperty("so.password"); + String url = serverRoot + "/serviceInstances/v2/" + serviceInstanceId + "/vnfs/" + vnfInstanceId + "/vfModulesHTTPS/1.1"; String auth = username + ":" + password; |