@Internal
public interface SchedulerRunDetailsManager
Modifier and Type | Field and Description |
---|---|
static long |
ALL_JOBS_TTL_MILLIS
The time-to-live of outdated run details that will be purged
The default value is 90 days, which can be overridden by the system property "all.jobs.ttl.minutes" with the hour granularity
|
static long |
UNSUCCESSFUL_JOBS_TTL_MILLIS
The time-to-live of unsuccessful run details that will be purged
The default value is 7 days, which can be overridden by the system property "unsuccessful.jobs.ttl.hours" with the hour granularity
|
Modifier and Type | Method and Description |
---|---|
com.atlassian.scheduler.status.RunDetails |
addRunDetails(com.atlassian.scheduler.config.JobId jobId,
Date startedAt,
com.atlassian.scheduler.status.RunOutcome runOutcome,
@Nullable String message)
Delegates the task to the underlying Scheduler Service since the ConfluenceSchedulerService bean is not accessible from the add-on
|
long |
count(com.atlassian.scheduler.config.JobId jobId,
long timeToLiveThreshold,
com.atlassian.scheduler.status.RunOutcome runOutcome)
Count the job's run details that are stored before a time-to-live threshold in milliseconds
|
org.apache.commons.lang3.tuple.Pair<Integer,Integer> |
purgeOldRunDetails()
This method purges the old run details, i.e.
|
static final long ALL_JOBS_TTL_MILLIS
static final long UNSUCCESSFUL_JOBS_TTL_MILLIS
org.apache.commons.lang3.tuple.Pair<Integer,Integer> purgeOldRunDetails()
or DefaultSchedulerRunDetailsManager#UNSUCCESSFUL_JOBS_TTL_MILLIS
This prevents the table space from growing without bounds, and it is unlikely that you really
care about the results of a scheduled job that hasn't run in that long, anyway.long count(com.atlassian.scheduler.config.JobId jobId, long timeToLiveThreshold, com.atlassian.scheduler.status.RunOutcome runOutcome)
timeToLiveThreshold
- the TTL thresholdrunOutcome
- the run outcome that should be matchedcom.atlassian.scheduler.status.RunDetails addRunDetails(com.atlassian.scheduler.config.JobId jobId, Date startedAt, com.atlassian.scheduler.status.RunOutcome runOutcome, @Nullable String message)
jobId
- the Job IDstartedAt
- when the job is startedrunOutcome
- the run outcomemessage
- the messageCopyright © 2003–2019 Atlassian. All rights reserved.