Skip to content

Commit a60cc80

Browse files
committed
Made monitoring links in alert mails tenant aware
1 parent ee6a851 commit a60cc80

File tree

8 files changed

+14
-13
lines changed

8 files changed

+14
-13
lines changed

Diff for: IFlow/Source/META-INF/MANIFEST.MF

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ SAP-RuntimeProfile: iflmap
33
Bundle-SymbolicName: Webbrowser_to_CPI_SystemMonitor_RealcoreDashboard
44
; singleton:=true
55
Bundle-Name: Webbrowser_to_CPI_SystemMonitor_RealcoreDashboard
6-
Bundle-Version: 1.0.28
6+
Bundle-Version: 1.0.31
77
Bundle-ManifestVersion: 2
88
SAP-ArtifactTrait:
99
SAP-NodeType: IFLMAP

Diff for: IFlow/Source/src/main/resources/scenarioflows/integrationflow/Webbrowser_to_CPI_SystemMonitor_Realcore.iflw

+8-8
Original file line numberDiff line numberDiff line change
@@ -4149,7 +4149,7 @@
41494149
<value>ctype::FlowstepVariant/cname::GatewayRoute/version::1.0.0</value>
41504150
</ifl:property>
41514151
</bpmn2:extensionElements>
4152-
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193480_1570536908275" xsi:type="bpmn2:tFormalExpression">${header.SAP_DatastoreEntryFound} != 'false'</bpmn2:conditionExpression>
4152+
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193480_1570594550480" xsi:type="bpmn2:tFormalExpression">${header.SAP_DatastoreEntryFound} != 'false'</bpmn2:conditionExpression>
41534153
</bpmn2:sequenceFlow>
41544154
<bpmn2:sequenceFlow id="SequenceFlow_193478" name="no" sourceRef="ExclusiveGateway_193477" targetRef="ServiceTask_193432">
41554155
<bpmn2:extensionElements>
@@ -4182,7 +4182,7 @@
41824182
<value>ctype::FlowstepVariant/cname::GatewayRoute/version::1.0.0</value>
41834183
</ifl:property>
41844184
</bpmn2:extensionElements>
4185-
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193484_1570536908275" xsi:type="bpmn2:tFormalExpression">${property.mplQuery.get('endDate').toString().endsWith('59:59.999')} = 'true'</bpmn2:conditionExpression>
4185+
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193484_1570594550481" xsi:type="bpmn2:tFormalExpression">${property.mplQuery.get('endDate').toString().endsWith('59:59.999')} = 'true'</bpmn2:conditionExpression>
41864186
</bpmn2:sequenceFlow>
41874187
<bpmn2:sequenceFlow id="SequenceFlow_193486" name="no" sourceRef="ExclusiveGateway_193483" targetRef="CallActivity_193457">
41884188
<bpmn2:extensionElements>
@@ -4836,7 +4836,7 @@
48364836
</ifl:property>
48374837
<ifl:property>
48384838
<key>propertyTable</key>
4839-
<value>&lt;row&gt;&lt;cell id='Action'&gt;Create&lt;/cell&gt;&lt;cell id='Type'&gt;expression&lt;/cell&gt;&lt;cell id='Value'&gt;${body}&lt;/cell&gt;&lt;cell id='Default'&gt;&lt;/cell&gt;&lt;cell id='Name'&gt;cacheAlertCertResponse&lt;/cell&gt;&lt;cell id='Datatype'&gt;java.lang.String&lt;/cell&gt;&lt;/row&gt;</value>
4839+
<value>&lt;row&gt;&lt;cell id='Action'&gt;Create&lt;/cell&gt;&lt;cell id='Type'&gt;constant&lt;/cell&gt;&lt;cell id='Value'&gt;{{SAP_CPI_HOST}}&lt;/cell&gt;&lt;cell id='Default'&gt;&lt;/cell&gt;&lt;cell id='Name'&gt;tenantHostname&lt;/cell&gt;&lt;cell id='Datatype'&gt;&lt;/cell&gt;&lt;/row&gt;&lt;row&gt;&lt;cell id='Action'&gt;Create&lt;/cell&gt;&lt;cell id='Type'&gt;expression&lt;/cell&gt;&lt;cell id='Value'&gt;${body}&lt;/cell&gt;&lt;cell id='Default'&gt;&lt;/cell&gt;&lt;cell id='Name'&gt;cacheAlertCertResponse&lt;/cell&gt;&lt;cell id='Datatype'&gt;java.lang.String&lt;/cell&gt;&lt;/row&gt;</value>
48404840
</ifl:property>
48414841
<ifl:property>
48424842
<key>headerTable</key>
@@ -5091,7 +5091,7 @@
50915091
<value>ctype::FlowstepVariant/cname::GatewayRoute/version::1.0.0</value>
50925092
</ifl:property>
50935093
</bpmn2:extensionElements>
5094-
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193621_1570536908277" xsi:type="bpmn2:tFormalExpression">${property.numAlertMails} &gt; '0'</bpmn2:conditionExpression>
5094+
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193621_1570594550485" xsi:type="bpmn2:tFormalExpression">${property.numAlertMails} &gt; '0'</bpmn2:conditionExpression>
50955095
</bpmn2:sequenceFlow>
50965096
<bpmn2:sequenceFlow id="SequenceFlow_193660" name="yes" sourceRef="ExclusiveGateway_193659" targetRef="CallActivity_193634">
50975097
<bpmn2:extensionElements>
@@ -5108,7 +5108,7 @@
51085108
<value>ctype::FlowstepVariant/cname::GatewayRoute/version::1.0.0</value>
51095109
</ifl:property>
51105110
</bpmn2:extensionElements>
5111-
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193660_1570536908277" xsi:type="bpmn2:tFormalExpression">${property.numAlertRules} &gt; '0'</bpmn2:conditionExpression>
5111+
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193660_1570594550486" xsi:type="bpmn2:tFormalExpression">${property.numAlertRules} &gt; '0'</bpmn2:conditionExpression>
51125112
</bpmn2:sequenceFlow>
51135113
<bpmn2:sequenceFlow id="SequenceFlow_193662" name="no" sourceRef="ExclusiveGateway_193659" targetRef="CallActivity_193668">
51145114
<bpmn2:extensionElements>
@@ -5605,7 +5605,7 @@
56055605
<value>ctype::FlowstepVariant/cname::GatewayRoute/version::1.0.0</value>
56065606
</ifl:property>
56075607
</bpmn2:extensionElements>
5608-
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193718_1570536908278" xsi:type="bpmn2:tFormalExpression">${header.CamelHttpMethod} = 'POST'</bpmn2:conditionExpression>
5608+
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193718_1570594550489" xsi:type="bpmn2:tFormalExpression">${header.CamelHttpMethod} = 'POST'</bpmn2:conditionExpression>
56095609
</bpmn2:sequenceFlow>
56105610
<bpmn2:sequenceFlow id="SequenceFlow_193711" name="GET" sourceRef="ExclusiveGateway_193710" targetRef="CallActivity_193696">
56115611
<bpmn2:extensionElements>
@@ -5622,7 +5622,7 @@
56225622
<value>ctype::FlowstepVariant/cname::GatewayRoute/version::1.0.0</value>
56235623
</ifl:property>
56245624
</bpmn2:extensionElements>
5625-
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193711_1570536908278" xsi:type="bpmn2:tFormalExpression">${header.CamelHttpMethod} = 'GET'</bpmn2:conditionExpression>
5625+
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193711_1570594550489" xsi:type="bpmn2:tFormalExpression">${header.CamelHttpMethod} = 'GET'</bpmn2:conditionExpression>
56265626
</bpmn2:sequenceFlow>
56275627
<bpmn2:sequenceFlow id="SequenceFlow_193705" sourceRef="CallActivity_193703" targetRef="EndEvent_193694"/>
56285628
<bpmn2:sequenceFlow id="SequenceFlow_193716" sourceRef="CallActivity_193714" targetRef="EndEvent_193713"/>
@@ -5898,7 +5898,7 @@
58985898
<value>ctype::FlowstepVariant/cname::GatewayRoute/version::1.0.0</value>
58995899
</ifl:property>
59005900
</bpmn2:extensionElements>
5901-
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193658_1570536908286" xsi:type="bpmn2:tFormalExpression">${header.SAP_DatastoreEntryFound} != 'false'</bpmn2:conditionExpression>
5901+
<bpmn2:conditionExpression id="FormalExpression_SequenceFlow_193658_1570594550493" xsi:type="bpmn2:tFormalExpression">${header.SAP_DatastoreEntryFound} != 'false'</bpmn2:conditionExpression>
59025902
</bpmn2:sequenceFlow>
59035903
<bpmn2:sequenceFlow id="SequenceFlow_193657" sourceRef="CallActivity_193583" targetRef="CallActivity_193684"/>
59045904
<bpmn2:sequenceFlow id="SequenceFlow_193728" sourceRef="CallActivity_193727" targetRef="CallActivity_193684"/>

Diff for: IFlow/Source/src/main/resources/script/alertCalculateAlerts.groovy

+2-1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ def Message processData(Message message) {
2727
//only process active rules
2828
if (rule.active){
2929
if (rule.ruletype.equals("message")){
30+
def tenantHostname = message.getProperty("tenantHostname")
3031
//Check all messages for matches
3132
def matchingMsgs = []
3233
new JsonSlurper().parseText(message.getProperty("cacheAlertMplResponse")).d.results.each { msg ->
@@ -39,7 +40,7 @@ def Message processData(Message message) {
3940
if (matchingMsgs.size() > 0) {
4041
def mailText = "Dear operator(s),<br/><br/>during the alert check for message between ${message.getProperty("alertLastRunBeginDate")}(UTC) and ${message.getProperty("alertLastRunDateNew")}(UTC) there was a problem found in the interface \"${rule.artifact_id}\".<br/><br/><u>The matching alert rule is:</u> ${rule.name}<br/><u>The user alert text is:</u> ${rule.alert_receiver_body}<br/><br/><u>The following ${matchingMsgs.size()} messages are affected:</u><br/><ul>"
4142
matchingMsgs.each { msg ->
42-
mailText += "<li><a href=\"https://p0401-tmn.hci.eu1.hana.ondemand.com/itspaces/shell/monitoring/Messages/%7B%22artifact%22:%22${rule.artifact_id}%22%7D\">${msg.id}</a> (Iflow-ID: ${msg.name})</li>"
43+
mailText += "<li><a href=\"https://${tenantHostname}/itspaces/shell/monitoring/Messages/%7B%22artifact%22:%22${msg.name}%22%7D\">${msg.id}</a> (Iflow-ID: ${msg.name})</li>"
4344
}
4445
mailText += "</ul>"
4546
rule.put("mailtext",mailText)

Diff for: IFlow/Source/src/main/resources/script/deliverStaticContent.groovy

+1-1
Large diffs are not rendered by default.

Diff for: Webfrontend/dist/index.html

0 Bytes
Binary file not shown.

Diff for: Webfrontend/dist/index_base64.txt

+1-1
Large diffs are not rendered by default.

Diff for: Webfrontend/dist/staticContent.groovy

0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)