Moti Asayag has posted comments on this change.

Change subject: core: Add event for MAC pool initialization error
......................................................................


Patch Set 11: (4 inline comments)

....................................................
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/MacPoolManager.java
Line 179:         }
Line 180:     }
Line 181: 
Line 182:     private void logInitializationError(String message) {
Line 183:         log.error("The Mac pool is not initialized");
s/Mac pool/MAC addresses pool
Line 184:         AuditLogableBase logable = new AuditLogableBase();
Line 185:         logable.AddCustomValue("Message",message);
Line 186:         AuditLogDirector.log(logable, 
AuditLogType.MAC_POOL_NOT_INITIALIZED);
Line 187:     }


Line 235:         log.info("MacPoolManager::freeMacs - entered");
Line 236:         mLocObj.writeLock().lock();
Line 237:         try {
Line 238:             if (!mInitialized) {
Line 239:                 logInitializationError("Failed to free macs.");
s/macs/ MAC addresses
Line 240:             }
Line 241:             for (String mac : macs) {
Line 242:                 internalFreeMac(mac);
Line 243:             }


....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/AuditLogType.java
Line 450:     MAC_POOL_EMPTY(816),
Line 451:     MAC_ADDRESS_IS_IN_USE(833),
Line 452:     CERTIFICATE_FILE_NOT_FOUND(817),
Line 453:     RUN_VM_FAILED(818),
Line 454:     
MAC_POOL_NOT_INITIALIZED(837,AuditLogTimeInterval.HOUR.getValue()),
s/MAC_POOL_NOT_INITIALIZED/MAC_ADDRESSES_POOL_NOT_INITIALIZED
Line 455:     // CBC
Line 456:     VDS_REGISTER_ERROR_UPDATING_HOST(819),
Line 457:     VDS_REGISTER_ERROR_UPDATING_HOST_ALL_TAKEN(820),
Line 458:     VDS_REGISTER_HOST_IS_ACTIVE(821),


....................................................
File 
backend/manager/modules/dal/src/main/resources/bundles/AuditLogMessages.properties
Line 321: USER_UPDATE_VM_POOL_WITH_VMS_FAILED=Failed to update VM Pool 
${VmPoolName}(User: ${UserName}).
Line 322: USER_VM_POOL_MAX_SUBSEQUENT_FAILURES_REACHED=Not all VMs where 
successfully created in VM Pool ${VmPoolName}.
Line 323: MAC_POOL_EMPTY=No MAC addresses left in the MAC Address Pool.
Line 324: MAC_ADDRESS_IS_IN_USE=VM ${VmName}: Mac Address ${MACAddr} is in use.
Line 325: MAC_POOL_NOT_INITIALIZED=Mac Address Pool is not initialized. 
${Message}
Although ${Message} saves some coding and introducing another AuditLogType, I 
think that in respect to localization this is a sin ;-)

However i'm not sure this resource has support for other languages.
Line 326: USER_PASSWORD_CHANGED=Password changed successfully for ${UserName}
Line 327: USER_PASSWORD_CHANGE_FAILED=Failed to change password. (User: 
${UserName})
Line 328: USER_CLEAR_UNKNOWN_VMS=All VMs' status on Non-Responsive Host 
${VdsName} were changed to 'Down' by ${UserName}
Line 329: USER_FAILED_CLEAR_UNKNOWN_VMS=Failed to clear VMs' status on 
Non-Responsive Host ${VdsName}. (User: ${UserName}).


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

Gerrit-MessageType: comment
Gerrit-Change-Id: Ibaa3d9eb23016b4866e5cfa39f919378e09fdf2d
Gerrit-PatchSet: 11
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Yair Zaslavsky <[email protected]>
Gerrit-Reviewer: Eli Mesika <[email protected]>
Gerrit-Reviewer: Gilad Chaplik <[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