return true;\r
}\r
for (int i = 0; i < strLen; i++) {\r
- if (Character.isWhitespace(cs.charAt(i)) == false) {\r
+ if (!Character.isWhitespace(cs.charAt(i))) {\r
return false;\r
}\r
}\r
execution.setVariable(prefix+'sdncResponseSuccess', false)\r
taskProcessor.utils.log("DEBUG", "Response" + ' = ' + (response == null ? "" : System.lineSeparator()) + response, isDebugLogEnabled)\r
\r
- if (successIndicator == true){\r
+ if (successIndicator){\r
if (response == null || response.trim().equals("")) {\r
taskProcessor.utils.log("DEBUG", response + ' is empty');\r
exceptionUtil.buildAndThrowWorkflowException(execution, 500, "SDNCAdapter Workflow Response is Empty")\r
execution.setVariable(prefix+'sdncResponseSuccess', false)\r
\r
taskProcessor.utils.log("sdncAdapter Success Indicator is: " + success, isDebugLogEnabled)\r
- if (success == true) {\r
+ if (success) {\r
\r
// we need to look inside the request data for error\r
def String callbackRequestData = taskProcessor.utils.getNodeXml(response, 'RequestData', false)\r
\r
\r
\r
-}
+}\r
try {
String serviceInstanceName = execution.getVariable("serviceInstanceName")
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("INFO","Error getting Service-instance from AAI", + serviceInstanceName, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
else
{
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
- if(foundInAAI == true){
+ if(foundInAAI){
utils.log("INFO","Found Service-instance in AAI", isDebugEnabled)
msg = "ServiceInstance already exists in AAI:" + serviceInstanceName
utils.log("INFO", msg, isDebugEnabled)
try {
String serviceInstanceId = execution.getVariable("serviceInstanceId")
boolean succInAAI = execution.getVariable("GENPS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("INFO","Error putting Service-instance in AAI", + serviceInstanceId, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
try {
String serviceInstanceName = execution.getVariable("serviceInstanceName")
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("INFO","Error getting Service-instance from AAI in postProcessAAIGET2", + serviceInstanceName, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
else
{
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
- if(foundInAAI == true){
+ if(foundInAAI){
String aaiService = execution.getVariable("GENGS_service")
if (!isBlank(aaiService) && (utils.nodeExists(aaiService, "service-instance-name"))) {
execution.setVariable("serviceInstanceName", utils.getNodeText1(aaiService, "service-instance-name"))
String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
boolean rollbackAAI = execution.getVariable("rollbackAAI")\r
boolean rollbackSDNC = execution.getVariable("rollbackSDNC")\r
- if (rollbackAAI == true || rollbackSDNC == true)\r
+ if (rollbackAAI || rollbackSDNC)\r
{\r
execution.setVariable("rolledBack", true)\r
}\r
- if (rollbackAAI == true)\r
+ if (rollbackAAI)\r
{\r
boolean succInAAI = execution.getVariable("GENDS_SuccessIndicator")\r
- if(succInAAI != true){\r
+ if(!succInAAI){\r
execution.setVariable("rolledBack", false) //both sdnc and aai must be successful to declare rollback Succesful\r
execution.setVariable("rollbackError", "Error deleting service-instance in AAI for rollback")\r
utils.log("DEBUG","Error deleting service-instance in AAI for rollback", + serviceInstanceId, isDebugEnabled)\r
try {\r
String serviceInstanceName = execution.getVariable("serviceInstanceName")\r
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")\r
- if(succInAAI != true){\r
+ if(!succInAAI){\r
utils.log("INFO","Error getting Service-instance from AAI", + serviceInstanceName, isDebugEnabled)\r
WorkflowException workflowException = execution.getVariable("WorkflowException")\r
utils.logAudit("workflowException: " + workflowException)\r
else\r
{\r
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")\r
- if(foundInAAI == true){\r
+ if(foundInAAI){\r
utils.log("INFO","Found Service-instance in AAI", isDebugEnabled)\r
msg = "ServiceInstance already exists in AAI:" + serviceInstanceName\r
utils.log("INFO", msg, isDebugEnabled)\r
try {\r
String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
boolean succInAAI = execution.getVariable("GENPS_SuccessIndicator")\r
- if(succInAAI != true){\r
+ if(!succInAAI){\r
utils.log("INFO","Error putting Service-instance in AAI", + serviceInstanceId, isDebugEnabled)\r
WorkflowException workflowException = execution.getVariable("WorkflowException")\r
utils.logAudit("workflowException: " + workflowException)\r
try {\r
String serviceInstanceName = execution.getVariable("serviceInstanceName")\r
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")\r
- if(succInAAI != true){\r
+ if(!succInAAI){\r
utils.log("INFO","Error getting Service-instance from AAI in postProcessAAIGET2", + serviceInstanceName, isDebugEnabled)\r
WorkflowException workflowException = execution.getVariable("WorkflowException")\r
utils.logAudit("workflowException: " + workflowException)\r
else\r
{\r
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")\r
- if(foundInAAI == true){\r
+ if(foundInAAI){\r
String aaiService = execution.getVariable("GENGS_service")\r
if (!isBlank(aaiService) && (utils.nodeExists(aaiService, "service-instance-name"))) {\r
execution.setVariable("serviceInstanceName", utils.getNodeText1(aaiService, "service-instance-name"))\r
try {
String serviceInstanceName = execution.getVariable("serviceInstanceName")
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("DEBUG","Error getting Service-instance from AAI", + serviceInstanceName, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
else
{
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
- if(foundInAAI == true){
+ if(foundInAAI){
utils.log("DEBUG","Found Service-instance in AAI", isDebugEnabled)
msg = "ServiceInstance already exists in AAI:" + serviceInstanceName
utils.log("DEBUG", msg, isDebugEnabled)
try {
String serviceInstanceId = execution.getVariable("serviceInstanceId")
boolean succInAAI = execution.getVariable("GENPS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("DEBUG","Error putting Service-instance in AAI", + serviceInstanceId, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
try {
String serviceInstanceName = execution.getVariable("serviceInstanceName")
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("DEBUG","Error getting Service-instance from AAI in postProcessAAIGET2", + serviceInstanceName, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
else
{
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
- if(foundInAAI == true){
+ if(foundInAAI){
String aaiService = execution.getVariable("GENGS_service")
if (!isBlank(aaiService) && (utils.nodeExists(aaiService, "service-instance-name"))) {
execution.setVariable("serviceInstanceName", utils.getNodeText1(aaiService, "service-instance-name"))
String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
boolean rollbackAAI = execution.getVariable("rollbackAAI")\r
boolean rollbackSDNC = execution.getVariable("rollbackSDNC")\r
- if (rollbackAAI == true || rollbackSDNC == true)\r
+ if (rollbackAAI || rollbackSDNC)\r
{\r
execution.setVariable("rolledBack", true)\r
}\r
- if (rollbackAAI == true)\r
+ if (rollbackAAI)\r
{\r
boolean succInAAI = execution.getVariable("GENDS_SuccessIndicator")\r
- if(succInAAI != true){\r
+ if(!succInAAI){\r
execution.setVariable("rolledBack", false) //both sdnc and aai must be successful to declare rollback Succesful\r
execution.setVariable("rollbackError", "Error deleting service-instance in AAI for rollback")\r
utils.log("DEBUG","Error deleting service-instance in AAI for rollback", + serviceInstanceId, isDebugEnabled)\r
utils.log("ERROR", "Exception Occured Processing postProcessCreateVfModuleRollback. Exception is:\n" + e, isDebugLogEnabled)\r
exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during postProcessCreateVfModuleRollback Method:\n" + e.getMessage())\r
}\r
- if (rolledBack == false) {\r
+ if (!rolledBack) {\r
logDebug("Failure on DoCreateVfModuleRollback", isDebugLogEnabled)\r
utils.log("ERROR", "Unsuccessful rollback of DoCreateVfModule")\r
exceptionUtil.buildAndThrowWorkflowException(execution, 1002, "Error Occurred during rollback of DoCreateVfModule")\r
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
String serviceType = ""
- if(foundInAAI == true){
+ if(foundInAAI){
utils.log("INFO","Found Service-instance in AAI", isDebugEnabled)
String siData = execution.getVariable("GENGS_service")
}
}else{
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("INFO","Error getting Service-instance from AAI", + serviceInstanceId, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
try {
String serviceInstanceId = execution.getVariable("serviceInstanceId")
boolean succInAAI = execution.getVariable("GENDS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
msg = "Error deleting Service-instance in AAI" + serviceInstanceId
utils.log("INFO", msg, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
String serviceType = ""\r
\r
\r
- if(foundInAAI == true){\r
+ if(foundInAAI){\r
utils.log("INFO","Found Service-instance in AAI", isDebugEnabled)\r
\r
String siData = execution.getVariable("GENGS_service")\r
\r
}else{\r
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")\r
- if(succInAAI != true){\r
+ if(!succInAAI){\r
utils.log("INFO","Error getting Service-instance from AAI", + serviceInstanceId, isDebugEnabled)\r
WorkflowException workflowException = execution.getVariable("WorkflowException")\r
utils.logAudit("workflowException: " + workflowException)\r
try {\r
String serviceInstanceId = execution.getVariable("serviceInstanceId")\r
boolean succInAAI = execution.getVariable("GENDS_SuccessIndicator")\r
- if(succInAAI != true){\r
+ if(!succInAAI){\r
msg = "Error deleting Service-instance in AAI" + serviceInstanceId\r
utils.log("INFO", msg, isDebugEnabled)\r
WorkflowException workflowException = execution.getVariable("WorkflowException")\r
NetworkUtils networkUtils = new NetworkUtils()
isVfRelationshipExist = networkUtils.isVfRelationshipExist(aaiResponseAsString)
execution.setVariable(Prefix + "isVfRelationshipExist", isVfRelationshipExist)
- if (isVfRelationshipExist == true) {
+ if (isVfRelationshipExist) {
String relationshipMessage = "AAI Query Success Response but 'vf-module' relationship exist, not allowed to delete: network Id: " + networkId
exceptionUtil.buildWorkflowException(execution, 2500, relationshipMessage)
boolean foundInAAI = execution.getVariable("GENGS_FoundIndicator")
String serviceType = ""
- if(foundInAAI == true){
+ if(foundInAAI){
utils.log("DEBUG","Found Service-instance in AAI", isDebugEnabled)
//Extract GlobalSubscriberId
}
}else{
boolean succInAAI = execution.getVariable("GENGS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
utils.log("DEBUG","Error getting Service-instance from AAI", + serviceInstanceId, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
utils.logAudit("workflowException: " + workflowException)
try {
String serviceInstanceId = execution.getVariable("serviceInstanceId")
boolean succInAAI = execution.getVariable("GENDS_SuccessIndicator")
- if(succInAAI != true){
+ if(!succInAAI){
msg = "Error deleting Service-instance in AAI" + serviceInstanceId
utils.log("DEBUG", msg, isDebugEnabled)
WorkflowException workflowException = execution.getVariable("WorkflowException")
try {
execution.setVariable("rollbackData", null)
boolean skipRollback = execution.getVariable("skipRollback")
- if (skipRollback != true)
+ if (!skipRollback)
{
execution.setVariable("rolledBack", true)
utils.log("DEBUG","rolledBack", isDebugEnabled)
try {
execution.setVariable("rollbackData", null)
boolean skipRollback = execution.getVariable("skipRollback")
- if (skipRollback != true)
+ if (!skipRollback)
{
execution.setVariable("rolledBack", true)
utils.log("DEBUG","rolledBack", isDebugEnabled)