<?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 date diff until in Alerting</title>
    <link>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681211#M15827</link>
    <description>&lt;P&gt;I have an alert which detects when a log feed has failed&lt;/P&gt;&lt;P&gt;The team the alert goes to have asked that I allow them to suppress the alert.&lt;/P&gt;&lt;P&gt;I have now created a mailto link within the alert email that sends and email with a specifically crafted email subject and body that is detected in all future alerts to suppress future alerts for 12hrs.&lt;BR /&gt;a simple math calculation generates the 12hrs, the epoch timestamp is in the subject header, the alert spl looks at the subject and either suppresses the alert or not.&lt;/P&gt;&lt;P&gt;This works perfectly - the technical team have now asked that I vary the suppression as follows&lt;/P&gt;&lt;P&gt;If the alert came in before 10AM the suppression remains 12 hours&lt;BR /&gt;If the alert came in after 10AM then the suppression time would be "until 10AM the following day".&lt;BR /&gt;&lt;BR /&gt;So - how do you calculate a time stamp to 10AM the following day.&lt;BR /&gt;It must be simple but my mind has lost it right now.&lt;BR /&gt;Something like is current hour &amp;gt;10AM timestamp=tomorrow:10Hrs&lt;/P&gt;</description>
    <pubDate>Tue, 19 Mar 2024 16:30:56 GMT</pubDate>
    <dc:creator>DaveBunn</dc:creator>
    <dc:date>2024-03-19T16:30:56Z</dc:date>
    <item>
      <title>date diff until</title>
      <link>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681211#M15827</link>
      <description>&lt;P&gt;I have an alert which detects when a log feed has failed&lt;/P&gt;&lt;P&gt;The team the alert goes to have asked that I allow them to suppress the alert.&lt;/P&gt;&lt;P&gt;I have now created a mailto link within the alert email that sends and email with a specifically crafted email subject and body that is detected in all future alerts to suppress future alerts for 12hrs.&lt;BR /&gt;a simple math calculation generates the 12hrs, the epoch timestamp is in the subject header, the alert spl looks at the subject and either suppresses the alert or not.&lt;/P&gt;&lt;P&gt;This works perfectly - the technical team have now asked that I vary the suppression as follows&lt;/P&gt;&lt;P&gt;If the alert came in before 10AM the suppression remains 12 hours&lt;BR /&gt;If the alert came in after 10AM then the suppression time would be "until 10AM the following day".&lt;BR /&gt;&lt;BR /&gt;So - how do you calculate a time stamp to 10AM the following day.&lt;BR /&gt;It must be simple but my mind has lost it right now.&lt;BR /&gt;Something like is current hour &amp;gt;10AM timestamp=tomorrow:10Hrs&lt;/P&gt;</description>
      <pubDate>Tue, 19 Mar 2024 16:30:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681211#M15827</guid>
      <dc:creator>DaveBunn</dc:creator>
      <dc:date>2024-03-19T16:30:56Z</dc:date>
    </item>
    <item>
      <title>Re: date diff until</title>
      <link>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681216#M15828</link>
      <description>&lt;P&gt;Use the &lt;FONT face="courier new,courier"&gt;relative_time&lt;/FONT&gt; function to calculate time offsets.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| eval new_time = relative_time(now(), "+1d@d+10h")&lt;/LI-CODE&gt;&lt;P&gt;The format string breaks down as follows:&lt;/P&gt;&lt;P&gt;"+1" : this time tomorrow&lt;BR /&gt;"@d": round off the time to 0:00&lt;BR /&gt;"+10h": add ten hours&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Mar 2024 17:11:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681216#M15828</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2024-03-19T17:11:15Z</dc:date>
    </item>
    <item>
      <title>Re: date diff until</title>
      <link>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681823#M15854</link>
      <description>&lt;P&gt;Thanks Rich - logical when you think about it.&lt;/P&gt;&lt;P&gt;Works a treat - thank you&lt;/P&gt;</description>
      <pubDate>Mon, 25 Mar 2024 09:02:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681823#M15854</guid>
      <dc:creator>DaveBunn</dc:creator>
      <dc:date>2024-03-25T09:02:35Z</dc:date>
    </item>
    <item>
      <title>Re: date diff until</title>
      <link>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681849#M15858</link>
      <description>&lt;P&gt;If your problem is resolved, then please click the "Accept as Solution" button to help future readers.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Mar 2024 11:53:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/date-diff-until/m-p/681849#M15858</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2024-03-25T11:53:35Z</dc:date>
    </item>
  </channel>
</rss>

