@Component
public class TaskExecutionManager
extends java.lang.Object
TaskExecutionManager
provides the actual implementation of request processing, reporting and storage.
The requests are queued up and gets processed in FIFO order.
THe class delegates report storage to ExecutionDataStore
Constructor and Description |
---|
TaskExecutionManager(SystemConfig systemConfig,
ExecutionDataStore dataStore,
InetSocketAddressCache inetCache) |
Modifier and Type | Method and Description |
---|---|
java.util.List<LightningRequestReport> |
getAuditReports(java.lang.String sessionId) |
SystemStatus |
getLightningStats() |
LightningRequestReport |
getReport(java.lang.String sessionId) |
java.util.Map<ReservationReceipt,java.lang.Long> |
getReservationResponseLog()
Get the current reservation list.
|
SystemConfig |
getSystemConfig() |
java.util.concurrent.BlockingQueue<LightningRequest> |
getWorkQueue()
Get the request to be processed queue.
|
LightningResponse |
pollResults(java.lang.String sessionId,
boolean pollDeltaOnly) |
ReservationReceipt |
reserve(int load) |
void |
setWorkQueue(java.util.concurrent.BlockingQueue<LightningRequest> workQueue)
Set the request to be processed queue.
|
void |
start()
Initialized the
TaskExecutionManager with reservation cleanup Reminder and request processing thread. |
void |
submit(LightningRequest request) |
SystemConfig |
updateSystemConfig(SystemConfig sysConfig) |
@Autowired public TaskExecutionManager(SystemConfig systemConfig, ExecutionDataStore dataStore, InetSocketAddressCache inetCache)
@PostConstruct public void start()
TaskExecutionManager
with reservation cleanup Reminder
and request processing thread.public ReservationReceipt reserve(int load)
public void submit(LightningRequest request)
public LightningResponse pollResults(java.lang.String sessionId, boolean pollDeltaOnly)
public LightningRequestReport getReport(java.lang.String sessionId)
public java.util.List<LightningRequestReport> getAuditReports(java.lang.String sessionId)
public SystemStatus getLightningStats()
public SystemConfig updateSystemConfig(SystemConfig sysConfig) throws java.lang.Exception
java.lang.Exception
public java.util.concurrent.BlockingQueue<LightningRequest> getWorkQueue()
public void setWorkQueue(java.util.concurrent.BlockingQueue<LightningRequest> workQueue)
workQueue
- to process queuepublic SystemConfig getSystemConfig()
public java.util.Map<ReservationReceipt,java.lang.Long> getReservationResponseLog()