Merge "Moved "" string literal on the left side."
diff --git a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/CatalogDbAdapterRest.java b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/CatalogDbAdapterRest.java
index aca8e9e..668f738 100644
--- a/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/CatalogDbAdapterRest.java
+++ b/adapters/mso-catalog-db-adapter/src/main/java/org/openecomp/mso/adapters/catalogdb/CatalogDbAdapterRest.java
@@ -142,19 +142,19 @@
 		List<VnfResourceCustomization> ret;
 
 		try (CatalogDatabase db = CatalogDatabase.getInstance()) {
-			if (vnfUuid != null && !vnfUuid.equals("")) {
+			if (vnfUuid != null && !"".equals(vnfUuid)) {
 				uuid = vnfUuid;
 				LOGGER.debug ("Query serviceVnfs getAllVnfsByVnfModelCustomizationUuid vnfModelCustomizationUuid: " + uuid);
 				ret = db.getAllVnfsByVnfModelCustomizationUuid(uuid);
 			}
-			else if (smUuid != null && !smUuid.equals("")) {
+			else if (smUuid != null && !"".equals(smUuid)) {
 				uuid = smUuid;
 				LOGGER.debug ("Query serviceVnfs getAllVnfsByServiceModelUuid serviceModelUuid: " + uuid);
 				ret = db.getAllVnfsByServiceModelUuid(uuid);
 			}
-			else if (smiUuid != null && !smiUuid.equals("")) {
+			else if (smiUuid != null && !"".equals(smiUuid)) {
 				uuid = smiUuid;
-				if (smVer != null && !smVer.equals("")) {
+				if (smVer != null && !"".equals(smVer)) {
 					LOGGER.debug ("Query serviceVnfs getAllNetworksByServiceModelInvariantUuid serviceModelInvariantUuid: " + uuid+ " serviceModelVersion: "+ smVer);
 					ret = db.getAllVnfsByServiceModelInvariantUuid(uuid, smVer);
 				}
@@ -163,8 +163,8 @@
 					ret = db.getAllVnfsByServiceModelInvariantUuid(uuid);
 				}
 			}
-			else if (smName != null && !smName.equals("")) {
-				if (smVer != null && !smVer.equals("")) {
+			else if (smName != null && !"".equals(smName)) {
+				if (smVer != null && !"".equals(smVer)) {
 					LOGGER.debug ("Query serviceVnfs getAllVnfsByServiceName serviceModelInvariantName: " + smName+ " serviceModelVersion: "+ smVer);
 					ret = db.getAllVnfsByServiceName(smName, smVer);
 				}
@@ -221,7 +221,7 @@
 		@QueryParam("serviceModelVersion") String smVer,
 		@QueryParam("networkModelVersion") String nmVer
 	) {
-		if (nModelName != null && !nModelName.equals("")) {
+		if (nModelName != null && !"".equals(nModelName)) {
 			nType = nModelName;
 		}
 		return serviceNetworksImpl (version, IS_ARRAY, nUuid, nType, smUuid, smiUuid, smVer);
@@ -234,24 +234,24 @@
 		List<NetworkResourceCustomization> ret;
 
 		try (CatalogDatabase db = CatalogDatabase.getInstance()) {
-			if (nUuid != null && !nUuid.equals("")) {
+			if (nUuid != null && !"".equals(nUuid)) {
 				uuid = nUuid;
 				LOGGER.debug ("Query serviceNetworks getAllNetworksByNetworkModelCustomizationUuid networkModelCustomizationUuid: " + uuid);
 				ret = db.getAllNetworksByNetworkModelCustomizationUuid(uuid);
 			}
-			else if (smUuid != null && !smUuid.equals("")) {
+			else if (smUuid != null && !"".equals(smUuid)) {
 				uuid = smUuid;
 				LOGGER.debug ("Query serviceNetworks getAllNetworksByServiceModelUuid serviceModelUuid: " + uuid);
 				ret = db.getAllNetworksByServiceModelUuid(uuid);
 			}
-			else if (nType != null && !nType.equals("")) {
+			else if (nType != null && !"".equals(nType)) {
 				uuid = nType;
 				LOGGER.debug ("Query serviceNetworks getAllNetworksByNetworkType serviceModelUuid: " + uuid);
 				ret = db.getAllNetworksByNetworkType(uuid);
 			}
-			else if (smiUuid != null && !smiUuid.equals("")) {
+			else if (smiUuid != null && !"".equals(smiUuid)) {
 				uuid = smiUuid;
-				if (smVer != null && !smVer.equals("")) {
+				if (smVer != null && !"".equals(smVer)) {
 					LOGGER.debug ("Query serviceNetworks getAllNetworksByServiceModelInvariantUuid serviceModelInvariantUuid: " + uuid+ " serviceModelVersion: "+ smVer);
 					ret = db.getAllNetworksByServiceModelInvariantUuid(uuid, smVer);
 				}
@@ -299,14 +299,14 @@
 		ServiceMacroHolder ret;
 
 		try (CatalogDatabase db = CatalogDatabase.getInstance()) {
-			if (smUuid != null && !smUuid.equals("")) {
+			if (smUuid != null && !"".equals(smUuid)) {
 				uuid = smUuid;
 				LOGGER.debug ("Query serviceMacroHolder getAllResourcesByServiceModelUuid serviceModelUuid: " + uuid);
 				ret = db.getAllResourcesByServiceModelUuid(uuid);
 			}
-			else if (smiUuid != null && !smiUuid.equals("")) {
+			else if (smiUuid != null && !"".equals(smiUuid)) {
 				uuid = smiUuid;
-				if (smVer != null && !smVer.equals("")) {
+				if (smVer != null && !"".equals(smVer)) {
 					LOGGER.debug ("Query serviceMacroHolder getAllResourcesByServiceModelInvariantUuid serviceModelInvariantUuid: " + uuid+ " serviceModelVersion: "+ smVer);
 					ret = db.getAllResourcesByServiceModelInvariantUuid(uuid, smVer);
 				}
@@ -370,14 +370,14 @@
 		List<AllottedResourceCustomization > ret;
 
 		try (CatalogDatabase db = CatalogDatabase.getInstance()) {
-			if (smUuid != null && !smUuid.equals("")) {
+			if (smUuid != null && !"".equals(smUuid)) {
 				uuid = smUuid;
 				LOGGER.debug ("Query AllottedResourceCustomization getAllAllottedResourcesByServiceModelUuid serviceModelUuid: " + uuid);
 				ret = db.getAllAllottedResourcesByServiceModelUuid(uuid);
 			}
-			else if (smiUuid != null && !smiUuid.equals("")) {
+			else if (smiUuid != null && !"".equals(smiUuid)) {
 				uuid = smiUuid;
-				if (smVer != null && !smVer.equals("")) {
+				if (smVer != null && !"".equals(smVer)) {
 					LOGGER.debug ("Query AllottedResourceCustomization getAllAllottedResourcesByServiceModelInvariantUuid serviceModelInvariantUuid: " + uuid+ " serviceModelVersion: "+ smVer);
 					ret = db.getAllAllottedResourcesByServiceModelInvariantUuid(uuid, smVer);
 				}
@@ -386,7 +386,7 @@
 					ret = db.getAllAllottedResourcesByServiceModelInvariantUuid(uuid);
 				}
 			}
-			else if (aUuid != null && !aUuid.equals("")) {
+			else if (aUuid != null && !"".equals(aUuid)) {
 				uuid = aUuid;
 				LOGGER.debug ("Query AllottedResourceCustomization getAllAllottedResourcesByArModelCustomizationUuid serviceModelUuid: " + uuid);
 				ret = db.getAllAllottedResourcesByArModelCustomizationUuid(uuid);
@@ -428,11 +428,11 @@
 		CatalogDatabase db = CatalogDatabase.getInstance();
 
 		try{
-			if(vfModuleModelName != null && !vfModuleModelName.equals("")){
+			if(vfModuleModelName != null && !"".equals(vfModuleModelName)){
 				LOGGER.debug ("Query vfModules by vfModuleModuleName: " + vfModuleModelName);
 				VfModuleCustomization vfModule = db.getVfModuleCustomizationByModelName(vfModuleModelName);
 				if(vfModule != null){
-					ret = new ArrayList<VfModuleCustomization>(1);
+					ret = new ArrayList<>(1);
 					ret.add(vfModule);
 				}
 			}else{
@@ -466,4 +466,4 @@
 		}
 	}
 
-}
\ No newline at end of file
+}
diff --git a/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/BPELRestClient.java b/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/BPELRestClient.java
index cd23991..ddeb359 100644
--- a/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/BPELRestClient.java
+++ b/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/BPELRestClient.java
@@ -47,7 +47,7 @@
                               String schemaVersion,
                               String serviceInstanceId,
                               String action) throws ClientProtocolException, IOException {
-        String encryptedCredentials = null;
+        String encryptedCredentials;
         HttpPost post = new HttpPost (url);
         msoLogger.debug ("BPEL url is: " + url);
         StringEntity input = new StringEntity (bpelReqXML);