Trigger alarm when value is 0 since 6h without including night hours?

Hello

I have +500 metrics that are tracking if we have activity on specific stream of data.

  • I trigger an alarm if we didn’t received a message since 6h, sometimes less.
  • Alarm are muted between 7pm and 8am

But the issue is sometimes first activity start after 8am, so I have some noise between 8am and 8:30am.

I would like to know how I could still have the 6h or less limit but, do not count the mute interval?

For example:

  • Last message the Monday at 4pm, mute timing at 7pm, alarm is for 6h without message.
  • No message the Thuesday, mute timing until 8am, alarm firing at 11am

Thanks