public class OCommandExecutorScript extends OCommandExecutorAbstract implements OCommandDistributedReplicateRequest, OTemporaryRidGenerator
OCommandScript
OCommandDistributedReplicateRequest.DISTRIBUTED_EXECUTION_MODE, OCommandDistributedReplicateRequest.DISTRIBUTED_RESULT_MGMT, OCommandDistributedReplicateRequest.QUORUM_TYPE
Modifier and Type | Field and Description |
---|---|
protected OCommandDistributedReplicateRequest.DISTRIBUTED_EXECUTION_MODE |
executionMode |
protected OCommandScript |
request |
protected AtomicInteger |
serialTempRID |
context, limit, parameters, progressListener
parserText, parserTextUpperCase
Constructor and Description |
---|
OCommandExecutorScript() |
Modifier and Type | Method and Description |
---|---|
Object |
execute(Map<Object,Object> iArgs)
Execute the requested command parsed previously.
|
Object |
executeInContext(OCommandContext iContext,
Map<Object,Object> iArgs) |
protected Object |
executeJsr223Script(String language,
OCommandContext iContext,
Map<Object,Object> iArgs) |
protected Object |
executeSQL() |
protected Object |
executeSQLScript(String iText,
ODatabaseDocument db) |
OCommandDistributedReplicateRequest.DISTRIBUTED_EXECUTION_MODE |
getDistributedExecutionMode()
Returns the execution mode when distributed configuration is active:
LOCAL: executed on local node only
REPLICATE: executed on all the nodes and expect the same result
SHARDED: executed on all the involved nodes and merge results
|
OCommandDistributedReplicateRequest.QUORUM_TYPE |
getQuorumType()
Returns the quorum type for the command:
NONE: no quorum
READ: configured Read quorum
WRITE: configured Write quorum
ALL: all nodes
|
int |
getTemporaryRIDCounter(OCommandContext iContext) |
boolean |
isIdempotent()
Returns true if the command doesn't change the database, otherwise false.
|
OCommandExecutorScript |
parse(OCommandRequest iRequest)
Parse the request.
|
protected void |
throwSyntaxErrorException(String iText)
Throws a syntax error exception.
|
protected void |
waitForNextRetry()
Wait before to retry
|
checkInterruption, checkInterruption, getContext, getDatabase, getDistributedResultManagement, getDistributedTimeout, getFetchPlan, getInvolvedClusters, getLimit, getParameters, getProgressListener, getSecurityOperationType, getUndoCommand, init, involveSchema, isCacheable, isDistributedExecutingOnLocalNodeFirst, isLocalExecution, mergeResults, setContext, setLimit, setProgressListener, toString, upperCase
getLastWordLength, getSyntax, getWordStatic, nextWord, nextWord, parseOptionalWord, parserGetCurrentChar, parserGetCurrentPosition, parserGetLastSeparator, parserGetLastWord, parserGetPreviousPosition, parserGoBack, parserIsEnded, parserMoveCurrentPosition, parserNextChars, parserNextWord, parserNextWord, parserNextWord, parserOptionalKeyword, parserOptionalWord, parserRequiredKeyword, parserRequiredWord, parserRequiredWord, parserRequiredWord, parserSetCurrentPosition, parserSetEndOfText, parserSetLastSeparator, parserSkipWhiteSpaces
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getDistributedResultManagement, getDistributedTimeout, getUndoCommand, isDistributedExecutingOnLocalNodeFirst
getSyntax
protected OCommandScript request
protected OCommandDistributedReplicateRequest.DISTRIBUTED_EXECUTION_MODE executionMode
protected AtomicInteger serialTempRID
public OCommandExecutorScript parse(OCommandRequest iRequest)
OCommandExecutor
parse
in interface OCommandExecutor
iRequest
- Command request implementation.#execute(Map
public OCommandDistributedReplicateRequest.DISTRIBUTED_EXECUTION_MODE getDistributedExecutionMode()
OCommandDistributedReplicateRequest
getDistributedExecutionMode
in interface OCommandDistributedReplicateRequest
public Object execute(Map<Object,Object> iArgs)
OCommandExecutor
execute
in interface OCommandExecutor
iArgs
- Optional variable arguments to pass to the command.OCommandExecutor.parse(OCommandRequest)
public Object executeInContext(OCommandContext iContext, Map<Object,Object> iArgs)
public boolean isIdempotent()
OCommandExecutor
isIdempotent
in interface OCommandExecutor
protected Object executeJsr223Script(String language, OCommandContext iContext, Map<Object,Object> iArgs)
protected Object executeSQL()
protected void throwSyntaxErrorException(String iText)
OBaseParser
throwSyntaxErrorException
in class OBaseParser
iText
- Text about the problem.protected Object executeSQLScript(String iText, ODatabaseDocument db) throws IOException
IOException
protected void waitForNextRetry()
public OCommandDistributedReplicateRequest.QUORUM_TYPE getQuorumType()
OCommandDistributedReplicateRequest
getQuorumType
in interface OCommandDistributedReplicateRequest
public int getTemporaryRIDCounter(OCommandContext iContext)
getTemporaryRIDCounter
in interface OTemporaryRidGenerator
Copyright © 2009–2020 OrientDB. All rights reserved.