Class JobHistoryHelper
java.lang.Object
org.nuxeo.ecm.platform.audit.api.job.JobHistoryHelper
Simple helper class to trace job execution using the Audit Service.
- Author:
- Thierry Delprat
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGets the last date the Job was failed.protected Date
getLastRunWithStatus
(String status) Gets the last date the Job was started.Gets the last date the Job was successfully run.protected AuditLogger
protected LogEntry
void
Logs an event for a successful Job completion.void
logJobFailed
(String errMessage) Logs an event for a failed Job execution.void
Logs an event for Job startup.
-
Field Details
-
JOB_STARTED_SUFFIX
- See Also:
-
JOB_ENDED_SUFFIX
- See Also:
-
JOB_FAILED_SUFFIX
- See Also:
-
logger
-
jobName
-
jobStartedEventId
-
jobEndedEventId
-
jobFailedEventId
-
-
Constructor Details
-
JobHistoryHelper
-
-
Method Details
-
getNewLogEntry
-
getLogger
-
logJobStarted
public void logJobStarted()Logs an event for Job startup. -
logJobEnded
public void logJobEnded()Logs an event for a successful Job completion. -
logJobFailed
Logs an event for a failed Job execution. -
getLastRunWithStatus
-
getLastSuccessfulRun
Gets the last date the Job was successfully run. -
getLastFailedRun
Gets the last date the Job was failed. -
getLastStarted
Gets the last date the Job was started.
-