/**
* Update all configured services.
+ * @param changed_to_online True if we just changed to online, false if we were already online
*/
-void Updater::update_services() const
+void Updater::update_services(bool changed_to_online) const
{
// Get all services from the ServiceHolder.
list<Service::Ptr> services = ServiceHolder->get_services();
// Test if the actual DNS-Record differs from the host's IP.
if (ip_host == ip_dns_recheck )
{
- Log->print_no_update_needed(hostname, ip_dns_recheck, ip_last_update, ip_host, lastupdated);
+ Log->print_no_update_needed(changed_to_online, hostname, ip_dns_recheck, ip_last_update, ip_host, lastupdated);
// No update needed
continue;
}
else
{
// DNS cache TTL isn't expired
- Log->print_update_service_ttl_not_expired(hostname, ip_dns_recheck, ip_last_update, ip_host, lastupdated, dns_cache_ttl, current_time);
+ Log->print_update_service_ttl_not_expired(changed_to_online, hostname, ip_dns_recheck, ip_last_update, ip_host, lastupdated, dns_cache_ttl, current_time);
}
}
}