|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.sparql.benchmarking.runners.AbstractRunner<T>
T - public abstract class AbstractRunner<T extends Options>
Abstract implementation of a runner providing common halting and progress reporting functionality
| Constructor Summary | |
|---|---|
AbstractRunner()
|
|
| Method Summary | |
|---|---|
protected void |
checkOperations(T options)
|
protected boolean |
checkSanity(T options)
Checks that the query endpoint/in-memory dataset being used passes some basic queries to see if it is up and running |
protected void |
finished(T options)
Informs all registered progress listeners that the run has finished |
protected String[] |
getSanityCheckQueries()
Gets the queries used for sanity checking |
void |
halt(T options,
Exception e)
Requests that the run be halted, exact halting conditions and behaviour is specified by the given options |
void |
halt(T options,
String message)
Requests that the run be halted, exact halting conditions and behaviour is specified by the given options |
void |
reportAfterOperation(T options,
Operation operation,
OperationRun run)
Reports progress after we have run an operation |
void |
reportAfterOperationMix(T options,
OperationMix mix,
OperationMixRun run)
Reports progress after we complete a run of the operation mix |
void |
reportBeforeOperation(T options,
Operation operation)
Reports progress before we run an operation |
void |
reportBeforeOperationMix(T options,
OperationMix mix)
Reports progress before we run an operation mix |
protected void |
reportCategorizedErrors(T options,
Map<Integer,List<OperationRun>> categorizedErrors)
Reports categorized errors |
protected void |
reportGeneralOptions(T options)
Reports information about the general options specified |
protected void |
reportOperationSummary(T options,
Operation op)
Reports a summary of the operation |
void |
reportPartialProgress(T options,
String message)
Reports progress with an informational message |
void |
reportProgress(T options)
Reports a newline as a progress message |
void |
reportProgress(T options,
String message)
Reports progress with an informational message |
protected OperationMixRun |
runMix(T options)
Runs the actual operation mix using the configured operation mix runner, if there is no configured runner then it uses the DefaultOperationMixRunner to run the mix |
protected OperationRun |
runOp(T options,
Operation op)
Runs an operation using the configured operation runner, if there is no configured runner then it uses the DefaultOperationRunner to run
the operation. |
protected void |
runSanityChecks(T options)
Helper method for running the sanity checks |
protected void |
runSetup(T options)
Runs the setup mix (if any) guaranteeing that operations run in precisely the order specified |
protected void |
runTeardown(T options)
Runs the tear down mix (if any) guaranteeing that operations run in precisely the order specified |
protected void |
started(T options)
Informs all registered progress listeners that the run has started |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface net.sf.sparql.benchmarking.runners.Runner |
|---|
run |
| Constructor Detail |
|---|
public AbstractRunner()
| Method Detail |
|---|
public void halt(T options,
String message)
Runner
halt in interface Runner<T extends Options>options - Optionsmessage - Halting Message
public void halt(T options,
Exception e)
Runner
halt in interface Runner<T extends Options>options - Optionse - Exceptionpublic void reportProgress(T options)
Runner
reportProgress in interface Runner<T extends Options>options - Options
public void reportPartialProgress(T options,
String message)
RunnerMessages passed to this function are sent to listeners as-is
reportPartialProgress in interface Runner<T extends Options>options - Optionsmessage - Informational Message
public void reportProgress(T options,
String message)
RunnerMessages passed to this function will always have a terminating newline character added to them before being sent to listeners
You can configure what happens to the reporting messages by adding
ProgressListener instances with the
Options.addListener(ProgressListener) method
reportProgress in interface Runner<T extends Options>options - Optionsmessage - Informational Message
public void reportBeforeOperation(T options,
Operation operation)
Runner
reportBeforeOperation in interface Runner<T extends Options>options - Optionsoperation - Operation
public void reportAfterOperation(T options,
Operation operation,
OperationRun run)
Runner
reportAfterOperation in interface Runner<T extends Options>options - Optionsoperation - Operationrun - Run information
public void reportBeforeOperationMix(T options,
OperationMix mix)
Runner
reportBeforeOperationMix in interface Runner<T extends Options>options - Optionsmix - Operation mix
public void reportAfterOperationMix(T options,
OperationMix mix,
OperationMixRun run)
Runner
reportAfterOperationMix in interface Runner<T extends Options>options - Optionsmix - Operation mixrun - Operation mix run informationprotected boolean checkSanity(T options)
May be overridden by runner implementations to change the sanity checking constraints
options - Options
protected String[] getSanityCheckQueries()
protected void checkOperations(T options)
protected void runTeardown(T options)
options - Optionsprotected void runSetup(T options)
options - Options
protected OperationRun runOp(T options,
Operation op)
DefaultOperationRunner to run
the operation.
options - Optionsop - Operation to run
protected OperationMixRun runMix(T options)
DefaultOperationMixRunner to run the mix
options - Options
protected void reportCategorizedErrors(T options,
Map<Integer,List<OperationRun>> categorizedErrors)
options - OptionscategorizedErrors - Categorized Errorsprotected void finished(T options)
options - Optionsprotected void started(T options)
options - Optionsprotected void reportGeneralOptions(T options)
options - Options
protected void reportOperationSummary(T options,
Operation op)
options - Optionsop - Operationprotected void runSanityChecks(T options)
options - Options
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||