<?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: Defining an SLO for KeyRequest response time in Automations</title>
    <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195383#M1165</link>
    <description>&lt;P&gt;At the moment I can't post an example with a KeyRequest because the ones I have are tests and are not called enough times to get a result out of them.&lt;/P&gt;&lt;P&gt;I've attached an example using a service response time and will add one with a service key request response time as soon as I get enough data for it &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Which error do you get when trying to get the SLO?&lt;/P&gt;&lt;P&gt;So far I saw that to use service.keyRequest.response.time you need to use type("SERVICE_METHOD") in the filter and then the name or the id of that key request.&lt;/P&gt;&lt;P&gt;Also you don't need to add the filter in the query of the SLO because you can do it in the filter section.&lt;/P&gt;</description>
    <pubDate>Thu, 29 Sep 2022 07:02:17 GMT</pubDate>
    <dc:creator>AlessandroG</dc:creator>
    <dc:date>2022-09-29T07:02:17Z</dc:date>
    <item>
      <title>Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/188467#M1158</link>
      <description>&lt;P&gt;I'm trying to create an SLO definition based on the number of fast and slow key requests, WITHOUT the need to create a custom metric for slow requests.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My idea was to define the SLO as:&lt;BR /&gt;&lt;EM&gt;100* (number of slow key requests / number of total requests)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;nothing special, really.&lt;BR /&gt;&lt;BR /&gt;I could create a custom service metric for the keyrequest that counts the number of requests that exceed a certain response time. But could this be done without that step, just with metric queries?&lt;BR /&gt;&lt;BR /&gt;I thought of this metric query:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;builtin:service.keyRequest.response.time
:filter(
  &amp;lt;filter for my key request goes here&amp;gt;
)
:avg
:partition(
 "time", 
 value(fast,lt(300000)),
 value(slow,otherwise)
)
:splitBy("time")
:filter(eq("time","fast"))
:count
:fold(sum)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The idea was to use &lt;EM&gt;partition&lt;/EM&gt; as a way to get the metric data points above and below a certain slow/fast level and then use &lt;EM&gt;count&lt;/EM&gt;&amp;nbsp;to calculate the number of datapoints and use those in the SLO definition: 100*(slow/fast).&lt;BR /&gt;(it wouldn't be perfectly accurate due to aggregation, but it should work for the SLO)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The metric partitioning works:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="r_weber_0-1655241602935.png" style="width: 400px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/6095i12C14198C3FC2401/image-size/medium?v=v2&amp;amp;px=400" role="button" title="r_weber_0-1655241602935.png" alt="r_weber_0-1655241602935.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;but I'm struggling in "counting" the number of metric points required for the SLO calculation.&lt;/P&gt;&lt;P&gt;Any ideas how this could be achieved?&lt;/P&gt;</description>
      <pubDate>Tue, 14 Jun 2022 21:25:45 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/188467#M1158</guid>
      <dc:creator>r_weber</dc:creator>
      <dc:date>2022-06-14T21:25:45Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/188474#M1159</link>
      <description>&lt;P&gt;Thankyou&amp;nbsp;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/35901"&gt;@r_weber&lt;/a&gt;&amp;nbsp; for this post, I dont have any solution yet but due to your post came across these below blogs which helped me to understand the SLO integration much better &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.dynatrace.com/support/help/how-to-use-dynatrace/cloud-automation/service-level-objectives/slo-definition-configuration-examples" target="_blank"&gt;Example configuration of service-level objective definitions | Dynatrace Docs&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.dynatrace.com/news/blog/slos-at-scale/" target="_blank"&gt;SLOs at Scale: Tips and Tricks | Dynatrace news&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.dynatrace.com/news/blog/7-steps-to-identify-and-implement-effective-slos/" target="_blank"&gt;7 steps to identify and implement effective SLOs | Dynatrace news&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 15 Jun 2022 05:52:36 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/188474#M1159</guid>
      <dc:creator>techean</dc:creator>
      <dc:date>2022-06-15T05:52:36Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/194974#M1160</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/35901"&gt;@r_weber&lt;/a&gt;&amp;nbsp;and thank you because your post pointed me in the right direction.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was struggling too because even with partitioning, if I divided by the count of all the response times I always got 100%, this because with aggregation every dot is considered 1 event.&lt;/P&gt;&lt;P&gt;By using partition and fold(sum) like you did we get the number of occurrences of each partition in the selected time frame, then by using fold(sum) on all the events we get the number of total events in the same timeframe and then we can calculate how many time it was good in a % way.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I did it like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;(
    builtin:service.keyRequest.response.time
    :filter(
        &amp;lt;filter for my key request goes here&amp;gt;
    )
    :avg
    :partition(
        "time", 
        value(fast,lt(300000)),
        value(slow,otherwise)
    )
    :splitBy("time")
    :filter(eq("time","fast"))
    :count
    :fold(sum)

    /

    builtin:service.keyRequest.response.time
    :filter(
        &amp;lt;filter for my key request goes here&amp;gt;
    )
    :avg
    :splitBy()
    :count
    :fold(sum)
) * 100&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope this is helpful &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Alessandro&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Sep 2022 06:54:32 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/194974#M1160</guid>
      <dc:creator>AlessandroG</dc:creator>
      <dc:date>2022-09-23T06:54:32Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195280#M1161</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.dynatrace.com/t5/user/viewprofilepage/user-id/55291"&gt;@AlessandroG&lt;/a&gt;&amp;nbsp;, did you manage to set SLO with your query? as I can see this is working in Data Explorer however I couldn't make it work in SLO.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2022 02:01:34 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195280#M1161</guid>
      <dc:creator>Ragu</dc:creator>
      <dc:date>2022-09-28T02:01:34Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195281#M1162</link>
      <description>&lt;P&gt;Would&amp;nbsp; be great if you could help us show an example how did you achieve in SLO wizard &lt;span class="lia-unicode-emoji" title=":folded_hands:"&gt;🙏&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2022 02:05:19 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195281#M1162</guid>
      <dc:creator>Ragu</dc:creator>
      <dc:date>2022-09-28T02:05:19Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195354#M1163</link>
      <description>&lt;P&gt;Using avg+partition has no reason in this case, since you can simple filter aggregations like this:&lt;/P&gt;&lt;PRE&gt;(&lt;SPAN&gt;100&lt;/SPAN&gt;)*(builtin:apps.web.&lt;SPAN&gt;action&lt;/SPAN&gt;.visuallyComplete.load.browser:filter(series(percentile(&lt;SPAN&gt;75&lt;/SPAN&gt;),lt(&lt;SPAN&gt;10000&lt;/SPAN&gt;))):splitBy():&lt;SPAN&gt;count&lt;/SPAN&gt;)/&lt;BR /&gt;(builtin:apps.web.&lt;SPAN&gt;action&lt;/SPAN&gt;.visuallyComplete.load.browser:splitBy():&lt;SPAN&gt;count&lt;/SPAN&gt;)&lt;/PRE&gt;&lt;P&gt;It doesn't solve initial problem - filter by criteria without aggregation.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2022 16:05:03 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195354#M1163</guid>
      <dc:creator>Viachaslau</dc:creator>
      <dc:date>2022-09-28T16:05:03Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195381#M1164</link>
      <description>&lt;P&gt;It doesn't works for the key request response time, because that metric aggregates the values for a "time slot" which is customisable in the data explorer but not in the SLO creation.&lt;/P&gt;&lt;P&gt;This time slot is set on automatic and can go from 1 minute (for small timeframes) to days in the larger timeframe.&lt;/P&gt;&lt;P&gt;By just counting the number of occurrences of the response time below a threshold you will get, for each time slot, 1 or 0.&lt;/P&gt;&lt;P&gt;OP got it right using fold(sum), because you need to find how many times you were below (good values) in the timeframe.&lt;/P&gt;</description>
      <pubDate>Thu, 29 Sep 2022 06:44:09 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195381#M1164</guid>
      <dc:creator>AlessandroG</dc:creator>
      <dc:date>2022-09-29T06:44:09Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195383#M1165</link>
      <description>&lt;P&gt;At the moment I can't post an example with a KeyRequest because the ones I have are tests and are not called enough times to get a result out of them.&lt;/P&gt;&lt;P&gt;I've attached an example using a service response time and will add one with a service key request response time as soon as I get enough data for it &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Which error do you get when trying to get the SLO?&lt;/P&gt;&lt;P&gt;So far I saw that to use service.keyRequest.response.time you need to use type("SERVICE_METHOD") in the filter and then the name or the id of that key request.&lt;/P&gt;&lt;P&gt;Also you don't need to add the filter in the query of the SLO because you can do it in the filter section.&lt;/P&gt;</description>
      <pubDate>Thu, 29 Sep 2022 07:02:17 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195383#M1165</guid>
      <dc:creator>AlessandroG</dc:creator>
      <dc:date>2022-09-29T07:02:17Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195384#M1166</link>
      <description>&lt;P&gt;I forgot to add that I don't know if there is a way to tell the SLO to don't use aggregated data for the response time but if there is I wasn't able to found it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 29 Sep 2022 07:05:26 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195384#M1166</guid>
      <dc:creator>AlessandroG</dc:creator>
      <dc:date>2022-09-29T07:05:26Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195404#M1167</link>
      <description>&lt;P&gt;This the main problem for me - because I don't want to have sum of avg count, but sum of count and filter it...&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;look like partition is also not helpful since we are using auto or avg for aggregation before filter.&lt;/P&gt;</description>
      <pubDate>Thu, 29 Sep 2022 09:32:23 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195404#M1167</guid>
      <dc:creator>Viachaslau</dc:creator>
      <dc:date>2022-09-29T09:32:23Z</dc:date>
    </item>
    <item>
      <title>Re: Defining an SLO for KeyRequest response time</title>
      <link>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195421#M1168</link>
      <description>&lt;P&gt;Ok, now I understood what are you saying. I missed the part, in the original question, where he says "without using a&amp;nbsp;&lt;SPAN&gt;custom service metric".&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;To my best knowledge it doesn't seems possible, we can get a SLO out of the standard metric but it is limited to the aggregation of all the requests in the auto resolution for that timeframe but not a fine grain number based on all the requests.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 29 Sep 2022 10:46:02 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Automations/Defining-an-SLO-for-KeyRequest-response-time/m-p/195421#M1168</guid>
      <dc:creator>AlessandroG</dc:creator>
      <dc:date>2022-09-29T10:46:02Z</dc:date>
    </item>
  </channel>
</rss>

