03 Jun 2025
09:17 PM
- last edited on
04 Sep 2025
10:07 AM
by
Michal_Gebacki
Discovery and Coverage app has rules defined at the below url.
/ui/apps/dynatrace.classic.settings/ui/settings/app:dynatrace.discovery.coverage:discovery.findings.default.rules.schema
As a customer I want to add some custom rules for our environment however these are almost immediately deleted. The app states:
Discovery findings default rules. This schema is not subject to manual changes, except for Muted setting. Any changes (except muting the rule) will be overwritten by the Discovery & Coverage application defaults.
My particular use case here is we have "Required" tags i.e App Name and Environment for each Host/Pg/Service etc.
The following DQL would provide a coverage of hosts that are not compliant with having the appropriate tags.
fetch dt.entity.host, from:-15m
| fieldsAdd tags
| fieldsAdd app = matchesPhrase(tags, "app:")
| fieldsAdd host.id=id, compliant=(app == true)
As I cannot add a rule. I need another approach to signal that entities have been onboarded without the correct tagging metadata. I have this all in a notebook currently and am thinking of a metric event that alerts when the count is higher than zero, as a work around.