aboutsummaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCommonBPMN
diff options
context:
space:
mode:
Diffstat (limited to 'bpmn/MSOCommonBPMN')
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/adapter/vnf/MsoRequest.java7
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/BpmnRestClient.java2
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoUtils.java28
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/appc/ApplicationControllerSupport.java2
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/dmaap/rest/DMaaPRestClient.java2
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/sdno/SDNOValidator.java4
-rw-r--r--bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/BPMNUtil.java2
-rw-r--r--bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/WorkflowTest.java2
-rw-r--r--bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/mock/FileUtil.java5
9 files changed, 13 insertions, 41 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/adapter/vnf/MsoRequest.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/adapter/vnf/MsoRequest.java
index 8a9cb955b0..eabd465934 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/adapter/vnf/MsoRequest.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/adapter/vnf/MsoRequest.java
@@ -105,11 +105,8 @@ public class MsoRequest {
@Override
public String toString() {
- StringBuilder request = new StringBuilder();
- request.append("<requestId>").append(requestId).append("</requestId>");
- request.append('\n');
- request.append("<serviceInstanceId>").append(serviceInstanceId).append("</serviceInstanceId>");
- return request.toString();
+ return "<requestId>" + requestId + "</requestId>" + '\n' + "<serviceInstanceId>" + serviceInstanceId
+ + "</serviceInstanceId>";
}
}
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/BpmnRestClient.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/BpmnRestClient.java
index 446de10ee2..e43af18ceb 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/BpmnRestClient.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/BpmnRestClient.java
@@ -129,7 +129,7 @@ public class BpmnRestClient {
if(encryptedCredentials != null) {
String userCredentials = getEncryptedPropValue(encryptedCredentials, DEFAULT_BPEL_AUTH, ENCRYPTION_KEY);
if(userCredentials != null) {
- post.addHeader("Authorization", "Basic " + new String(DatatypeConverter.printBase64Binary(userCredentials.getBytes())));
+ post.addHeader("Authorization", "Basic " + DatatypeConverter.printBase64Binary(userCredentials.getBytes()));
}
}
}
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoUtils.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoUtils.java
index 5972c76c41..846b87aba8 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoUtils.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/util/CryptoUtils.java
@@ -38,11 +38,10 @@ public class CryptoUtils {
public static final String AES = "AES";
/**
- * encrypt a value and generate a keyfile
+ * encrypt a value and generate a keyfile
* if the keyfile is not found then a new one is created
- * @throws GeneralSecurityException
- * @throws IOException
- */
+ * @throws GeneralSecurityException
+ * */
public static String encrypt(String value, String keyString) throws GeneralSecurityException
{
SecretKeySpec sks = getSecretKeySpec(keyString);
@@ -53,9 +52,8 @@ public class CryptoUtils {
}
/**
- * decrypt a value
+ * decrypt a value
* @throws GeneralSecurityException
- * @throws IOException
*/
public static String decrypt(String message, String keyString) throws GeneralSecurityException
{
@@ -96,23 +94,5 @@ public class CryptoUtils {
return b;
}
- /**
- * Not Used...
- *
- * Call Rttp utility jar to encrypt pwd
- * @param clearPassword
- * @return
- * @throws GeneralSecurityException
- * @throws Exception
- *
- public static String encryptRttpPwd(String clearPassword) throws GeneralSecurityException {
- try {
- return RttpBasicAuth.encrypt(clearPassword);
- } catch (Exception e) {
- // wrap generic exception
- throw new GeneralSecurityException(e);
- }
- }
- */
}
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/appc/ApplicationControllerSupport.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/appc/ApplicationControllerSupport.java
index 765bf61c49..f7db52b1c0 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/appc/ApplicationControllerSupport.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/appc/ApplicationControllerSupport.java
@@ -71,7 +71,7 @@ public class ApplicationControllerSupport {
}
/**
- * @param inputClass
+ * @param action
* @return
* @throws ClassNotFoundException
* @throws InstantiationException
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/dmaap/rest/DMaaPRestClient.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/dmaap/rest/DMaaPRestClient.java
index 124e2c3a28..f54eba406e 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/dmaap/rest/DMaaPRestClient.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/dmaap/rest/DMaaPRestClient.java
@@ -42,7 +42,7 @@ public class DMaaPRestClient extends RestClient {
@Override
protected void initializeHeaderMap(Map<String, String> headerMap) {
- headerMap.put("Authorization", "Basic " + Base64.getEncoder().encodeToString(new String(username + ":" + password).getBytes()));
+ headerMap.put("Authorization", "Basic " + Base64.getEncoder().encodeToString((username + ":" + password).getBytes()));
}
@Override
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/sdno/SDNOValidator.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/sdno/SDNOValidator.java
index c746c0d448..df30e43822 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/sdno/SDNOValidator.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/client/sdno/SDNOValidator.java
@@ -27,8 +27,8 @@ public interface SDNOValidator {
/**
* Issues a health diagnostic request for a given vnf to SDN-O
*
- * @param vnfName
- * @param uuid
+ * @param vnfId
+ * @param requestingUserId
* @throws IOException
* @throws Exception
*/
diff --git a/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/BPMNUtil.java b/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/BPMNUtil.java
index 9fcde31e4f..0bb5186a17 100644
--- a/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/BPMNUtil.java
+++ b/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/BPMNUtil.java
@@ -68,7 +68,7 @@ public class BPMNUtil {
}
@SuppressWarnings("unchecked")
- public static <T extends Object> T getRawVariable(ProcessEngineServices processEngineServices, String processDefinitionID, String name) {
+ public static <T> T getRawVariable(ProcessEngineServices processEngineServices, String processDefinitionID, String name) {
String pID = getProcessInstanceId(processEngineServices,
processDefinitionID);
assertProcessInstanceFinished(processEngineServices, pID);
diff --git a/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/WorkflowTest.java b/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/WorkflowTest.java
index b71f708797..6f0095fb02 100644
--- a/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/WorkflowTest.java
+++ b/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/common/WorkflowTest.java
@@ -1829,7 +1829,7 @@ public class WorkflowTest {
/**
* Constructor
* @param contentType the HTTP content type (optional)
- * @param type the callback message type (optional)
+ * @param messageType the callback message type (optional)
* @param content the content
*/
public CallbackData(String contentType, String messageType, String content) {
diff --git a/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/mock/FileUtil.java b/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/mock/FileUtil.java
index 2ebb44a644..38d0584d0d 100644
--- a/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/mock/FileUtil.java
+++ b/bpmn/MSOCommonBPMN/src/test/java/org/openecomp/mso/bpmn/mock/FileUtil.java
@@ -35,11 +35,6 @@ public class FileUtil {
private static final MsoLogger LOGGER = MsoLogger.getMsoLogger (MsoLogger.Catalog.RA);
- private FileUtil() {
- /**
- * Constructor.
- */
- }
/**
* Read the specified resource file and return the contents as a String.
*