Documentation ¶
Index ¶
- func RegisterQueryServer(s *grpc.Server, srv QueryServer)
- type QueryClient
- type QueryServer
- type Query_MessageStreamClient
- type Query_MessageStreamServer
- type Query_StreamExecuteClient
- type Query_StreamExecuteServer
- type Query_StreamHealthClient
- type Query_StreamHealthServer
- type Query_VStreamClient
- type Query_VStreamResultsClient
- type Query_VStreamResultsServer
- type Query_VStreamRowsClient
- type Query_VStreamRowsServer
- type Query_VStreamServer
- type UnimplementedQueryServer
- func (*UnimplementedQueryServer) Begin(ctx context.Context, req *query.BeginRequest) (*query.BeginResponse, error)
- func (*UnimplementedQueryServer) BeginExecute(ctx context.Context, req *query.BeginExecuteRequest) (*query.BeginExecuteResponse, error)
- func (*UnimplementedQueryServer) BeginExecuteBatch(ctx context.Context, req *query.BeginExecuteBatchRequest) (*query.BeginExecuteBatchResponse, error)
- func (*UnimplementedQueryServer) Commit(ctx context.Context, req *query.CommitRequest) (*query.CommitResponse, error)
- func (*UnimplementedQueryServer) CommitPrepared(ctx context.Context, req *query.CommitPreparedRequest) (*query.CommitPreparedResponse, error)
- func (*UnimplementedQueryServer) ConcludeTransaction(ctx context.Context, req *query.ConcludeTransactionRequest) (*query.ConcludeTransactionResponse, error)
- func (*UnimplementedQueryServer) CreateTransaction(ctx context.Context, req *query.CreateTransactionRequest) (*query.CreateTransactionResponse, error)
- func (*UnimplementedQueryServer) Execute(ctx context.Context, req *query.ExecuteRequest) (*query.ExecuteResponse, error)
- func (*UnimplementedQueryServer) ExecuteBatch(ctx context.Context, req *query.ExecuteBatchRequest) (*query.ExecuteBatchResponse, error)
- func (*UnimplementedQueryServer) MessageAck(ctx context.Context, req *query.MessageAckRequest) (*query.MessageAckResponse, error)
- func (*UnimplementedQueryServer) MessageStream(req *query.MessageStreamRequest, srv Query_MessageStreamServer) error
- func (*UnimplementedQueryServer) Prepare(ctx context.Context, req *query.PrepareRequest) (*query.PrepareResponse, error)
- func (*UnimplementedQueryServer) ReadTransaction(ctx context.Context, req *query.ReadTransactionRequest) (*query.ReadTransactionResponse, error)
- func (*UnimplementedQueryServer) Rollback(ctx context.Context, req *query.RollbackRequest) (*query.RollbackResponse, error)
- func (*UnimplementedQueryServer) RollbackPrepared(ctx context.Context, req *query.RollbackPreparedRequest) (*query.RollbackPreparedResponse, error)
- func (*UnimplementedQueryServer) SetRollback(ctx context.Context, req *query.SetRollbackRequest) (*query.SetRollbackResponse, error)
- func (*UnimplementedQueryServer) StartCommit(ctx context.Context, req *query.StartCommitRequest) (*query.StartCommitResponse, error)
- func (*UnimplementedQueryServer) StreamExecute(req *query.StreamExecuteRequest, srv Query_StreamExecuteServer) error
- func (*UnimplementedQueryServer) StreamHealth(req *query.StreamHealthRequest, srv Query_StreamHealthServer) error
- func (*UnimplementedQueryServer) VStream(req *binlogdata.VStreamRequest, srv Query_VStreamServer) error
- func (*UnimplementedQueryServer) VStreamResults(req *binlogdata.VStreamResultsRequest, srv Query_VStreamResultsServer) error
- func (*UnimplementedQueryServer) VStreamRows(req *binlogdata.VStreamRowsRequest, srv Query_VStreamRowsServer) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterQueryServer ¶
func RegisterQueryServer(s *grpc.Server, srv QueryServer)
Types ¶
type QueryClient ¶
type QueryClient interface { // Execute executes the specified SQL query (might be in a // transaction context, if Query.transaction_id is set). Execute(ctx context.Context, in *query.ExecuteRequest, opts ...grpc.CallOption) (*query.ExecuteResponse, error) // ExecuteBatch executes a list of queries, and returns the result // for each query. ExecuteBatch(ctx context.Context, in *query.ExecuteBatchRequest, opts ...grpc.CallOption) (*query.ExecuteBatchResponse, error) // StreamExecute executes a streaming query. Use this method if the // query returns a large number of rows. The first QueryResult will // contain the Fields, subsequent QueryResult messages will contain // the rows. StreamExecute(ctx context.Context, in *query.StreamExecuteRequest, opts ...grpc.CallOption) (Query_StreamExecuteClient, error) // Begin a transaction. Begin(ctx context.Context, in *query.BeginRequest, opts ...grpc.CallOption) (*query.BeginResponse, error) // Commit a transaction. Commit(ctx context.Context, in *query.CommitRequest, opts ...grpc.CallOption) (*query.CommitResponse, error) // Rollback a transaction. Rollback(ctx context.Context, in *query.RollbackRequest, opts ...grpc.CallOption) (*query.RollbackResponse, error) // Prepare preares a transaction. Prepare(ctx context.Context, in *query.PrepareRequest, opts ...grpc.CallOption) (*query.PrepareResponse, error) // CommitPrepared commits a prepared transaction. CommitPrepared(ctx context.Context, in *query.CommitPreparedRequest, opts ...grpc.CallOption) (*query.CommitPreparedResponse, error) // RollbackPrepared rolls back a prepared transaction. RollbackPrepared(ctx context.Context, in *query.RollbackPreparedRequest, opts ...grpc.CallOption) (*query.RollbackPreparedResponse, error) // CreateTransaction creates the metadata for a 2pc transaction. CreateTransaction(ctx context.Context, in *query.CreateTransactionRequest, opts ...grpc.CallOption) (*query.CreateTransactionResponse, error) // StartCommit initiates a commit for a 2pc transaction. StartCommit(ctx context.Context, in *query.StartCommitRequest, opts ...grpc.CallOption) (*query.StartCommitResponse, error) // SetRollback marks the 2pc transaction for rollback. SetRollback(ctx context.Context, in *query.SetRollbackRequest, opts ...grpc.CallOption) (*query.SetRollbackResponse, error) // ConcludeTransaction marks the 2pc transaction as resolved. ConcludeTransaction(ctx context.Context, in *query.ConcludeTransactionRequest, opts ...grpc.CallOption) (*query.ConcludeTransactionResponse, error) // ReadTransaction returns the 2pc transaction info. ReadTransaction(ctx context.Context, in *query.ReadTransactionRequest, opts ...grpc.CallOption) (*query.ReadTransactionResponse, error) // BeginExecute executes a begin and the specified SQL query. BeginExecute(ctx context.Context, in *query.BeginExecuteRequest, opts ...grpc.CallOption) (*query.BeginExecuteResponse, error) // BeginExecuteBatch executes a begin and a list of queries. BeginExecuteBatch(ctx context.Context, in *query.BeginExecuteBatchRequest, opts ...grpc.CallOption) (*query.BeginExecuteBatchResponse, error) // MessageStream streams messages from a message table. MessageStream(ctx context.Context, in *query.MessageStreamRequest, opts ...grpc.CallOption) (Query_MessageStreamClient, error) // MessageAck acks messages for a table. MessageAck(ctx context.Context, in *query.MessageAckRequest, opts ...grpc.CallOption) (*query.MessageAckResponse, error) // StreamHealth runs a streaming RPC to the tablet, that returns the // current health of the tablet on a regular basis. StreamHealth(ctx context.Context, in *query.StreamHealthRequest, opts ...grpc.CallOption) (Query_StreamHealthClient, error) // VStream streams vreplication events. VStream(ctx context.Context, in *binlogdata.VStreamRequest, opts ...grpc.CallOption) (Query_VStreamClient, error) // VStreamRows streams rows from the specified starting point. VStreamRows(ctx context.Context, in *binlogdata.VStreamRowsRequest, opts ...grpc.CallOption) (Query_VStreamRowsClient, error) // VStreamResults streams results along with the gtid of the snapshot. VStreamResults(ctx context.Context, in *binlogdata.VStreamResultsRequest, opts ...grpc.CallOption) (Query_VStreamResultsClient, error) }
QueryClient is the client API for Query service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewQueryClient ¶
func NewQueryClient(cc *grpc.ClientConn) QueryClient
type QueryServer ¶
type QueryServer interface { // Execute executes the specified SQL query (might be in a // transaction context, if Query.transaction_id is set). Execute(context.Context, *query.ExecuteRequest) (*query.ExecuteResponse, error) // ExecuteBatch executes a list of queries, and returns the result // for each query. ExecuteBatch(context.Context, *query.ExecuteBatchRequest) (*query.ExecuteBatchResponse, error) // StreamExecute executes a streaming query. Use this method if the // query returns a large number of rows. The first QueryResult will // contain the Fields, subsequent QueryResult messages will contain // the rows. StreamExecute(*query.StreamExecuteRequest, Query_StreamExecuteServer) error // Begin a transaction. Begin(context.Context, *query.BeginRequest) (*query.BeginResponse, error) // Commit a transaction. Commit(context.Context, *query.CommitRequest) (*query.CommitResponse, error) // Rollback a transaction. Rollback(context.Context, *query.RollbackRequest) (*query.RollbackResponse, error) // Prepare preares a transaction. Prepare(context.Context, *query.PrepareRequest) (*query.PrepareResponse, error) // CommitPrepared commits a prepared transaction. CommitPrepared(context.Context, *query.CommitPreparedRequest) (*query.CommitPreparedResponse, error) // RollbackPrepared rolls back a prepared transaction. RollbackPrepared(context.Context, *query.RollbackPreparedRequest) (*query.RollbackPreparedResponse, error) // CreateTransaction creates the metadata for a 2pc transaction. CreateTransaction(context.Context, *query.CreateTransactionRequest) (*query.CreateTransactionResponse, error) // StartCommit initiates a commit for a 2pc transaction. StartCommit(context.Context, *query.StartCommitRequest) (*query.StartCommitResponse, error) // SetRollback marks the 2pc transaction for rollback. SetRollback(context.Context, *query.SetRollbackRequest) (*query.SetRollbackResponse, error) // ConcludeTransaction marks the 2pc transaction as resolved. ConcludeTransaction(context.Context, *query.ConcludeTransactionRequest) (*query.ConcludeTransactionResponse, error) // ReadTransaction returns the 2pc transaction info. ReadTransaction(context.Context, *query.ReadTransactionRequest) (*query.ReadTransactionResponse, error) // BeginExecute executes a begin and the specified SQL query. BeginExecute(context.Context, *query.BeginExecuteRequest) (*query.BeginExecuteResponse, error) // BeginExecuteBatch executes a begin and a list of queries. BeginExecuteBatch(context.Context, *query.BeginExecuteBatchRequest) (*query.BeginExecuteBatchResponse, error) // MessageStream streams messages from a message table. MessageStream(*query.MessageStreamRequest, Query_MessageStreamServer) error // MessageAck acks messages for a table. MessageAck(context.Context, *query.MessageAckRequest) (*query.MessageAckResponse, error) // StreamHealth runs a streaming RPC to the tablet, that returns the // current health of the tablet on a regular basis. StreamHealth(*query.StreamHealthRequest, Query_StreamHealthServer) error // VStream streams vreplication events. VStream(*binlogdata.VStreamRequest, Query_VStreamServer) error // VStreamRows streams rows from the specified starting point. VStreamRows(*binlogdata.VStreamRowsRequest, Query_VStreamRowsServer) error // VStreamResults streams results along with the gtid of the snapshot. VStreamResults(*binlogdata.VStreamResultsRequest, Query_VStreamResultsServer) error }
QueryServer is the server API for Query service.
type Query_MessageStreamClient ¶
type Query_MessageStreamClient interface { Recv() (*query.MessageStreamResponse, error) grpc.ClientStream }
type Query_MessageStreamServer ¶
type Query_MessageStreamServer interface { Send(*query.MessageStreamResponse) error grpc.ServerStream }
type Query_StreamExecuteClient ¶
type Query_StreamExecuteClient interface { Recv() (*query.StreamExecuteResponse, error) grpc.ClientStream }
type Query_StreamExecuteServer ¶
type Query_StreamExecuteServer interface { Send(*query.StreamExecuteResponse) error grpc.ServerStream }
type Query_StreamHealthClient ¶
type Query_StreamHealthClient interface { Recv() (*query.StreamHealthResponse, error) grpc.ClientStream }
type Query_StreamHealthServer ¶
type Query_StreamHealthServer interface { Send(*query.StreamHealthResponse) error grpc.ServerStream }
type Query_VStreamClient ¶
type Query_VStreamClient interface { Recv() (*binlogdata.VStreamResponse, error) grpc.ClientStream }
type Query_VStreamResultsClient ¶
type Query_VStreamResultsClient interface { Recv() (*binlogdata.VStreamResultsResponse, error) grpc.ClientStream }
type Query_VStreamResultsServer ¶
type Query_VStreamResultsServer interface { Send(*binlogdata.VStreamResultsResponse) error grpc.ServerStream }
type Query_VStreamRowsClient ¶
type Query_VStreamRowsClient interface { Recv() (*binlogdata.VStreamRowsResponse, error) grpc.ClientStream }
type Query_VStreamRowsServer ¶
type Query_VStreamRowsServer interface { Send(*binlogdata.VStreamRowsResponse) error grpc.ServerStream }
type Query_VStreamServer ¶
type Query_VStreamServer interface { Send(*binlogdata.VStreamResponse) error grpc.ServerStream }
type UnimplementedQueryServer ¶
type UnimplementedQueryServer struct { }
UnimplementedQueryServer can be embedded to have forward compatible implementations.
func (*UnimplementedQueryServer) Begin ¶
func (*UnimplementedQueryServer) Begin(ctx context.Context, req *query.BeginRequest) (*query.BeginResponse, error)
func (*UnimplementedQueryServer) BeginExecute ¶
func (*UnimplementedQueryServer) BeginExecute(ctx context.Context, req *query.BeginExecuteRequest) (*query.BeginExecuteResponse, error)
func (*UnimplementedQueryServer) BeginExecuteBatch ¶
func (*UnimplementedQueryServer) BeginExecuteBatch(ctx context.Context, req *query.BeginExecuteBatchRequest) (*query.BeginExecuteBatchResponse, error)
func (*UnimplementedQueryServer) Commit ¶
func (*UnimplementedQueryServer) Commit(ctx context.Context, req *query.CommitRequest) (*query.CommitResponse, error)
func (*UnimplementedQueryServer) CommitPrepared ¶
func (*UnimplementedQueryServer) CommitPrepared(ctx context.Context, req *query.CommitPreparedRequest) (*query.CommitPreparedResponse, error)
func (*UnimplementedQueryServer) ConcludeTransaction ¶
func (*UnimplementedQueryServer) ConcludeTransaction(ctx context.Context, req *query.ConcludeTransactionRequest) (*query.ConcludeTransactionResponse, error)
func (*UnimplementedQueryServer) CreateTransaction ¶
func (*UnimplementedQueryServer) CreateTransaction(ctx context.Context, req *query.CreateTransactionRequest) (*query.CreateTransactionResponse, error)
func (*UnimplementedQueryServer) Execute ¶
func (*UnimplementedQueryServer) Execute(ctx context.Context, req *query.ExecuteRequest) (*query.ExecuteResponse, error)
func (*UnimplementedQueryServer) ExecuteBatch ¶
func (*UnimplementedQueryServer) ExecuteBatch(ctx context.Context, req *query.ExecuteBatchRequest) (*query.ExecuteBatchResponse, error)
func (*UnimplementedQueryServer) MessageAck ¶
func (*UnimplementedQueryServer) MessageAck(ctx context.Context, req *query.MessageAckRequest) (*query.MessageAckResponse, error)
func (*UnimplementedQueryServer) MessageStream ¶
func (*UnimplementedQueryServer) MessageStream(req *query.MessageStreamRequest, srv Query_MessageStreamServer) error
func (*UnimplementedQueryServer) Prepare ¶
func (*UnimplementedQueryServer) Prepare(ctx context.Context, req *query.PrepareRequest) (*query.PrepareResponse, error)
func (*UnimplementedQueryServer) ReadTransaction ¶
func (*UnimplementedQueryServer) ReadTransaction(ctx context.Context, req *query.ReadTransactionRequest) (*query.ReadTransactionResponse, error)
func (*UnimplementedQueryServer) Rollback ¶
func (*UnimplementedQueryServer) Rollback(ctx context.Context, req *query.RollbackRequest) (*query.RollbackResponse, error)
func (*UnimplementedQueryServer) RollbackPrepared ¶
func (*UnimplementedQueryServer) RollbackPrepared(ctx context.Context, req *query.RollbackPreparedRequest) (*query.RollbackPreparedResponse, error)
func (*UnimplementedQueryServer) SetRollback ¶
func (*UnimplementedQueryServer) SetRollback(ctx context.Context, req *query.SetRollbackRequest) (*query.SetRollbackResponse, error)
func (*UnimplementedQueryServer) StartCommit ¶
func (*UnimplementedQueryServer) StartCommit(ctx context.Context, req *query.StartCommitRequest) (*query.StartCommitResponse, error)
func (*UnimplementedQueryServer) StreamExecute ¶
func (*UnimplementedQueryServer) StreamExecute(req *query.StreamExecuteRequest, srv Query_StreamExecuteServer) error
func (*UnimplementedQueryServer) StreamHealth ¶
func (*UnimplementedQueryServer) StreamHealth(req *query.StreamHealthRequest, srv Query_StreamHealthServer) error
func (*UnimplementedQueryServer) VStream ¶
func (*UnimplementedQueryServer) VStream(req *binlogdata.VStreamRequest, srv Query_VStreamServer) error
func (*UnimplementedQueryServer) VStreamResults ¶
func (*UnimplementedQueryServer) VStreamResults(req *binlogdata.VStreamResultsRequest, srv Query_VStreamResultsServer) error
func (*UnimplementedQueryServer) VStreamRows ¶
func (*UnimplementedQueryServer) VStreamRows(req *binlogdata.VStreamRowsRequest, srv Query_VStreamRowsServer) error
Click to show internal directories.
Click to hide internal directories.