com.ibm.batch.container.services.impl
Class FileBasedPersistenceManagerImpl
java.lang.Object
com.ibm.batch.container.services.impl.AbstractPersistenceManagerImpl
com.ibm.batch.container.services.impl.AbstractMapBasedPersistenceManagerImpl
com.ibm.batch.container.services.impl.FileBasedPersistenceManagerImpl
- All Implemented Interfaces:
- IBatchServiceBase, IPersistenceManagerService
public class FileBasedPersistenceManagerImpl
- extends AbstractMapBasedPersistenceManagerImpl
- implements IPersistenceManagerService
|
Method Summary |
protected String |
_getStorePath(int storeId)
|
protected void |
_loadDataStores()
|
protected Hashtable |
_loadStore(int storeId)
|
protected void |
_saveStore(int storeId)
|
void |
createData(int storeDestination,
IPersistenceDataKey key,
Serializable value)
(Required) Its purpose is to insert data into a particular store. |
void |
deleteData(int storeDestination,
IPersistenceDataKey key)
(Required) Its purpose is to delete the data items corresponding to the
given key from the given store. |
List |
getData(int storeDestination,
IPersistenceDataKey key)
(Required) Its purpose is to fetch data using the given key from a particular store |
void |
init(IBatchConfig batchConfig)
|
void |
jobExecutionStatusStringUpdate(long key,
String statusToUpdate,
String statusString,
Timestamp updatets)
|
void |
jobExecutionTimestampUpdate(long key,
String timestampToUpdate,
Timestamp ts)
|
void |
jobOperatorCreateExecutionData(long key,
Timestamp createTime,
Timestamp starttime,
Timestamp endtime,
Timestamp updateTime,
Properties parms,
long instanceID,
String batchstatus,
String exitstatus)
|
void |
jobOperatorCreateJobInstanceData(long key,
String jobNameValue)
JOB OPERATOR ONLY METHODS |
int |
jobOperatorGetJobInstanceCount(String jobName)
|
List<Long> |
jobOperatorgetJobInstanceIds(String jobName,
int start,
int count)
|
Set<String> |
jobOperatorgetJobNames()
|
long |
jobOperatorQueryJobExecutionJobInstanceId(long executionID)
|
String |
jobOperatorQueryJobExecutionStatus(long executionID,
String requestedStatus)
|
Timestamp |
jobOperatorQueryJobExecutionTimestamp(long executionID,
String timetype)
|
void |
shutdown()
|
void |
stepExecutionCreateStepExecutionData(String stepExecutionKey,
long jobExecutionID,
long stepExecutionID)
|
long |
stepExecutionQueryID(String key,
String idtype)
|
List<StepExecution> |
stepExecutionQueryIDList(long key,
String idtype)
|
void |
updateData(int storeDestination,
IPersistenceDataKey key,
Serializable value)
(Required) Its purpose is to update one or more fields of a data item identified by the
key from the given data store. |
| Methods inherited from class com.ibm.batch.container.services.impl.AbstractMapBasedPersistenceManagerImpl |
_createCheckpointData, _createJobStatus, _createStepStatus, _deleteCheckpointData, _deleteJobStatus, _deleteStepStatus, _getCheckpointData, _getJobStatus, _getStepStatus, _updateCheckpointData, _updateJobStatus, _updateStepStatus |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FileBasedPersistenceManagerImpl
public FileBasedPersistenceManagerImpl()
init
public void init(IBatchConfig batchConfig)
throws BatchContainerServiceException
- Specified by:
init in interface IBatchServiceBase- Overrides:
init in class AbstractMapBasedPersistenceManagerImpl
- Throws:
BatchContainerServiceException
_loadDataStores
protected void _loadDataStores()
- Specified by:
_loadDataStores in class AbstractMapBasedPersistenceManagerImpl
_saveStore
protected void _saveStore(int storeId)
- Specified by:
_saveStore in class AbstractMapBasedPersistenceManagerImpl
_getStorePath
protected String _getStorePath(int storeId)
_loadStore
protected Hashtable _loadStore(int storeId)
shutdown
public void shutdown()
throws BatchContainerServiceException
- Specified by:
shutdown in interface IBatchServiceBase- Overrides:
shutdown in class AbstractMapBasedPersistenceManagerImpl
- Throws:
BatchContainerServiceException
createData
public void createData(int storeDestination,
IPersistenceDataKey key,
Serializable value)
throws PersistenceException
- Description copied from interface:
IPersistenceManagerService
- (Required) Its purpose is to insert data into a particular store.
- Specified by:
createData in interface IPersistenceManagerService- Overrides:
createData in class AbstractPersistenceManagerImpl
- Parameters:
storeDestination - The target store destination. One of
IPersistenceManagerService.JOB_STATUS_STORE_ID,
IPersistenceManagerService.STEP_STATUS_STORE_ID,
IPersistenceManagerService.CHECKPOINT_STORE_IDkey - A unique key under which the data should be stored.value - A serializable object that contains the actual payload. One of
JobStatus, StepStatus or CheckpointData
- Throws:
PersistenceException
deleteData
public void deleteData(int storeDestination,
IPersistenceDataKey key)
throws PersistenceException
- Description copied from interface:
IPersistenceManagerService
- (Required) Its purpose is to delete the data items corresponding to the
given key from the given store.
- Specified by:
deleteData in interface IPersistenceManagerService- Overrides:
deleteData in class AbstractPersistenceManagerImpl
- Parameters:
storeDestination - The store from which the data should be deleted. One of
IPersistenceManagerService.JOB_STATUS_STORE_ID,
IPersistenceManagerService.STEP_STATUS_STORE_ID,
IPersistenceManagerService.CHECKPOINT_STORE_ID
- Throws:
PersistenceException
getData
public List getData(int storeDestination,
IPersistenceDataKey key)
throws PersistenceException
- Description copied from interface:
IPersistenceManagerService
- (Required) Its purpose is to fetch data using the given key from a particular store
- Specified by:
getData in interface IPersistenceManagerService- Overrides:
getData in class AbstractPersistenceManagerImpl
- Parameters:
storeDestination - The store from which the data should be retrieved. One of
IPersistenceManagerService.JOB_STATUS_STORE_ID,
IPersistenceManagerService.STEP_STATUS_STORE_ID,
IPersistenceManagerService.CHECKPOINT_STORE_ID
- Returns:
- A list containing the data items that match the input key filter.
Depending on the type of the store the List should contain either
JobStatus, StepStatus or CheckpointData objects
- Throws:
PersistenceException
updateData
public void updateData(int storeDestination,
IPersistenceDataKey key,
Serializable value)
throws PersistenceException
- Description copied from interface:
IPersistenceManagerService
- (Required) Its purpose is to update one or more fields of a data item identified by the
key from the given data store.
- Specified by:
updateData in interface IPersistenceManagerService- Overrides:
updateData in class AbstractPersistenceManagerImpl
- Parameters:
storeDestination - The store from which the data should be updated. One of
IPersistenceManagerService.JOB_STATUS_STORE_ID,
IPersistenceManagerService.STEP_STATUS_STORE_ID,
IPersistenceManagerService.CHECKPOINT_STORE_ID
- Throws:
PersistenceException
jobOperatorGetJobInstanceCount
public int jobOperatorGetJobInstanceCount(String jobName)
- Specified by:
jobOperatorGetJobInstanceCount in interface IPersistenceManagerService
jobOperatorQueryJobExecutionJobInstanceId
public long jobOperatorQueryJobExecutionJobInstanceId(long executionID)
- Specified by:
jobOperatorQueryJobExecutionJobInstanceId in interface IPersistenceManagerService
jobOperatorQueryJobExecutionStatus
public String jobOperatorQueryJobExecutionStatus(long executionID,
String requestedStatus)
- Specified by:
jobOperatorQueryJobExecutionStatus in interface IPersistenceManagerService
jobOperatorQueryJobExecutionTimestamp
public Timestamp jobOperatorQueryJobExecutionTimestamp(long executionID,
String timetype)
- Specified by:
jobOperatorQueryJobExecutionTimestamp in interface IPersistenceManagerService
jobOperatorgetJobInstanceIds
public List<Long> jobOperatorgetJobInstanceIds(String jobName,
int start,
int count)
- Specified by:
jobOperatorgetJobInstanceIds in interface IPersistenceManagerService
jobOperatorgetJobNames
public Set<String> jobOperatorgetJobNames()
- Specified by:
jobOperatorgetJobNames in interface IPersistenceManagerService
jobExecutionStatusStringUpdate
public void jobExecutionStatusStringUpdate(long key,
String statusToUpdate,
String statusString,
Timestamp updatets)
- Specified by:
jobExecutionStatusStringUpdate in interface IPersistenceManagerService
jobExecutionTimestampUpdate
public void jobExecutionTimestampUpdate(long key,
String timestampToUpdate,
Timestamp ts)
- Specified by:
jobExecutionTimestampUpdate in interface IPersistenceManagerService
jobOperatorCreateExecutionData
public void jobOperatorCreateExecutionData(long key,
Timestamp createTime,
Timestamp starttime,
Timestamp endtime,
Timestamp updateTime,
Properties parms,
long instanceID,
String batchstatus,
String exitstatus)
- Specified by:
jobOperatorCreateExecutionData in interface IPersistenceManagerService
jobOperatorCreateJobInstanceData
public void jobOperatorCreateJobInstanceData(long key,
String jobNameValue)
- Description copied from interface:
IPersistenceManagerService
- JOB OPERATOR ONLY METHODS
- Specified by:
jobOperatorCreateJobInstanceData in interface IPersistenceManagerService
stepExecutionCreateStepExecutionData
public void stepExecutionCreateStepExecutionData(String stepExecutionKey,
long jobExecutionID,
long stepExecutionID)
- Specified by:
stepExecutionCreateStepExecutionData in interface IPersistenceManagerService
stepExecutionQueryID
public long stepExecutionQueryID(String key,
String idtype)
- Specified by:
stepExecutionQueryID in interface IPersistenceManagerService
stepExecutionQueryIDList
public List<StepExecution> stepExecutionQueryIDList(long key,
String idtype)
- Specified by:
stepExecutionQueryIDList in interface IPersistenceManagerService
Copyright © 2013. All Rights Reserved.