diff --git a/src/host/Host.cc b/src/host/Host.cc index 5fd411a06d..6a12e1c9fe 100644 --- a/src/host/Host.cc +++ b/src/host/Host.cc @@ -203,7 +203,7 @@ int Host::update_info(string &parse_str, ostringstream ess; ess << "Error parsing host information: " << error_msg - << "Monitoring information: " << parse_str; + << ". Monitoring information: " << endl << parse_str; NebulaLog::log("ONE", Log::ERROR, ess); diff --git a/src/im/InformationManagerDriver.cc b/src/im/InformationManagerDriver.cc index d9bbc8971e..fdd60e58f4 100644 --- a/src/im/InformationManagerDriver.cc +++ b/src/im/InformationManagerDriver.cc @@ -119,11 +119,11 @@ void InformationManagerDriver::protocol( host->error_info(*hinfo, vm_ids); + Nebula &ne = Nebula::instance(); + LifeCycleManager *lcm = ne.get_lcm(); + for (set::iterator it = vm_ids.begin(); it != vm_ids.end(); it++) { - Nebula &ne = Nebula::instance(); - LifeCycleManager *lcm = ne.get_lcm(); - lcm->trigger(LifeCycleManager::MONITOR_DONE, *it); } @@ -137,19 +137,17 @@ void InformationManagerDriver::protocol( rc = host->update_info(*hinfo, vm_poll, lost, found); + delete hinfo; + + hpool->update(host); + if (rc != 0) { - delete hinfo; - - hpool->update(host); host->unlock(); return; } - delete hinfo; - - hpool->update(host); hpool->update_monitoring(host); ess << "Host " << host->get_name() << " (" << host->get_oid() << ")" @@ -164,11 +162,11 @@ void InformationManagerDriver::protocol( set::iterator its; map::iterator itm; + Nebula &ne = Nebula::instance(); + LifeCycleManager *lcm = ne.get_lcm(); + for (its = lost.begin(); its != lost.end(); its++) { - Nebula &ne = Nebula::instance(); - LifeCycleManager *lcm = ne.get_lcm(); - lcm->trigger(LifeCycleManager::MONITOR_DONE, *its); }