For our use-case to notify chat when a downtime/ack has run out we currently run the following API Call every 2 minutes: /api/1.0/domain-types/service/collections/all?columns=comments_with_extra_info&query={"op":"and","expr":[{"op":">","left":"acknowledgement_type","right":"0"}]}
The output we keep as a reference and do a diff to the current version to detect comments/downtimes that have been removed.
It works in principle and also sends out messages to chat.
But sometimes we observe that all ack infos vanisch for specific satellite sites (in distributed monitoring) for one iteration and 2 minutes later come back again.
As if check_mk is forgetting about the ACks because the livestatus link is slow or similar.
Obviously this produces a lot of unnecessary noise on our chat channel when this happens…
Is this a known issue with CMK enterprise 2.1? Is it maybe already fixed in 2.2 or later?
OK, so I did test things further and the problem is not that the api looses comments, but the API sometime does not report some hosts (which may or may not have comments).
Essentially what i am doing is this every 2 minutes: