<?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: Set Query Method Checks Other Than 1 Minute in Extensions</title>
    <link>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186330#M2193</link>
    <description>&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;The query indeed works, only the logger somehow doesn't show up.&lt;/P&gt;</description>
    <pubDate>Thu, 12 May 2022 03:18:01 GMT</pubDate>
    <dc:creator>Ardhi</dc:creator>
    <dc:date>2022-05-12T03:18:01Z</dc:date>
    <item>
      <title>Set query method checks other than 1 minute</title>
      <link>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186247#M2189</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;Based on this &lt;A href="https://www.dynatrace.com/support/help/extend-dynatrace/extensions/activegate-extensions/write-your-first-activegate-plugin" target="_self"&gt;documentation&lt;/A&gt;, I found out the query method is checked every minute.&lt;/P&gt;
&lt;P&gt;But is there a way we can change this to arbitrary values like 1 hour or 1 day?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So far I did the checking function,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;    def query(self, **kwargs):
        logger.info(f"Config: {self.username} {self.config_folder}, {self.retention_days}, {self.device_type}")
        logger.info(f"{datetime.now()} ActiveGate Backup Plugin")
        if self.poll_count &amp;lt; self.polling_interval:
            self.poll_count += 1
            logger.info(f"... only polling every {self.polling_interval} minutes. Skipping this minute.")
        else:
            logger.info(f"your time has come: {datetime.now()}")
            self.poll_count = 1&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But without luck, not even every minute&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="Screen Shot 2022-05-11 at 10.15.22.png" style="width: 976px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/5640iCA78185678F21BDA/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screen Shot 2022-05-11 at 10.15.22.png" alt="Screen Shot 2022-05-11 at 10.15.22.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;the query only works when the "Update" button is pressed on the extension page.&lt;/P&gt;
&lt;P&gt;Is there any additional setting or a way around this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Ardhi&lt;/P&gt;</description>
      <pubDate>Wed, 17 May 2023 08:25:33 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186247#M2189</guid>
      <dc:creator>Ardhi</dc:creator>
      <dc:date>2023-05-17T08:25:33Z</dc:date>
    </item>
    <item>
      <title>Re: Set Query Method Checks Other Than 1 Minute</title>
      <link>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186251#M2190</link>
      <description>&lt;P&gt;You need to do that in your code. The query method gets executed every minute, however if the previous run did not finish, the extension engine won't trigger another query method call. If you need to execute it in a different interval, just implement a simple counter in your extension and immediately exit the query method.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 May 2022 06:17:33 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186251#M2190</guid>
      <dc:creator>Julius_Loman</dc:creator>
      <dc:date>2022-05-11T06:17:33Z</dc:date>
    </item>
    <item>
      <title>Re: Set Query Method Checks Other Than 1 Minute</title>
      <link>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186330#M2193</link>
      <description>&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;The query indeed works, only the logger somehow doesn't show up.&lt;/P&gt;</description>
      <pubDate>Thu, 12 May 2022 03:18:01 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186330#M2193</guid>
      <dc:creator>Ardhi</dc:creator>
      <dc:date>2022-05-12T03:18:01Z</dc:date>
    </item>
    <item>
      <title>Re: Set Query Method Checks Other Than 1 Minute</title>
      <link>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186642#M2203</link>
      <description>&lt;P&gt;The specific logs for your extensions will be under /var/lib/dynatrace/remotepluginmodule/log/remoteplugin/custom.remote.python.your_extension_name/&lt;/P&gt;</description>
      <pubDate>Tue, 17 May 2022 12:47:40 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186642#M2203</guid>
      <dc:creator>mark_bley</dc:creator>
      <dc:date>2022-05-17T12:47:40Z</dc:date>
    </item>
    <item>
      <title>Re: Set Query Method Checks Other Than 1 Minute</title>
      <link>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186704#M2204</link>
      <description>&lt;P&gt;I personally use an alternative method, based on the modulus of the current minute. So, if I want it to run every 5 minutes, I do a modulus 5...&lt;/P&gt;</description>
      <pubDate>Tue, 17 May 2022 20:17:15 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186704#M2204</guid>
      <dc:creator>AntonioSousa</dc:creator>
      <dc:date>2022-05-17T20:17:15Z</dc:date>
    </item>
    <item>
      <title>Re: Set Query Method Checks Other Than 1 Minute</title>
      <link>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186716#M2205</link>
      <description>&lt;P&gt;Thank you, yes was using modulus, and so far the result is good.&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="Screen Shot 2022-05-18 at 08.18.32.png" style="width: 270px;"&gt;&lt;img src="https://community.dynatrace.com/t5/image/serverpage/image-id/5753i9BA51E7B174A1744/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screen Shot 2022-05-18 at 08.18.32.png" alt="Screen Shot 2022-05-18 at 08.18.32.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 19 May 2022 12:53:24 GMT</pubDate>
      <guid>https://community.dynatrace.com/t5/Extensions/Set-query-method-checks-other-than-1-minute/m-p/186716#M2205</guid>
      <dc:creator>Ardhi</dc:creator>
      <dc:date>2022-05-19T12:53:24Z</dc:date>
    </item>
  </channel>
</rss>

