<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Custom Alert Not Firing When Using Code-based Metric Query in Alerting</title>
    <link>https://community.dynatrace.com/t5/Alerting/Custom-Alert-Not-Firing-When-Using-Code-based-Metric-Query/m-p/189660#M3075</link>
    <description>&lt;P&gt;The problem was that the custom alert wasn't related to the management zone condition that I had configured in my alerting profile.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I ended up removing the management zone condition from the alerting profile, instead relying on a different condition on the alerting profile; matching on the name of the custom alert. Once I did this, the alert starting sending notifications as expected.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I still don't fully understand which conditions cause a custom alert to be associated with a management zone (such that it is 'respected' by an alerting profile that has a management zone condition set). My best guess is that you must have a management zone entity filter applied in the custom alert configuration. I still don't understand how this is possible when the custom alert uses a code-based metric expression (as you seem to lose the ability to set a management zone entity filter this way).&lt;/P&gt;</description>
    <pubDate>Thu, 30 Jun 2022 20:41:06 GMT</pubDate>
    <dc:creator>swin12</dc:creator>
    <dc:date>2022-06-30T20:41:06Z</dc:date>
    <item>
      <title>Custom Alert Not Firing When Using Code-based Metric Query</title>
      <link>https://community.dynatrace.com/t5/Alerting/Custom-Alert-Not-Firing-When-Using-Code-based-Metric-Query/m-p/189635#M3073</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to configure custom alerts for a service's processing time. These alerts are based on a calculated service metric I created that allows me to filter request data by certain dimension; request attributes.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have configured this alarm end-to-end and gotten an alert to successfully fire under the condition I configure the alert using the 'build' option (filtering by only a single dimension value):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="swin12_1-1656607461563.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/6367iFB749EAE5537310E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="swin12_1-1656607461563.png" alt="swin12_1-1656607461563.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="swin12_2-1656607540101.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/6368i2F26F0EB2AB0CB06/image-size/medium?v=v2&amp;amp;px=400" role="button" title="swin12_2-1656607540101.png" alt="swin12_2-1656607540101.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I try to create a very similar alert using the 'code' option (because I need to filter on multiple values for the dimension, which doesn't seem possible using the 'build' option), I get a preview that indicates alerts should fire, but they never actually fire:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="swin12_0-1656607450089.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/6366i29F181D49AFC1593/image-size/medium?v=v2&amp;amp;px=400" role="button" title="swin12_0-1656607450089.png" alt="swin12_0-1656607450089.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="swin12_3-1656607858215.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/6369iC18AA8AEA71C721D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="swin12_3-1656607858215.png" alt="swin12_3-1656607858215.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The settings for the two alarms are identical, in that:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;They have identical static threshold settings&lt;/LI&gt;&lt;LI&gt;They have identical severity settings (Slowdown)&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Where they differ is:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;I used the 'build' option for one and the 'code' option for the other.&lt;/LI&gt;&lt;LI&gt;For the alert that uses the 'build' option, I am able to set entity scopes for the alert (such as management zone).&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="swin12_4-1656608492855.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/6370iD905749F69A780AF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="swin12_4-1656608492855.png" alt="swin12_4-1656608492855.png" /&gt;&lt;/span&gt;&lt;/LI&gt;&lt;LI&gt;For the alert that uses the 'code' option, I am unable to set these entity scopes (i.e. I can't select management zone from the dropdown).&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="swin12_5-1656608530513.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/6371iBDB2FB105E43E102/image-size/medium?v=v2&amp;amp;px=400" role="button" title="swin12_5-1656608530513.png" alt="swin12_5-1656608530513.png" /&gt;&lt;/span&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My leading theory is that the issue lies with the fact that the code-based alert does not have a management zone entity set (it doesn't seem to let me set one). As a result, the alert doesn't match the management zone for my alerting profile, and therefore I don't get an alert.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How would I associate a code-based alert with a specific management zone, such that it is picked up by the alerting profile when the alarm fires? Is there something I can add to the metric query?&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2022 17:25:22 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Alerting/Custom-Alert-Not-Firing-When-Using-Code-based-Metric-Query/m-p/189635#M3073</guid>
      <dc:creator>swin12</dc:creator>
      <dc:date>2022-06-30T17:25:22Z</dc:date>
    </item>
    <item>
      <title>Re: Custom Alert Not Firing When Using Code-based Metric Query</title>
      <link>https://community.dynatrace.com/t5/Alerting/Custom-Alert-Not-Firing-When-Using-Code-based-Metric-Query/m-p/189660#M3075</link>
      <description>&lt;P&gt;The problem was that the custom alert wasn't related to the management zone condition that I had configured in my alerting profile.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I ended up removing the management zone condition from the alerting profile, instead relying on a different condition on the alerting profile; matching on the name of the custom alert. Once I did this, the alert starting sending notifications as expected.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I still don't fully understand which conditions cause a custom alert to be associated with a management zone (such that it is 'respected' by an alerting profile that has a management zone condition set). My best guess is that you must have a management zone entity filter applied in the custom alert configuration. I still don't understand how this is possible when the custom alert uses a code-based metric expression (as you seem to lose the ability to set a management zone entity filter this way).&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2022 20:41:06 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Alerting/Custom-Alert-Not-Firing-When-Using-Code-based-Metric-Query/m-p/189660#M3075</guid>
      <dc:creator>swin12</dc:creator>
      <dc:date>2022-06-30T20:41:06Z</dc:date>
    </item>
  </channel>
</rss>

