org.apache.tinkerpop.gremlin.server.op.traversal

## Class TraversalOpProcessor

- java.lang.Object
- - org.apache.tinkerpop.gremlin.server.op.AbstractOpProcessor
  - - org.apache.tinkerpop.gremlin.server.op.traversal.TraversalOpProcessor

- All Implemented Interfaces:
    AutoCloseable, OpProcessor

      public class TraversalOpProcessor
      extends AbstractOpProcessor

  Simple `OpProcessor` implementation that iterates remotely submitted serialized `Traversal` objects.
  Author:
    Stephen Mallette (http://stephen.genoprime.com)

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `OP_PROCESSOR_NAME`
    `static Timer` | `traversalOpTimer`

    - ### Fields inherited from class org.apache.tinkerpop.gremlin.server.op.AbstractOpProcessor

      `manageTransactions`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `TraversalOpProcessor()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `beforeProcessing(Graph graph, Context ctx)`
    `void` | `close()`
    `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)`
    `protected void` | `onError(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.

    - ### Methods inherited from class org.apache.tinkerpop.gremlin.server.op.AbstractOpProcessor

      `attemptCommit, attemptRollback, determineIfTemporaryException, generateResultMetaData, generateStatusAttributes, handleIterator, isForceFlushed, iterateComplete, makeFrame`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface org.apache.tinkerpop.gremlin.server.OpProcessor

      `init`

- - ### Field Detail

    - #### OP_PROCESSOR_NAME

          public static final String OP_PROCESSOR_NAME

      See Also:
        Constant Field Values

    - #### traversalOpTimer

          public static final Timer traversalOpTimer

  - ### Constructor Detail

    - #### TraversalOpProcessor

          public TraversalOpProcessor()

  - ### Method Detail

    - #### getName

          public String getName()

      Description copied from interface: `OpProcessor`
      The name of the processor which requests must refer to "processor" field on a request.

    - #### close

          public void close()
                     throws Exception

      Throws:
        `Exception`

    - #### select

          public ThrowingConsumer<Context> select(Context context)
                                           throws OpProcessorException

      Description copied from interface: `OpProcessor`
      Given the context (which contains the RequestMessage), return back a Consumer function that will be executed with the context. A typical implementation will simply check the "op" field on the RequestMessage and return the Consumer function for that particular operation.
      Returns:
      Throws:
        `OpProcessorException`

    - #### beforeProcessing

          protected void beforeProcessing(Graph graph,
                                          Context ctx)

    - #### onError

          protected void onError(Graph graph,
                                 Context ctx)

    - #### onTraversalSuccess

          protected void onTraversalSuccess(Graph graph,
                                            Context ctx)

    - #### handleIterator

          protected void handleIterator(Context context,
                                        Iterator itty,
                                        Graph graph)
                                 throws InterruptedException

      Throws:
        `InterruptedException`

Copyright © 2013–2021 Apache Software Foundation. All rights reserved.