Documentation
¶
Index ¶
- Variables
- func RegisterDistributedTxServiceServer(s grpc.ServiceRegistrar, srv DistributedTxServiceServer)
- type DistributedTxServiceClient
- type DistributedTxServiceServer
- type TxResponse
- type TxToCommit
- type TxToRollback
- type UnimplementedDistributedTxServiceServer
- type UnsafeDistributedTxServiceServer
Constants ¶
This section is empty.
Variables ¶
var DistributedTxService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "DistributedTxService", HandlerType: (*DistributedTxServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Commit", Handler: _DistributedTxService_Commit_Handler, }, { MethodName: "Rollback", Handler: _DistributedTxService_Rollback_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "proto/distributedTx.proto", }
DistributedTxService_ServiceDesc is the grpc.ServiceDesc for DistributedTxService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_proto_distributedTx_proto protoreflect.FileDescriptor
Functions ¶
func RegisterDistributedTxServiceServer ¶
func RegisterDistributedTxServiceServer(s grpc.ServiceRegistrar, srv DistributedTxServiceServer)
Types ¶
type DistributedTxServiceClient ¶
type DistributedTxServiceClient interface { Commit(ctx context.Context, in *TxToCommit, opts ...grpc.CallOption) (*TxResponse, error) Rollback(ctx context.Context, in *TxToRollback, opts ...grpc.CallOption) (*TxResponse, error) }
DistributedTxServiceClient is the client API for DistributedTxService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewDistributedTxServiceClient ¶
func NewDistributedTxServiceClient(cc grpc.ClientConnInterface) DistributedTxServiceClient
type DistributedTxServiceServer ¶
type DistributedTxServiceServer interface { Commit(context.Context, *TxToCommit) (*TxResponse, error) Rollback(context.Context, *TxToRollback) (*TxResponse, error) // contains filtered or unexported methods }
DistributedTxServiceServer is the server API for DistributedTxService service. All implementations must embed UnimplementedDistributedTxServiceServer for forward compatibility
type TxResponse ¶
type TxResponse struct {
// contains filtered or unexported fields
}
func (*TxResponse) Descriptor
deprecated
func (*TxResponse) Descriptor() ([]byte, []int)
Deprecated: Use TxResponse.ProtoReflect.Descriptor instead.
func (*TxResponse) ProtoMessage ¶
func (*TxResponse) ProtoMessage()
func (*TxResponse) ProtoReflect ¶
func (x *TxResponse) ProtoReflect() protoreflect.Message
func (*TxResponse) Reset ¶
func (x *TxResponse) Reset()
func (*TxResponse) String ¶
func (x *TxResponse) String() string
type TxToCommit ¶
type TxToCommit struct { TxId string `protobuf:"bytes,1,opt,name=tx_id,json=txId,proto3" json:"tx_id,omitempty"` // contains filtered or unexported fields }
func (*TxToCommit) Descriptor
deprecated
func (*TxToCommit) Descriptor() ([]byte, []int)
Deprecated: Use TxToCommit.ProtoReflect.Descriptor instead.
func (*TxToCommit) GetTxId ¶
func (x *TxToCommit) GetTxId() string
func (*TxToCommit) ProtoMessage ¶
func (*TxToCommit) ProtoMessage()
func (*TxToCommit) ProtoReflect ¶
func (x *TxToCommit) ProtoReflect() protoreflect.Message
func (*TxToCommit) Reset ¶
func (x *TxToCommit) Reset()
func (*TxToCommit) String ¶
func (x *TxToCommit) String() string
type TxToRollback ¶
type TxToRollback struct { TxId string `protobuf:"bytes,1,opt,name=tx_id,json=txId,proto3" json:"tx_id,omitempty"` // contains filtered or unexported fields }
func (*TxToRollback) Descriptor
deprecated
func (*TxToRollback) Descriptor() ([]byte, []int)
Deprecated: Use TxToRollback.ProtoReflect.Descriptor instead.
func (*TxToRollback) GetTxId ¶
func (x *TxToRollback) GetTxId() string
func (*TxToRollback) ProtoMessage ¶
func (*TxToRollback) ProtoMessage()
func (*TxToRollback) ProtoReflect ¶
func (x *TxToRollback) ProtoReflect() protoreflect.Message
func (*TxToRollback) Reset ¶
func (x *TxToRollback) Reset()
func (*TxToRollback) String ¶
func (x *TxToRollback) String() string
type UnimplementedDistributedTxServiceServer ¶
type UnimplementedDistributedTxServiceServer struct { }
UnimplementedDistributedTxServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedDistributedTxServiceServer) Commit ¶
func (UnimplementedDistributedTxServiceServer) Commit(context.Context, *TxToCommit) (*TxResponse, error)
func (UnimplementedDistributedTxServiceServer) Rollback ¶
func (UnimplementedDistributedTxServiceServer) Rollback(context.Context, *TxToRollback) (*TxResponse, error)
type UnsafeDistributedTxServiceServer ¶
type UnsafeDistributedTxServiceServer interface {
// contains filtered or unexported methods
}
UnsafeDistributedTxServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to DistributedTxServiceServer will result in compilation errors.