<?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: SLO using a calculated service metric with no data result in an error - any workaround? in Automations</title>
    <link>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253682#M1753</link>
    <description>&lt;P&gt;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/42071"&gt;@rsmsdk&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/73123"&gt;@fpereira22&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Because of having a calculated, or just because of having different metrics, it must be applying a different aggregation from the intended...&lt;BR /&gt;Apply a Fold transformation. For instance:&lt;BR /&gt;&lt;BR /&gt;(&lt;BR /&gt;(builtin:service.requestCount.total:value:splitBy() - calc:service....:value:splitBy():default(0,always)):fold(value) / builtin:service.requestCount.total:value:splitBy():fold(value)&lt;BR /&gt;)&lt;BR /&gt;* 100&lt;/P&gt;</description>
    <pubDate>Tue, 20 Aug 2024 09:51:52 GMT</pubDate>
    <dc:creator>paulo_calaxa</dc:creator>
    <dc:date>2024-08-20T09:51:52Z</dc:date>
    <item>
      <title>SLO using a calculated service metric with no data result in an error - any workaround?</title>
      <link>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253315#M1749</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;
&lt;P&gt;I have a calculated service metric that track a key request count with a processing time of &amp;gt;10 seconds.&lt;/P&gt;
&lt;P&gt;I want to use this metric in a SLO to track how many of the total key request are within a timeout limit set in an application.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The problem occur when no requests have a processing time of &amp;gt; 10 seconds, and the metrics return "no data" which in return causes my SLO to fail instead of showcasing 100%.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Obviously the metric expression can not use null or zero in the definition, so I was wondering if there is another way to get the result om looking for?&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Metric expression:&lt;/STRONG&gt;&lt;BR /&gt;((calc:service.&lt;U&gt;total-request.count&lt;/U&gt;":splitBy()-&lt;U&gt;calc:service.custom-metric-bad-request-count&lt;/U&gt;":splitBy())/&lt;U&gt;calc:service.total-request-count&lt;/U&gt;":splitBy())*100&lt;/P&gt;
&lt;P&gt;When&amp;nbsp;&lt;U&gt;calc:service.custom-metric-bad-request-count&lt;/U&gt; have data, the metric express produces the SLO output I'm looking for, but when&amp;nbsp;&lt;U&gt;calc:service.custom-metric-bad-request-count&lt;/U&gt; dont have any data the SLO fail.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Thank you in advance.&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Aug 2024 10:48:33 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253315#M1749</guid>
      <dc:creator>rsmsdk</dc:creator>
      <dc:date>2024-08-22T10:48:33Z</dc:date>
    </item>
    <item>
      <title>Re: SLO using a calculated service metric with no data result in an error - any workaround?</title>
      <link>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253321#M1750</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/42071"&gt;@rsmsdk&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Have you tired the default transformation? (your expression above):default(100)&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.dynatrace.com/docs/dynatrace-api/environment-api/metric-v2/metric-expressions#cover-data-gaps-with-the-default-transformation" target="_blank"&gt;Metrics API - Metric expressions - Dynatrace Docs&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.dynatrace.com/docs/observe-and-explore/metrics/upgrade/metric-selector-conversion" target="_blank"&gt;Metric selector conversion guide - Dynatrace Docs&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I hope it helps.&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Mizső&lt;/P&gt;</description>
      <pubDate>Tue, 13 Aug 2024 15:39:01 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253321#M1750</guid>
      <dc:creator>Mizső</dc:creator>
      <dc:date>2024-08-13T15:39:01Z</dc:date>
    </item>
    <item>
      <title>Re: SLO using a calculated service metric with no data result in an error - any workaround?</title>
      <link>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253363#M1751</link>
      <description>&lt;P&gt;Thank you so much for taking the time to provide an answer.&lt;/P&gt;&lt;P&gt;I tried adding :&lt;SPAN&gt;defualt(0) to my calculated metric that lack data, but it does not work. I can then add :defualt(0,always) like suggested in &lt;A href="https://community.dynatrace.com/t5/Dashboarding/Replace-quot-no-data-quot-with-quot-0-quot-in-a-dashboard/m-p/208824/highlight/true#M2811" target="_self"&gt;this thread&lt;/A&gt; on the same topic, but the math does not add up.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I can isolate the individual metrics, and get a confirmation on the data, but when I set up the expression for calculation, the result does not match.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I can setup&amp;nbsp;&lt;U&gt;calc:service.custom-metric-bad-request-count&lt;/U&gt;":splitBy():default(0, always) by itself and display zero, but when I try to setup the expression the output is wrong.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;An example with values could be ((&lt;FONT color="#00FF00"&gt;200&lt;/FONT&gt;-&lt;FONT color="#FF0000"&gt;0&lt;/FONT&gt;)/(&lt;FONT color="#00FF00"&gt;200&lt;/FONT&gt;))*100&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;FONT color="#FF0000"&gt;Red&lt;/FONT&gt; = Calculated metric with no data and the addition of&amp;nbsp;:default(0, always)&lt;BR /&gt;&lt;FONT color="#00FF00"&gt;Green&lt;/FONT&gt; = Total count&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Obivously this should output 100, but it does not. It output a number that is nowhere close.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 14 Aug 2024 07:48:40 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253363#M1751</guid>
      <dc:creator>rsmsdk</dc:creator>
      <dc:date>2024-08-14T07:48:40Z</dc:date>
    </item>
    <item>
      <title>Re: SLO using a calculated service metric with no data result in an error - any workaround?</title>
      <link>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253637#M1752</link>
      <description>&lt;P&gt;I have the same problem, I need to bring a calculated metric of no response (another item that is not included) and when I try to remove the SLO, it breaks the entire expression.&lt;/P&gt;&lt;P&gt;Send some examples of my problem:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="fpereira22_0-1724093585910.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/21861i9564CDD4F9A19DD9/image-size/medium?v=v2&amp;amp;px=400" role="button" title="fpereira22_0-1724093585910.png" alt="fpereira22_0-1724093585910.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="fpereira22_1-1724093628045.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/21862iB1C4E5126B6F4F6A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="fpereira22_1-1724093628045.png" alt="fpereira22_1-1724093628045.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="fpereira22_3-1724093750691.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/21864iD564B38750F166F2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="fpereira22_3-1724093750691.png" alt="fpereira22_3-1724093750691.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="fpereira22_2-1724093653923.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/21863i35B09BD47E8140AD/image-size/medium?v=v2&amp;amp;px=400" role="button" title="fpereira22_2-1724093653923.png" alt="fpereira22_2-1724093653923.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;calc:service.statuscode_noresponse_loyalty:splitby() = 4 counts&lt;/P&gt;&lt;P&gt;calc:service.statuscode_noresponse_loyalty:splitby():default(0,always) = 4 counts&lt;/P&gt;&lt;P&gt;(1)+(calc:service.statuscode_noresponse_loyalty:splitby()) = 5 counts&lt;BR /&gt;(1)+(calc:service.statuscode_noresponse_loyalty:splitby():default(0,always)) = 124 counts?????&lt;/P&gt;&lt;P&gt;Does anyone have any suggestions?&lt;/P&gt;</description>
      <pubDate>Mon, 19 Aug 2024 18:56:16 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253637#M1752</guid>
      <dc:creator>fpereira22</dc:creator>
      <dc:date>2024-08-19T18:56:16Z</dc:date>
    </item>
    <item>
      <title>Re: SLO using a calculated service metric with no data result in an error - any workaround?</title>
      <link>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253682#M1753</link>
      <description>&lt;P&gt;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/42071"&gt;@rsmsdk&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/73123"&gt;@fpereira22&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Because of having a calculated, or just because of having different metrics, it must be applying a different aggregation from the intended...&lt;BR /&gt;Apply a Fold transformation. For instance:&lt;BR /&gt;&lt;BR /&gt;(&lt;BR /&gt;(builtin:service.requestCount.total:value:splitBy() - calc:service....:value:splitBy():default(0,always)):fold(value) / builtin:service.requestCount.total:value:splitBy():fold(value)&lt;BR /&gt;)&lt;BR /&gt;* 100&lt;/P&gt;</description>
      <pubDate>Tue, 20 Aug 2024 09:51:52 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/SLO-using-a-calculated-service-metric-with-no-data-result-in-an/m-p/253682#M1753</guid>
      <dc:creator>paulo_calaxa</dc:creator>
      <dc:date>2024-08-20T09:51:52Z</dc:date>
    </item>
  </channel>
</rss>

