diff options
Diffstat (limited to 'models-interactions/model-actors/actor.vfc/src/main')
-rw-r--r-- | models-interactions/model-actors/actor.vfc/src/main/java/org/onap/policy/controlloop/actor/vfc/Restart.java | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/models-interactions/model-actors/actor.vfc/src/main/java/org/onap/policy/controlloop/actor/vfc/Restart.java b/models-interactions/model-actors/actor.vfc/src/main/java/org/onap/policy/controlloop/actor/vfc/Restart.java index 2c5cf8eda..e3df16d9b 100644 --- a/models-interactions/model-actors/actor.vfc/src/main/java/org/onap/policy/controlloop/actor/vfc/Restart.java +++ b/models-interactions/model-actors/actor.vfc/src/main/java/org/onap/policy/controlloop/actor/vfc/Restart.java @@ -20,6 +20,7 @@ package org.onap.policy.controlloop.actor.vfc; +import java.util.Map; import java.util.concurrent.CompletableFuture; import javax.ws.rs.client.Entity; import javax.ws.rs.core.MediaType; @@ -47,7 +48,10 @@ public class Restart extends VfcOperation { String path = getPath() + pair.getLeft(); String url = getClient().getBaseUrl() + path; - return handleResponse(outcome, url, callback -> getClient().post(callback, path, entity, null)); + Map<String, Object> headers = makeHeaders(); + headers.put("Accept", MediaType.APPLICATION_JSON); + + return handleResponse(outcome, url, callback -> getClient().post(callback, path, entity, headers)); } /** @@ -58,7 +62,7 @@ public class Restart extends VfcOperation { protected Pair<String, VfcRequest> makeRequest() { VfcRequest request = super.constructVfcRequest(); - String requestUrl = "/ns/" + request.getNsInstanceId() + "/heal"; + String requestUrl = "/" + request.getNsInstanceId() + "/heal"; return Pair.of(requestUrl, request); } } |