Martin Peřina has posted comments on this change. Change subject: core: VM Monitoring abstract fetching/analyzing/monitoring ......................................................................
Patch Set 14: (5 comments) http://gerrit.ovirt.org/#/c/28662/14/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/ResourceManager.java File backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/ResourceManager.java: Line 456: return null; Line 457: } Line 458: Line 459: public VmManager getVmManager(Guid vmId) { Line 460: if (vmManagers.contains(vmId)) { Why not use putIfAbsent as before? Line 461: return vmManagers.get(vmId); Line 462: } else { Line 463: VmManager value = new VmManager(vmId); Line 464: vmManagers.put(vmId, value); http://gerrit.ovirt.org/#/c/28662/14/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsManager.java File backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsManager.java: Line 88: private IVdsServer vdsProxy; Line 89: private boolean mBeforeFirstRefresh = true; Line 90: private HostMonitoring hostMonitoring; Line 91: private boolean monitoringNeeded; Line 92: private List<Pair<VM, VmInternalData>> lastVmsList = Collections.emptyList(); Please initialize in constructor Line 93: Line 94: private VdsManager(VDS vds) { Line 95: log.info("Entered VdsManager constructor"); Line 96: cachedVds = vds; Line 160: new Object[0], Line 161: refreshRate, Line 162: refreshRate, Line 163: TimeUnit.MILLISECONDS); Line 164: // register push provider and consumer TODO ? Line 165: } Line 166: Line 167: private void initVdsBroker() { Line 168: log.info("Initialize vdsBroker '{}:{}'", cachedVds.getHostName(), cachedVds.getPort()); Line 289: } Line 290: } Line 291: Line 292: VDS getVds() { Line 293: return cachedVds.clone(); Do we need to clone? Line 294: } Line 295: public String getVdsName() { Line 296: return cachedVds.getName(); Line 297: } http://gerrit.ovirt.org/#/c/28662/14/backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VmsMonitoring.java File backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VmsMonitoring.java: Line 34: import org.ovirt.engine.core.vdsbroker.vdsbroker.FullListVdsCommand; Line 35: import org.ovirt.engine.core.vdsbroker.vdsbroker.VdsProperties; Line 36: import org.ovirt.engine.core.vdsbroker.vdsbroker.entities.VmInternalData; Line 37: import org.slf4j.Logger; Line 38: import org.slf4j.LoggerFactory; Please fix import ordering (java.* 1st) Line 39: Line 40: import java.util.ArrayList; Line 41: import java.util.Arrays; Line 42: import java.util.Collection; -- To view, visit http://gerrit.ovirt.org/28662 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I1adf0a95007140e89b080b5160ba93e340ee3ba6 Gerrit-PatchSet: 14 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Roy Golan <rgo...@redhat.com> Gerrit-Reviewer: Martin Peřina <mper...@redhat.com> Gerrit-Reviewer: Michal Skrivanek <michal.skriva...@redhat.com> Gerrit-Reviewer: Omer Frenkel <ofren...@redhat.com> Gerrit-Reviewer: Oved Ourfali <oourf...@redhat.com> Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczew...@gmail.com> Gerrit-Reviewer: Roy Golan <rgo...@redhat.com> Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches