Moti Asayag has posted comments on this change.

Change subject: engine: Preventing running host monitor during activation of 
host operation
......................................................................


Patch Set 1: (4 inline comments)

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/ActivateVdsCommand.java
Line 50: 
Line 51:     @Override
Line 52:     protected void executeCommand() {
Line 53: 
Line 54:         EngineLock monitoring_lock =
s/ monitoring_lock/monitoringLock
Line 55:                 new 
EngineLock(Collections.singletonMap(getParameters().getVdsId().toString(),
Line 56:                         LockingGroup.VDS_INIT.name()), null);
Line 57:         log.info("Before acquiring lock in order to prevent 
monitoring");
Line 58:         getLockManager().acquireLockWait(monitoring_lock);


Line 55:                 new 
EngineLock(Collections.singletonMap(getParameters().getVdsId().toString(),
Line 56:                         LockingGroup.VDS_INIT.name()), null);
Line 57:         log.info("Before acquiring lock in order to prevent 
monitoring");
Line 58:         getLockManager().acquireLockWait(monitoring_lock);
Line 59:         log.info("Lock acquired, from now a monitoring of host will be 
skipped");
+1 I'd suggest adding both host name and host id into the logof the messages 
above.
Line 60:         try {
Line 61:             final VDS vds = getVds();
Line 62:             
ExecutionHandler.updateSpecificActionJobCompleted(vds.getId(), 
VdcActionType.MaintananceVds, false);
Line 63:             TransactionSupport.executeInNewTransaction(new 
TransactionMethod<Void>() {


Line 90:                 });
Line 91:             }
Line 92:         } finally {
Line 93:             getLockManager().releaseLock(monitoring_lock);
Line 94:             log.info("Activate finished. Lock released. Monitoring can 
run now");
please add host name and host id for this message as well. It will add clarity 
to the flow (instead of examining the log by thread id or correlation-id)
Line 95:         }
Line 96:     }
Line 97: 
Line 98:     @Override


....................................................
File 
backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsManager.java
Line 73:     private final Object _lockObj = new Object();
Line 74:     private static Map<Guid, String> recoveringJobIdMap = new 
ConcurrentHashMap<Guid, String>();
Line 75:     private boolean isSetNonOperationalExecuted;
Line 76:     private MonitoringStrategy monitoringStrategy;
Line 77:     private EngineLock monitoring_lock;
s/monitoring_lock/monitoringLock
Line 78:     public Object getLockObj() {
Line 79:         return _lockObj;
Line 80:     }
Line 81: 


--
To view, visit http://gerrit.ovirt.org/11885
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: If7f5eed741ca392ed7144934c539d2aa70744431
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Michael Kublin <[email protected]>
Gerrit-Reviewer: Alissa Bonas <[email protected]>
Gerrit-Reviewer: Barak Azulay <[email protected]>
Gerrit-Reviewer: Eli Mesika <[email protected]>
Gerrit-Reviewer: Michael Kublin <[email protected]>
Gerrit-Reviewer: Moti Asayag <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to