public interface IBatchManager
Modifier and Type | Field and Description |
---|---|
static int |
REMOVE_OLD
Removes batches older than 6 months (default), or older than value
specified in configuration.
|
static int |
REMOVE_SUCCESS
Removes all jobs with no error or rejects.
|
Modifier and Type | Method and Description |
---|---|
IBatch |
addBatch(String name,
String group,
String uuid)
Creates and adds a new Batch to the batch manager.
|
List<IBatch> |
getBatches(String group,
String name)
Ordered by update date DESC
|
Properties |
getConfiguration()
Get current configuration.
|
List<IBatch> |
getErrorBatches()
Ordered by update date DESC
|
List<IBatch> |
getFinishedBatches()
Ordered by update date DESC
|
IBatchProgressMonitor |
getMonitor(IBatch batch)
Returns the batch monitor for this batch.
|
List<IBatch> |
getRunningBatches()
Returns the list of batchs which are currently running.
|
void |
init() |
void |
removeAllBatches(int scope)
Removes all jobs matching the scope value.
|
void |
removeBatch(String uuid)
Removes a specific job.
|
void |
setConfiguration(Properties configuration)
Inject configuration for service manager.
|
static final int REMOVE_OLD
static final int REMOVE_SUCCESS
IBatch addBatch(String name, String group, String uuid)
If the batch already exists (same uuid). The existing one is returned.
NOTE: This method is not intended to be called directly.
name
- group
- uuid
- AppStatus#getBatchProgressMonitor()
Properties getConfiguration()
IBatchProgressMonitor getMonitor(IBatch batch)
The same progress monitor is always returned. It is expected that only a single thread updates the monitor.
batch
- List<IBatch> getRunningBatches()
void init()
void removeAllBatches(int scope)
scope
- 1 or REMOVE_SUCCESS
void removeBatch(String uuid)
b
- void setConfiguration(Properties configuration)
configuration
- Copyright © 2010–2016. All rights reserved.