Package org.dbos.apiary.function
Class ApiaryStatelessContext
java.lang.Object
org.dbos.apiary.function.ApiaryContext
org.dbos.apiary.function.ApiaryStatelessContext
ApiaryStatelessContext is a context for stateless functions.
-
Field Summary
Fields inherited from class org.dbos.apiary.function.ApiaryContext
execID, functionID, provBuff, service
-
Constructor Summary
ConstructorsConstructorDescriptionApiaryStatelessContext
(org.dbos.apiary.connection.ApiaryConnection c, InternalApiaryWorkerClient client, ProvenanceBuffer provBuff, String service, long execID, long functionID, Map<String, Callable<StatelessFunction>> statelessFunctions) -
Method Summary
Modifier and TypeMethodDescriptionapiaryCallFunction
(String name, Object... inputs) Synchronously invoke a function.For internal use only.void
recordExecution
(FunctionOutput output) For internal use only.Methods inherited from class org.dbos.apiary.function.ApiaryContext
apiaryQueueFunction, getFunctionOutput
-
Constructor Details
-
ApiaryStatelessContext
public ApiaryStatelessContext(org.dbos.apiary.connection.ApiaryConnection c, InternalApiaryWorkerClient client, ProvenanceBuffer provBuff, String service, long execID, long functionID, Map<String, Callable<StatelessFunction>> statelessFunctions)
-
-
Method Details
-
apiaryCallFunction
Description copied from class:ApiaryContext
Synchronously invoke a function.- Specified by:
apiaryCallFunction
in classApiaryContext
- Parameters:
name
- the fully-qualified name of the invoked function.inputs
- the list of arguments provided to the invoked function.- Returns:
- an
FunctionOutput
object that stores the output from a function.
-
checkPreviousExecution
Description copied from class:ApiaryContext
For internal use only.- Specified by:
checkPreviousExecution
in classApiaryContext
- Returns:
FunctionOutput
-
recordExecution
Description copied from class:ApiaryContext
For internal use only.- Specified by:
recordExecution
in classApiaryContext
- Parameters:
output
- the finalized output of a function.
-