diff --git a/BMW-Dynatrace-config/CD_VDLM_rtchandler/custom-service-java/template-2-1.json b/BMW-Dynatrace-config/CD_VDLM_rtchandler/custom-service-java/template-2-1.json index 0658d43e..9c3c9300 100644 --- a/BMW-Dynatrace-config/CD_VDLM_rtchandler/custom-service-java/template-2-1.json +++ b/BMW-Dynatrace-config/CD_VDLM_rtchandler/custom-service-java/template-2-1.json @@ -16,20 +16,19 @@ "argumentTypes": [], "methodName": "{{.methodName1}}", "returnType": "{{.returnType1}}" - }, + }] + }, + { + "annotations": [], + "className": "{{.className2}}", + "enabled": true, + "fileName": "", + "matcher": "EQUALS", + "methodRules": [ { - "annotations": [], - "className": "{{.className2}}", - "enabled": true, - "fileName": "", - "matcher": "EQUALS", - "methodRules": [ - { - "argumentTypes": [], - "methodName": "{{.methodName2}}", - "returnType": "{{.returnType2}}" - } - ] + "argumentTypes": [], + "methodName": "{{.methodName2}}", + "returnType": "{{.returnType2}}" } ] } diff --git a/BMW-Dynatrace-config/CD_VDLM_rtchandler/management-zone/default.json b/BMW-Dynatrace-config/CD_VDLM_rtchandler/management-zone/default.json index fc96de39..9cbec622 100644 --- a/BMW-Dynatrace-config/CD_VDLM_rtchandler/management-zone/default.json +++ b/BMW-Dynatrace-config/CD_VDLM_rtchandler/management-zone/default.json @@ -1,23 +1,120 @@ { - "dimensionalRules": [], - "name": "{{.name}}", - "entitySelectorBasedRules": [ + "dimensionalRules": [], + "name": "{{.name}}", + "rules": [ { - "enabled": true, - "entitySelector": "type(Service),tag({{.compassIDs}})" + "type": "SERVICE", + "enabled": true, + "propagationTypes": [], + "conditions": [ + { + "key": { + "attribute": "SERVICE_TAGS", + "type": "STATIC" + }, + "comparisonInfo": { + "type": "TAG", + "operator": "EQUALS", + "value": { + "context": "CONTEXTLESS", + "key": "compass-id", + "value": "{{.compassIDs}}" + }, + "negate": false + } + }, + { + "key": { + "attribute": "SERVICE_NAME", + "type": "STATIC" + }, + "comparisonInfo": { + "type": "STRING", + "operator": "CONTAINS", + "value": "PingResource", + "negate": true, + "caseSensitive": true + } + }, + { + "key": { + "attribute": "SERVICE_NAME", + "type": "STATIC" + }, + "comparisonInfo": { + "type": "STRING", + "operator": "CONTAINS", + "value": "HealthResource", + "negate": true, + "caseSensitive": true + } + }, + { + "key": { + "attribute": "SERVICE_NAME", + "type": "STATIC" + }, + "comparisonInfo": { + "type": "STRING", + "operator": "CONTAINS", + "value": "PrometheusResource", + "negate": true, + "caseSensitive": true + } + } + ] }, + { + "type": "PROCESS_GROUP", + "enabled": true, + "propagationTypes": [], + "conditions": [ + { + "key": { + "attribute": "PROCESS_GROUP_TAGS", + "type": "STATIC" + }, + "comparisonInfo": { + "type": "TAG", + "operator": "EQUALS", + "value": { + "context": "CONTEXTLESS", + "key": "compass-id", + "value": "{{.compassIDs}}" + }, + "negate": false + } + } + ] + }, + { + "type": "HOST", + "enabled": true, + "propagationTypes": [], + "conditions": [ + { + "key": { + "attribute": "HOST_TAGS", + "type": "STATIC" + }, + "comparisonInfo": { + "type": "TAG", + "operator": "EQUALS", + "value": { + "context": "CONTEXTLESS", + "key": "compass-id", + "value": "{{.compassIDs}}" + }, + "negate": false + } + } + ] + } + ], + "entitySelectorBasedRules": [ { "enabled": true, - "entitySelector": "type(SERVICE),databaseName.exists(),toRelationship.calls(type(SERVICE),tag({{.compassIDs}}))" - }, - { - "enabled": true, - "entitySelector": "type(PROCESS_GROUP_INSTANCE),tag({{.compassIDs}})" - }, - { - "enabled": true, - "entitySelector": "type(HOST),tag({{.compassIDs}})" - } - ], - "rules": [] + "entitySelector": "type(SERVICE),databaseName.exists(),toRelationship.calls(type(SERVICE),tag(compass-id:{{.compassIDs}}))" + } + ] } \ No newline at end of file