From f8918bd51026807518dde0fdebec9178a196269b Mon Sep 17 00:00:00 2001 From: Christian Herdtweck Date: Wed, 6 May 2015 17:02:56 +0200 Subject: [PATCH] logging update --- src/host/pingscheduler.cpp | 13 ++++++++----- 1 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/host/pingscheduler.cpp b/src/host/pingscheduler.cpp index b72dcba..664ad14 100644 --- a/src/host/pingscheduler.cpp +++ b/src/host/pingscheduler.cpp @@ -171,7 +171,7 @@ void PingScheduler::ping_when_ready() if ( !WantToPing ) { GlobalLogger.info() << LogPrefix << "waiting for ping request " - << "(should take less than " << PingIntervalInSec << "s)"; + << "(should take no more than than " << PingIntervalInSec << "s)"; return; } else if ( Resolver && Resolver->is_resolving() ) @@ -244,6 +244,9 @@ void PingScheduler::ping_when_ready() */ void PingScheduler::ping_done_handler( const bool ping_success ) { + GlobalLogger.info() << LogPrefix << "Ping done with success = " + << ping_success; + // post-processing // You must call these 3 methods exactly in this order // TODO Fix this method, once it has a semantic dependency with the @@ -385,7 +388,7 @@ void PingScheduler::update_dns_resolver( PingProtocol current_protocol ) if (ip_count > 0) { GlobalLogger.info() << LogPrefix << "Set resolved_ip_count to " - << ip_count << " where IPs may be outdated: " << !check_up_to_date; + << ip_count << " (IPs may be outdated=" << !check_up_to_date << ")"; HostAnalyzer.set_resolved_ip_count( ip_count ); if (Resolver->is_resolving()) @@ -435,8 +438,8 @@ void PingScheduler::dns_resolve_callback(const bool was_success, else { GlobalLogger.info() << LogPrefix << "Set resolved_ip_count to " - << ip_count << " where IPs may be outdated: " - << ContinueOnOutdatedIps << " --> could ping now"; + << ip_count << " (IPs may be outdated=" + << ContinueOnOutdatedIps << ") --> could ping now"; HostAnalyzer.set_resolved_ip_count( ip_count ); } ping_when_ready(); @@ -456,7 +459,7 @@ void PingScheduler::dns_resolve_callback(const bool was_success, int ip_count = Resolver->get_resolved_ip_count(false); GlobalLogger.info() << LogPrefix << "Set resolved_ip_count to " - << ip_count << " where IPs may be outdated: " << true; + << ip_count << " (IPs may be outdated=" << true << ")"; HostAnalyzer.set_resolved_ip_count( ip_count ); ping_when_ready(); -- 1.7.1