Search Results for

    Show / Hide Table of Contents

    Class RemoteTransaction

    A controller for a remote transaction that is constructed from

    g.Tx()
    . Calling
    Begin()
    on this object will produce a new
    GraphTraversalSource
    that is bound to a remote transaction over which multiple traversals may be executed in that context. Calling
    CommitAsync()
    or

    RollbackAsync()
    will then close the transaction and thus, the session. This feature only works with

    transaction enabled graphs.

    Inheritance
    System.Object
    RemoteTransaction
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ToString()
    System.Object.ReferenceEquals(System.Object, System.Object)
    Namespace: Gremlin.Net.Process.Remote
    Assembly: cs.temp.dll.dll
    Syntax
    public class RemoteTransaction

    Constructors

    RemoteTransaction(IRemoteConnection, GraphTraversalSource)

    Initializes a new instance of the RemoteTransaction class.

    Declaration
    public RemoteTransaction(IRemoteConnection connection, GraphTraversalSource g)
    Parameters
    Type Name Description
    IRemoteConnection connection

    The session bound connection that will be used to control this transaction.

    GraphTraversalSource g

    The graph traversal source from which a session bound traversal source will be created.

    Methods

    Begin()

    Spawns a that is bound to a remote session which enables a transaction.

    Declaration
    public GraphTraversalSource Begin()
    Returns
    Type Description
    GraphTraversalSource

    A bound to a remote session.

    Exceptions
    Type Condition
    System.InvalidOperationException

    Thrown if this transaction is already bound to a session.

    CommitAsync()

    Commits the transaction.

    Declaration
    public async Task CommitAsync()
    Returns
    Type Description
    System.Threading.Tasks.Task

    RollbackAsync()

    Rolls back the transaction.

    Declaration
    public async Task RollbackAsync()
    Returns
    Type Description
    System.Threading.Tasks.Task
    In This Article
    Back to top Copyright © 2018 The Apache Software Foundation