public class TraversalOpProcessor extends AbstractOpProcessor
OpProcessor
implementation that iterates remotely submitted serialized Traversal
objects.Modifier and Type | Field and Description |
---|---|
protected static <any> |
cache
Deprecated.
As of release 3.3.8, not directly replaced in the protocol as side-effect retrieval after
traversal iteration is not being promoted anymore as a feature.
|
static String |
CONFIG_CACHE_EXPIRATION_TIME
Deprecated.
As of release 3.3.8, not directly replaced in the protocol as side-effect retrieval after
traversal iteration is not being promoted anymore as a feature.
|
static String |
CONFIG_CACHE_MAX_SIZE
Deprecated.
As of release 3.3.8, not directly replaced in the protocol as side-effect retrieval after
traversal iteration is not being promoted anymore as a feature.
|
static long |
DEFAULT_CACHE_EXPIRATION_TIME
Deprecated.
As of release 3.3.8, not directly replaced in the protocol as side-effect retrieval after
traversal iteration is not being promoted anymore as a feature.
|
static long |
DEFAULT_CACHE_MAX_SIZE
Deprecated.
As of release 3.3.8, not directly replaced in the protocol as side-effect retrieval after
traversal iteration is not being promoted anymore as a feature.
|
static Settings.ProcessorSettings |
DEFAULT_SETTINGS |
static String |
OP_PROCESSOR_NAME |
static Timer |
traversalOpTimer |
manageTransactions
Constructor and Description |
---|
TraversalOpProcessor() |
Modifier and Type | Method and Description |
---|---|
protected void |
beforeProcessing(Graph graph,
Context ctx) |
void |
close() |
protected Map<String,Object> |
generateMetaData(ChannelHandlerContext ctx,
RequestMessage msg,
ResponseStatusCode code,
Iterator itty)
Generates meta-data to put on a
ResponseMessage . |
String |
getName()
The name of the processor which requests must refer to "processor" field on a request.
|
protected void |
handleIterator(Context context,
Iterator itty,
Graph graph) |
void |
init(Settings settings)
Initialize the
OpProcessor with settings from the server. |
protected void |
iterateComplete(ChannelHandlerContext ctx,
RequestMessage msg,
Iterator itty)
Called when iteration within
AbstractOpProcessor.handleIterator(Context, Iterator) is on its final pass and the final
frame is about to be sent back to the client. |
protected void |
onError(Graph graph,
Context ctx) |
protected void |
onSideEffectSuccess(Graph graph,
Context ctx) |
protected void |
onTraversalSuccess(Graph graph,
Context ctx) |
ThrowingConsumer<Context> |
select(Context context)
Given the context (which contains the RequestMessage), return back a Consumer function that will be
executed with the context.
|
attemptCommit, attemptRollback, handleIterator, handleIterator, isForceFlushed, makeFrame, makeFrame
public static final String OP_PROCESSOR_NAME
public static final Timer traversalOpTimer
public static final Settings.ProcessorSettings DEFAULT_SETTINGS
@Deprecated public static final String CONFIG_CACHE_EXPIRATION_TIME
@Deprecated public static final long DEFAULT_CACHE_EXPIRATION_TIME
@Deprecated public static final String CONFIG_CACHE_MAX_SIZE
@Deprecated public static final long DEFAULT_CACHE_MAX_SIZE
protected static <any> cache
public String getName()
OpProcessor
public void init(Settings settings)
OpProcessor
OpProcessor
with settings from the server. This method should only be called once at
server startup by a single thread.public ThrowingConsumer<Context> select(Context context) throws OpProcessorException
OpProcessor
OpProcessorException
protected void iterateComplete(ChannelHandlerContext ctx, RequestMessage msg, Iterator itty)
AbstractOpProcessor
AbstractOpProcessor.handleIterator(Context, Iterator)
is on its final pass and the final
frame is about to be sent back to the client. This method only gets called on successful iteration of the
entire result.iterateComplete
in class AbstractOpProcessor
protected Map<String,Object> generateMetaData(ChannelHandlerContext ctx, RequestMessage msg, ResponseStatusCode code, Iterator itty)
AbstractOpProcessor
ResponseMessage
.generateMetaData
in class AbstractOpProcessor
itty
- a reference to the current Iterator
of results - it is not meant to be forwarded in
this methodprotected void handleIterator(Context context, Iterator itty, Graph graph) throws InterruptedException
InterruptedException
Copyright © 2013–2019 Apache Software Foundation. All rights reserved.