Alissa Bonas has posted comments on this change.
Change subject: core: improve logging
......................................................................
Patch Set 6: Verified
(7 inline comments)
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/AuditLogCleanupManager.java
Line 22: return _instance;
Line 23: }
Line 24:
Line 25: private AuditLogCleanupManager() {
Line 26: log.info("Start initializing " +
this.getClass().getSimpleName());
Done
Line 27: Calendar calendar = new GregorianCalendar();
Line 28: Date mAuditLogCleanupTime = Config.<DateTime>
GetValue(ConfigValues.AuditLogCleanupTime);
Line 29: calendar.setTimeInMillis(mAuditLogCleanupTime.getTime());
Line 30:
Line 33:
Line 34: log.info("Setting audit cleanup manager to run at: " +
cronExpression);
Line 35: SchedulerUtilQuartzImpl.getInstance().scheduleACronJob(this,
"OnTimer", new Class[] {}, new Object[] {},
Line 36: cronExpression);
Line 37: log.info("Finished initializing " +
this.getClass().getSimpleName());
Done
Line 38: }
Line 39:
Line 40: @OnTimerMethodAnnotation("OnTimer")
Line 41: public void OnTimer() {
Line 42: try {
Line 43: log.info("Start deleteAgedOutAuditLogs");
Line 44: DateTime latestTimeToKeep = DateTime.getNow().AddDays(
Line 45: Config.<Integer>
GetValue(ConfigValues.AuditLogAgingThreashold) * -1);
Line 46:
DbFacade.getInstance().getAuditLogDao().removeAllBeforeDate(latestTimeToKeep);
Done
Line 47: } catch (RuntimeException e) {
Line 48: log.error("deleteAgedOutAuditLog failed with exception",
e);
Line 49: }
Line 50: }
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/Backend.java
Line 191:
Line 192: _vdsErrorsTranslator = new
ErrorTranslatorImpl(VdsErrorsFileName);
Line 193:
Line 194: // initialize the JobRepository object and finalize
non-terminated jobs
Line 195: log.infoFormat("Mark incompleted jobs as {0}",
JobExecutionStatus.UNKNOWN.name());
Done
Line 196: initJobRepository();
Line 197:
Line 198: // initializes the JobRepositoryCleanupManager
Line 199: JobRepositoryCleanupManager.getInstance().initialize();
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/CpuFlagsManagerHandler.java
Line 29: _managersDictionary.clear();
Line 30: for (Version ver : Config.<HashSet<Version>>
GetValue(ConfigValues.SupportedClusterLevels)) {
Line 31: _managersDictionary.put(ver, new CpuFlagsManager(ver));
Line 32: }
Line 33: log.info("Finished initializing dictionaries" +
CpuFlagsManagerHandler.class.getSimpleName());
Done
Line 34: }
Line 35:
Line 36: public static String GetVDSVerbDataByCpuName(String name, Version
ver) {
Line 37: final CpuFlagsManager cpuFlagsManager =
_managersDictionary.get(ver);
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/network/MacPoolManager.java
Line 1: package org.ovirt.engine.core.bll.network;
Line 2:
Line 3: import java.util.*;
Done
Line 4: import java.util.concurrent.locks.ReentrantReadWriteLock;
Line 5:
Line 6: import org.apache.commons.lang.StringUtils;
Line 7: import org.ovirt.engine.core.common.AuditLogType;
....................................................
File
backend/manager/modules/utils/src/main/java/org/ovirt/engine/core/utils/ErrorTranslatorImpl.java
Line 15:
Line 16: public final class ErrorTranslatorImpl implements ErrorTranslator {
Line 17:
Line 18: private static final long ONE_HOUR = 60 * 60 * 1000L;
Line 19: private static Log log =
LogFactory.getLog(ErrorTranslatorImpl.class);
Done
Line 20: private List<String> messageSources;
Line 21: private Locale standardLocale;
Line 22: private Map<String, String> standardMessages;
Line 23: private ReapedMap<Locale, Map<String, String>> messagesByLocale;
--
To view, visit http://gerrit.ovirt.org/10823
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Iaea9c16e9913cdee4eef88de920e87bde8bc6b5d
Gerrit-PatchSet: 6
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Alissa Bonas <[email protected]>
Gerrit-Reviewer: Alissa Bonas <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Ayal Baron <[email protected]>
Gerrit-Reviewer: Laszlo Hornyak <[email protected]>
Gerrit-Reviewer: Liron Aravot <[email protected]>
Gerrit-Reviewer: Moti Asayag <[email protected]>
Gerrit-Reviewer: Tal Nisan <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches