Closeable, AutoCloseable, CommandReceivingComponent, Component, ExpectedResponseReceivingComponent, PlatformConnector, ResponseReceivingComponentpublic class InMemoryEvaluationStore extends AbstractEvaluationStorage
| Modifier and Type | Class | Description |
|---|---|---|
static class |
InMemoryEvaluationStore.ResultImpl |
A simple structure implementing the
Result interface |
static class |
InMemoryEvaluationStore.ResultPairImpl |
A simple structure implementing the
ResultPair interface. |
| Modifier and Type | Field | Description |
|---|---|---|
private Map<String,ResultPair> |
results |
Map containing a mapping from task Ids to result pairs.
|
cmdChannel, cmdQueueFactory, defaultContainerTypeconnectionFactory, incomingDataQueueFactory, NUMBER_OF_RETRIES_TO_CONNECT_TO_RABBIT_MQ, outgoingDataQueuefactory, rabbitMQHostName, START_WAITING_TIME_BEFORE_RETRYackChannel, evalModule2EvalStoreQueue, NEW_ITERATOR_ID, RECEIVE_TIMESTAMP_FOR_SYSTEM_RESULTS_KEY, resultPairIterators, systemResultReceiver, taskResultReceiver| Constructor | Description |
|---|---|
InMemoryEvaluationStore() |
| Modifier and Type | Method | Description |
|---|---|---|
protected Iterator<ResultPair> |
createIterator() |
Creates a new iterator that iterates over the response pairs.
|
void |
putResult(boolean isExpectedResult,
String taskId,
long timestamp,
byte[] data) |
Adds the given result to the map of results.
|
void |
receiveExpectedResponseData(String taskId,
long timestamp,
byte[] data) |
This method is called if an expected response is received from a task
generator component.
|
void |
receiveResponseData(String taskId,
long timestamp,
byte[] data) |
This method is called if a response is received from the system.
|
addCommandHeaderId, createContainer, createContainer, handleCmd, sendToCmdQueue, sendToCmdQueue, sendToCmdQueuecreateConnection, generateSessionQueueName, getHobbitSessionIdclose, init, receiveCommand, runaddContainerObserver, createContainer, getFactoryForIncomingCmdQueues, getFactoryForIncomingDataQueues, getFactoryForOutgoingCmdQueues, getFactoryForOutgoingDataQueues, stopContainerprivate Map<String,ResultPair> results
public void receiveResponseData(String taskId, long timestamp, byte[] data)
ResponseReceivingComponenttaskId - the id of the tasktimestamp - the time at which the response has been received from the
systemdata - the data received from a data generatorpublic void receiveExpectedResponseData(String taskId, long timestamp, byte[] data)
ExpectedResponseReceivingComponenttaskId - the id of the tasktimestamp - the time at which the task has been sent to the systemdata - the data received from a task generatorpublic void putResult(boolean isExpectedResult,
String taskId,
long timestamp,
byte[] data)
isExpectedResult - true if the result has been received from a task generator,
i.e., is the expected result for a tasktaskId - id of the tasktimestamp - time stamp for the task resultdata - the resultprotected Iterator<ResultPair> createIterator()
AbstractEvaluationStoragecreateIterator in class AbstractEvaluationStorageCopyright © 2017. All rights reserved.