public class CachedHistoryStorage extends AbstractService implements HistoryStorage
Service.STATE| Constructor and Description |
|---|
CachedHistoryStorage() |
| Modifier and Type | Method and Description |
|---|---|
Map<JobId,Job> |
getAllPartialJobs()
Get all of the cached jobs.
|
Job |
getFullJob(JobId jobId)
Get a fully parsed job.
|
static JobsInfo |
getPartialJobs(Collection<Job> jobs,
Long offset,
Long count,
String user,
String queue,
Long sBegin,
Long sEnd,
Long fBegin,
Long fEnd,
JobState jobState) |
JobsInfo |
getPartialJobs(Long offset,
Long count,
String user,
String queue,
Long sBegin,
Long sEnd,
Long fBegin,
Long fEnd,
JobState jobState)
Look for a set of partial jobs.
|
void |
serviceInit(Configuration conf)
All initialization code needed by a service.
|
void |
setHistoryFileManager(HistoryFileManager hsManager)
Give the Storage a reference to a class that can be used to interact with
history files.
|
close, getBlockers, getConfig, getFailureCause, getFailureState, getLifecycleHistory, getName, getServiceState, getStartTime, init, isInState, noteFailure, putBlocker, registerGlobalListener, registerServiceListener, removeBlocker, serviceStart, serviceStop, setConfig, start, stop, toString, unregisterGlobalListener, unregisterServiceListener, waitForServiceToStoppublic void setHistoryFileManager(HistoryFileManager hsManager)
HistoryStoragesetHistoryFileManager in interface HistoryStoragehsManager - the class that is used to interact with history files.public void serviceInit(Configuration conf) throws Exception
AbstractServiceAbstractService.init(Configuration) prevents re-entrancy.
The base implementation checks to see if the subclass has created
a new configuration instance, and if so, updates the base class valueserviceInit in class AbstractServiceconf - configurationException - on a failure -these will be caught,
possibly wrapped, and wil; trigger a service stoppublic Job getFullJob(JobId jobId)
HistoryStoragegetFullJob in interface HistoryStoragejobId - the id of the jobpublic Map<JobId,Job> getAllPartialJobs()
HistoryStoragegetAllPartialJobs in interface HistoryStoragepublic JobsInfo getPartialJobs(Long offset, Long count, String user, String queue, Long sBegin, Long sEnd, Long fBegin, Long fEnd, JobState jobState)
HistoryStoragegetPartialJobs in interface HistoryStorageoffset - the offset into the list of jobs.count - the maximum number of jobs to return.user - only return jobs for the given user.queue - only return jobs for in the given queue.sBegin - only return Jobs that started on or after the given time.sEnd - only return Jobs that started on or before the given time.fBegin - only return Jobs that ended on or after the given time.fEnd - only return Jobs that ended on or before the given time.jobState - only return Jobs that are in the given job state.Copyright © 2013 Apache Software Foundation. All rights reserved.