From 64b1d076e9081637833c4af6d4c3f296d8121c0a Mon Sep 17 00:00:00 2001 From: Wojciech Sliwka Date: Thu, 27 Sep 2018 13:54:22 +0200 Subject: Fix service instantiation error Fix error during service instantiation (unknown field during call to SO) Fix endpoit used durign creating vf module instance Add separate endpoint for scale out Issue-ID: VID-317 Change-Id: I34c25ae9d1ee1afe71ac340ef71c2572686bee2b Signed-off-by: Wojciech Sliwka --- .../main/java/org/onap/vid/mso/MsoBusinessLogicImpl.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'vid-app-common/src/main/java/org/onap/vid/mso/MsoBusinessLogicImpl.java') diff --git a/vid-app-common/src/main/java/org/onap/vid/mso/MsoBusinessLogicImpl.java b/vid-app-common/src/main/java/org/onap/vid/mso/MsoBusinessLogicImpl.java index 00db464a..d4ca8651 100644 --- a/vid-app-common/src/main/java/org/onap/vid/mso/MsoBusinessLogicImpl.java +++ b/vid-app-common/src/main/java/org/onap/vid/mso/MsoBusinessLogicImpl.java @@ -174,6 +174,19 @@ public class MsoBusinessLogicImpl implements MsoBusinessLogic { return msoClientInterface.createVfModuleInstance(requestDetails, vf_module_endpoint); } + @Override + public MsoResponseWrapper scaleOutVfModuleInstance(RequestDetails requestDetails, String serviceInstanceId, String vnfInstanceId) { + String methodName = "scaleOutVfModuleInstance"; + logger.debug(EELFLoggerDelegate.debugLogger, dateFormat.format(new Date()) + "<== " + methodName + START); + + String endpoint; + endpoint = validateEndpointPath(MsoProperties.MSO_REST_API_VF_MODULE_SCALE_OUT); + + String partial_endpoint = endpoint.replaceFirst(SVC_INSTANCE_ID, serviceInstanceId); + String vf_module_endpoint = partial_endpoint.replaceFirst(VNF_INSTANCE_ID, vnfInstanceId); + + return msoClientInterface.createVfModuleInstance(requestDetails, vf_module_endpoint); + } @Override public MsoResponseWrapper createConfigurationInstance(org.onap.vid.mso.rest.RequestDetailsWrapper requestDetailsWrapper, String serviceInstanceId) { String methodName = "createConfigurationInstance"; -- cgit 1.2.3-korg