diff options
author | Pamela Dragosh <pdragosh@research.att.com> | 2018-11-01 00:43:14 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2018-11-01 00:43:14 +0000 |
commit | 4e5fc12d539c6f61657ad56f55774cfe5681ab21 (patch) | |
tree | 95c1b29581440f44e73199773102c6cc5668f03a /controlloop | |
parent | 805d51c6f884cfe7001cb6e010115bcabfaa4480 (diff) | |
parent | e757f3f7b596d6fb08293388c94aba2447f6011a (diff) |
Merge "Add /serviceInstances/ to SO URL for scale-out" into casablanca
Diffstat (limited to 'controlloop')
4 files changed, 6 insertions, 5 deletions
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 20b1ac57b..6557be45e 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 @@ -179,8 +179,8 @@ public final class SOManager { if (request.getOperationType() != null && request.getOperationType() .equals(SoOperationType.SCALE_OUT)) { - url = urlBase + "/serviceInstantiation/v7/" + serviceInstanceId + "/vnfs/" + vnfInstanceId - + "/vfModules/scaleOut"; + url = urlBase + "/serviceInstantiation/v7/serviceInstances/" + serviceInstanceId + "/vnfs/" + + vnfInstanceId + "/vfModules/scaleOut"; netLogger.info("[OUT|{}|{}|]{}{}", "SO", url, LINE_SEPARATOR, soJson); httpResponse = restManager.post(url, username, password, createSimpleHeaders(), MEDIA_TYPE, soJson); } else if (request.getOperationType() != null && request.getOperationType() diff --git a/controlloop/common/model-impl/so/src/test/java/org/onap/policy/so/TestSoDummyServer.java b/controlloop/common/model-impl/so/src/test/java/org/onap/policy/so/TestSoDummyServer.java index 0d719e50d..2a352b0bf 100644 --- a/controlloop/common/model-impl/so/src/test/java/org/onap/policy/so/TestSoDummyServer.java +++ b/controlloop/common/model-impl/so/src/test/java/org/onap/policy/so/TestSoDummyServer.java @@ -93,7 +93,7 @@ public class TestSoDummyServer { * @return http response */ @POST - @Path("/serviceInstantiation/v7/{serviceInstanceId}/vnfs/{vnfInstanceId}/vfModules/scaleOut") + @Path("/serviceInstantiation/v7/serviceInstances/{serviceInstanceId}/vnfs/{vnfInstanceId}/vfModules/scaleOut") public Response servicePostRequestVfModules(@PathParam("serviceInstanceId") final String serviceInstanceId, @PathParam("vnfInstanceId") final String vnfInstanceId, final String jsonString) { postMessagesReceived++; diff --git a/controlloop/common/simulators/src/main/java/org/onap/policy/simulators/SoSimulatorJaxRs.java b/controlloop/common/simulators/src/main/java/org/onap/policy/simulators/SoSimulatorJaxRs.java index 8bab8bba4..c99fc12bb 100644 --- a/controlloop/common/simulators/src/main/java/org/onap/policy/simulators/SoSimulatorJaxRs.java +++ b/controlloop/common/simulators/src/main/java/org/onap/policy/simulators/SoSimulatorJaxRs.java @@ -44,7 +44,7 @@ public class SoSimulatorJaxRs { * @return the response */ @POST - @Path("/v7/{serviceInstanceId}/vnfs/{vnfInstanceId}/vfModules/scaleOut") + @Path("/v7/serviceInstances/{serviceInstanceId}/vnfs/{vnfInstanceId}/vfModules/scaleOut") @Consumes(MediaType.APPLICATION_JSON) @Produces("application/json") public String soPostQuery(@PathParam("serviceInstanceId") final String serviceInstanceId, diff --git a/controlloop/common/simulators/src/test/java/org/onap/policy/simulators/SoSimulatorTest.java b/controlloop/common/simulators/src/test/java/org/onap/policy/simulators/SoSimulatorTest.java index 772dd7f2c..86f7b3e96 100644 --- a/controlloop/common/simulators/src/test/java/org/onap/policy/simulators/SoSimulatorTest.java +++ b/controlloop/common/simulators/src/test/java/org/onap/policy/simulators/SoSimulatorTest.java @@ -139,7 +139,8 @@ public class SoSimulatorTest { public void testResponse() { final String request = Serialization.gsonPretty.toJson(this.createTestRequest()); final Pair<Integer, String> httpDetails = new RESTManager().post( - "http://localhost:6667/serviceInstantiation/v7/12345/vnfs/12345/vfModules/scaleOut", "username", + "http://localhost:6667/serviceInstantiation/v7/serviceInstances/12345/vnfs/12345/vfModules/scaleOut", + "username", "password", new HashMap<>(), "application/json", request); assertNotNull(httpDetails); final SOResponse response = Serialization.gsonPretty.fromJson(httpDetails.second, SOResponse.class); |