
/*
The integration developer needs to create the method processData
This method takes Message object of package com.sap.gateway.ip.core.customdev.util
which includes helper methods useful for the content developer:
The methods available are:
public java.lang.Object getBody()
public void setBody(java.lang.Object exchangeBody)
public java.util.Map<java.lang.String,java.lang.Object> getHeaders()
public void setHeaders(java.util.Map<java.lang.String,java.lang.Object> exchangeHeaders)
public void setHeader(java.lang.String name, java.lang.Object value)
public java.util.Map<java.lang.String,java.lang.Object> getProperties()
public void setProperties(java.util.Map<java.lang.String,java.lang.Object> exchangeProperties)
public void setProperty(java.lang.String name, java.lang.Object value)
*/
import com.sap.gateway.ip.core.customdev.util.Message;
import java.util.HashMap;
def Message processData(Message message) {
//Body
def body = message.getBody();
def map = message.getHeaders();
//Get initialized cached entity form Header
String sExceptionMessage = map.get("ExceptionMessage");
String sExceptionTrace = map.get("ExceptionTrace");
String sParentMPLId = map.get("ParentMPLId");
String siFlowName = map.get("iFlowName");
String CPITenantURL; // = System.getenv("HC_APPLICATION_URL");
String UrlPart1 = System.getenv("HC_APPLICATION");
String UrlPart2 = System.getenv("HC_HOST");
String UrlPart3 = '{"messageGuid":"';
String UrlPart4 = '"}';
UrlPart1 = UrlPart1.replaceAll("iflmap","");
if(UrlPart1 != null || UrlPart2 != null || UrlPart3 != null || sParentMPLId != null || UrlPart4 != null){
CPITenantURL = "https://" + UrlPart1 + "-tmn.hci." + UrlPart2 + "/itspaces/shell/monitoring/MessageDetails/" + UrlPart3 + sParentMPLId + UrlPart4;
}
https://<hostname:port>/itspaces/shell/monitoring/MessageDetails/{"messageGuid":"<mplGUID>"}
if(CPITenantURL != null){
message.setProperty("EPTenantURL", CPITenantURL);
}
if(sExceptionMessage != null){
message.setProperty("EPExceptionMessage", sExceptionMessage);
}
if(sExceptionTrace != null){
message.setProperty("EPExceptionTrace", sExceptionTrace);
}
if(sParentMPLId != null){
message.setProperty("EPParentMPLId", sParentMPLId);
}
if(siFlowName != null){
message.setProperty("EPiFlowName", siFlowName);
}
return message;
}
Dear IT Admins,
An internal error occurred in iflow ${property.EPiFlowName}. For error details check MPL ID ${property.EPParentMPLId} in message monitoring or use the URL ${property.EPTenantURL}
Time: ${date:now:yyyy-MM-dd hh:mm:ss a}
Find below exception details for quick reference.
${property.EPExceptionMessage}
Regards,
Cloud Platform Service
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
16 | |
14 | |
13 | |
11 | |
11 | |
11 | |
10 | |
8 | |
7 | |
6 |