vmInfo.getMoref(), vmInfo.getName());
continue;
}
/* Try to load archive metadata. */
VmArchiveManager vmArcMgr;
try {
vmArcMgr = new VmArchiveManager(cfgGlobal_, vmInfo);
} catch (Exception e) {
logException(e);
System.out.printf("[%s][%s] ##########_ERROR_##########\n",
vmInfo.getMoref(), vmInfo.getName());
continue;
}
/* Get status information from the metadata. */
try {
vmArcMgr.lock(0);
vmArcMgr.reload();
boolean isAvailable = profAllVm_.isAvailableWithMoref(vmMoref);
System.out.println
(vmArcMgr.getStatusString(statusInfo, isAvailable));
} catch (LockTimeoutException e) {
logException(e, "lock timeout" + vmInfo.toString());
System.out.printf("[%s][%s] ##########_LOCKED_##########\n",
vmInfo.getMoref(), vmInfo.getName());
} catch (Exception e) {
logException
(e, String.format
("Reload profile of %s failed.", vmInfo.toString()));
} finally {
vmArcMgr.unlock();
}
}
}