Class TXNGrpc.TXNFutureStub

java.lang.Object
io.grpc.stub.AbstractStub<S>
io.grpc.stub.AbstractFutureStub<TXNGrpc.TXNFutureStub>
org.vitrivr.cottontail.grpc.TXNGrpc.TXNFutureStub
Enclosing class:
TXNGrpc

public static final class TXNGrpc.TXNFutureStub extends io.grpc.stub.AbstractFutureStub<TXNGrpc.TXNFutureStub>
A stub to allow clients to do ListenableFuture-style rpc calls to service TXN.

 Endpoint for transaction management.
 
  • Nested Class Summary

    Nested classes/interfaces inherited from class io.grpc.stub.AbstractStub

    io.grpc.stub.AbstractStub.StubFactory<T extends io.grpc.stub.AbstractStub<T>>
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
    TXNFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    com.google.common.util.concurrent.ListenableFuture<CottontailGrpc.ResponseMetadata>
    Starts a new transaction.
    build(io.grpc.Channel channel, io.grpc.CallOptions callOptions)
     
    com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty>
    Performs a commit on a transaction.
    com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty>
    Kills and performs a rollback on an ongoing transaction.
    com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty>
    Performs a rollback on a transaction and aborts it.

    Methods inherited from class io.grpc.stub.AbstractFutureStub

    newStub, newStub

    Methods inherited from class io.grpc.stub.AbstractStub

    getCallOptions, getChannel, withCallCredentials, withChannel, withCompression, withDeadline, withDeadlineAfter, withExecutor, withInterceptors, withMaxInboundMessageSize, withMaxOutboundMessageSize, withOption, withWaitForReady

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • TXNFutureStub

      private TXNFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions)
  • Method Details

    • build

      protected TXNGrpc.TXNFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions)
      Specified by:
      build in class io.grpc.stub.AbstractStub<TXNGrpc.TXNFutureStub>
    • begin

      public com.google.common.util.concurrent.ListenableFuture<CottontailGrpc.ResponseMetadata> begin(CottontailGrpc.BeginTransaction request)
       Starts a new transaction. 
       
    • commit

      public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty> commit(CottontailGrpc.RequestMetadata request)
       Performs a commit on a transaction. This method blocks if a query is currently executed. 
       
    • rollback

      public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty> rollback(CottontailGrpc.RequestMetadata request)
       Performs a rollback on a transaction and aborts it. This method blocks if a query is currently executed. 
       
    • kill

      public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty> kill(CottontailGrpc.RequestMetadata request)
       Kills and performs a rollback on an ongoing transaction. This method can even be used when a query is being executed.