diff options
Diffstat (limited to 'adapters')
-rw-r--r-- | adapters/mso-vfc-adapter/WebContent/WEB-INF/web.xml | 2 | ||||
-rw-r--r-- | adapters/mso-vnf-adapter/src/main/java/org/openecomp/mso/adapters/vnf/BpelRestClient.java | 16 |
2 files changed, 2 insertions, 16 deletions
diff --git a/adapters/mso-vfc-adapter/WebContent/WEB-INF/web.xml b/adapters/mso-vfc-adapter/WebContent/WEB-INF/web.xml index cd97471b5b..66ea46fcc9 100644 --- a/adapters/mso-vfc-adapter/WebContent/WEB-INF/web.xml +++ b/adapters/mso-vfc-adapter/WebContent/WEB-INF/web.xml @@ -16,7 +16,7 @@ </context-param> <context-param> <param-name>mso.configuration</param-name> - <param-value>MSO_PROP_NETWORK_ADAPTER=mso.vfc.properties,MSO_PROP_TOPOLOGY=topology.properties</param-value> + <param-value>MSO_PROP_VFC_ADAPTER=mso.vfc.properties,MSO_PROP_TOPOLOGY=topology.properties</param-value> </context-param> <context-param> <param-name>mso.cloud_config.configuration</param-name> diff --git a/adapters/mso-vnf-adapter/src/main/java/org/openecomp/mso/adapters/vnf/BpelRestClient.java b/adapters/mso-vnf-adapter/src/main/java/org/openecomp/mso/adapters/vnf/BpelRestClient.java index a8189925fb..749b9f9fc3 100644 --- a/adapters/mso-vnf-adapter/src/main/java/org/openecomp/mso/adapters/vnf/BpelRestClient.java +++ b/adapters/mso-vnf-adapter/src/main/java/org/openecomp/mso/adapters/vnf/BpelRestClient.java @@ -256,13 +256,9 @@ public class BpelRestClient { .build(); post.setConfig(requestConfig); - //Client 4.3+ - CloseableHttpClient client = null; - //Client 4.3+ //Execute & GetResponse - try { - client = HttpClients.createDefault(); + try(CloseableHttpClient client = HttpClients.createDefault()) { CloseableHttpResponse response = client.execute(post); if (response != null) { lastResponseCode = response.getStatusLine().getStatusCode(); @@ -277,16 +273,6 @@ public class BpelRestClient { LOGGER.error (MessageEnum.RA_SEND_VNF_NOTIF_ERR, error, "Camunda", "", MsoLogger.ErrorCode.BusinessProcesssError, "Exception - Error sending Bpel notification", e); lastResponseCode = 900; lastResponse = ""; - } finally { - try { - client.close(); - } catch (IOException e) { - // ignore - LOGGER.debug("IOException: ", e); - } catch (NullPointerException e) { - //ignore - LOGGER.debug("NullPointerException: ", e); - } } LOGGER.debug("Response code from BPEL server: "+lastResponseCode); LOGGER.debug("Response body is: "+lastResponse); |