зеркало из https://github.com/github/vitess-gh.git
2pc (#2153)
2pc: export grpc functions * govet issue: call cancel funcs from contexts. * Export 2PC functions as gRPC methods
This commit is contained in:
Родитель
354fcd2c35
Коммит
92c1dca28f
|
@ -381,6 +381,54 @@ func (itc *internalTabletConn) Rollback(ctx context.Context, target *querypb.Tar
|
|||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// Prepare is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) error {
|
||||
err := itc.tablet.qsc.QueryService().Prepare(ctx, target, transactionID, dtid)
|
||||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// CommitPrepared is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) error {
|
||||
err := itc.tablet.qsc.QueryService().CommitPrepared(ctx, target, dtid)
|
||||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// RollbackPrepared is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) error {
|
||||
err := itc.tablet.qsc.QueryService().RollbackPrepared(ctx, target, dtid, originalID)
|
||||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// CreateTransaction is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) error {
|
||||
err := itc.tablet.qsc.QueryService().CreateTransaction(ctx, target, dtid, participants)
|
||||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// StartCommit is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) error {
|
||||
err := itc.tablet.qsc.QueryService().StartCommit(ctx, target, transactionID, dtid)
|
||||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// SetRollback is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) error {
|
||||
err := itc.tablet.qsc.QueryService().SetRollback(ctx, target, dtid, transactionID)
|
||||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// ResolveTransaction is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) error {
|
||||
err := itc.tablet.qsc.QueryService().ResolveTransaction(ctx, target, dtid)
|
||||
return tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// ReadTransaction is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
metadata, err = itc.tablet.qsc.QueryService().ReadTransaction(ctx, target, dtid)
|
||||
return metadata, tabletconn.TabletErrorFromGRPC(vterrors.ToGRPCError(err))
|
||||
}
|
||||
|
||||
// BeginExecute is part of tabletconn.TabletConn
|
||||
func (itc *internalTabletConn) BeginExecute(ctx context.Context, target *querypb.Target, query string, bindVars map[string]interface{}, options *querypb.ExecuteOptions) (*sqltypes.Result, int64, error) {
|
||||
transactionID, err := itc.Begin(ctx, target)
|
||||
|
|
|
@ -483,6 +483,46 @@ func (fc *fakeConn) Rollback(ctx context.Context, target *querypb.Target, transa
|
|||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// Prepare implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// CommitPrepared implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// RollbackPrepared implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error) {
|
||||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// CreateTransaction implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error) {
|
||||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// StartCommit implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// SetRollback implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error) {
|
||||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// ResolveTransaction implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// ReadTransaction implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
return nil, fmt.Errorf("not implemented")
|
||||
}
|
||||
|
||||
// BeginExecute implements tabletconn.TabletConn.
|
||||
func (fc *fakeConn) BeginExecute(ctx context.Context, target *querypb.Target, query string, bindVars map[string]interface{}, options *querypb.ExecuteOptions) (*sqltypes.Result, int64, error) {
|
||||
return nil, 0, fmt.Errorf("not implemented")
|
||||
|
|
|
@ -33,6 +33,22 @@ It has these top-level messages:
|
|||
CommitResponse
|
||||
RollbackRequest
|
||||
RollbackResponse
|
||||
PrepareRequest
|
||||
PrepareResponse
|
||||
CommitPreparedRequest
|
||||
CommitPreparedResponse
|
||||
RollbackPreparedRequest
|
||||
RollbackPreparedResponse
|
||||
CreateTransactionRequest
|
||||
CreateTransactionResponse
|
||||
StartCommitRequest
|
||||
StartCommitResponse
|
||||
SetRollbackRequest
|
||||
SetRollbackResponse
|
||||
ResolveTransactionRequest
|
||||
ResolveTransactionResponse
|
||||
ReadTransactionRequest
|
||||
ReadTransactionResponse
|
||||
BeginExecuteRequest
|
||||
BeginExecuteResponse
|
||||
BeginExecuteBatchRequest
|
||||
|
@ -341,7 +357,7 @@ func (x SplitQueryRequest_Algorithm) String() string {
|
|||
return proto.EnumName(SplitQueryRequest_Algorithm_name, int32(x))
|
||||
}
|
||||
func (SplitQueryRequest_Algorithm) EnumDescriptor() ([]byte, []int) {
|
||||
return fileDescriptor0, []int{28, 0}
|
||||
return fileDescriptor0, []int{44, 0}
|
||||
}
|
||||
|
||||
// Target describes what the client expects the tablet is.
|
||||
|
@ -956,6 +972,370 @@ func (m *RollbackResponse) String() string { return proto.CompactText
|
|||
func (*RollbackResponse) ProtoMessage() {}
|
||||
func (*RollbackResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{23} }
|
||||
|
||||
// PrepareRequest is the payload to Prepare
|
||||
type PrepareRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
TransactionId int64 `protobuf:"varint,4,opt,name=transaction_id,json=transactionId" json:"transaction_id,omitempty"`
|
||||
Dtid string `protobuf:"bytes,5,opt,name=dtid" json:"dtid,omitempty"`
|
||||
}
|
||||
|
||||
func (m *PrepareRequest) Reset() { *m = PrepareRequest{} }
|
||||
func (m *PrepareRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*PrepareRequest) ProtoMessage() {}
|
||||
func (*PrepareRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{24} }
|
||||
|
||||
func (m *PrepareRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *PrepareRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *PrepareRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// PrepareResponse is the returned value from Prepare
|
||||
type PrepareResponse struct {
|
||||
}
|
||||
|
||||
func (m *PrepareResponse) Reset() { *m = PrepareResponse{} }
|
||||
func (m *PrepareResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*PrepareResponse) ProtoMessage() {}
|
||||
func (*PrepareResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{25} }
|
||||
|
||||
// CommitPreparedRequest is the payload to CommitPrepared
|
||||
type CommitPreparedRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
Dtid string `protobuf:"bytes,4,opt,name=dtid" json:"dtid,omitempty"`
|
||||
}
|
||||
|
||||
func (m *CommitPreparedRequest) Reset() { *m = CommitPreparedRequest{} }
|
||||
func (m *CommitPreparedRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*CommitPreparedRequest) ProtoMessage() {}
|
||||
func (*CommitPreparedRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{26} }
|
||||
|
||||
func (m *CommitPreparedRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *CommitPreparedRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *CommitPreparedRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// CommitPreparedResponse is the returned value from CommitPrepared
|
||||
type CommitPreparedResponse struct {
|
||||
}
|
||||
|
||||
func (m *CommitPreparedResponse) Reset() { *m = CommitPreparedResponse{} }
|
||||
func (m *CommitPreparedResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*CommitPreparedResponse) ProtoMessage() {}
|
||||
func (*CommitPreparedResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{27} }
|
||||
|
||||
// RollbackPreparedRequest is the payload to RollbackPrepared
|
||||
type RollbackPreparedRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
TransactionId int64 `protobuf:"varint,4,opt,name=transaction_id,json=transactionId" json:"transaction_id,omitempty"`
|
||||
Dtid string `protobuf:"bytes,5,opt,name=dtid" json:"dtid,omitempty"`
|
||||
}
|
||||
|
||||
func (m *RollbackPreparedRequest) Reset() { *m = RollbackPreparedRequest{} }
|
||||
func (m *RollbackPreparedRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*RollbackPreparedRequest) ProtoMessage() {}
|
||||
func (*RollbackPreparedRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{28} }
|
||||
|
||||
func (m *RollbackPreparedRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *RollbackPreparedRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *RollbackPreparedRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RollbackPreparedResponse is the returned value from RollbackPrepared
|
||||
type RollbackPreparedResponse struct {
|
||||
}
|
||||
|
||||
func (m *RollbackPreparedResponse) Reset() { *m = RollbackPreparedResponse{} }
|
||||
func (m *RollbackPreparedResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*RollbackPreparedResponse) ProtoMessage() {}
|
||||
func (*RollbackPreparedResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{29} }
|
||||
|
||||
// CreateTransactionRequest is the payload to CreateTransaction
|
||||
type CreateTransactionRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
Dtid string `protobuf:"bytes,4,opt,name=dtid" json:"dtid,omitempty"`
|
||||
Participants []*Target `protobuf:"bytes,5,rep,name=participants" json:"participants,omitempty"`
|
||||
}
|
||||
|
||||
func (m *CreateTransactionRequest) Reset() { *m = CreateTransactionRequest{} }
|
||||
func (m *CreateTransactionRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*CreateTransactionRequest) ProtoMessage() {}
|
||||
func (*CreateTransactionRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{30} }
|
||||
|
||||
func (m *CreateTransactionRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *CreateTransactionRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *CreateTransactionRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *CreateTransactionRequest) GetParticipants() []*Target {
|
||||
if m != nil {
|
||||
return m.Participants
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// CreateTransactionResponse is the returned value from CreateTransaction
|
||||
type CreateTransactionResponse struct {
|
||||
}
|
||||
|
||||
func (m *CreateTransactionResponse) Reset() { *m = CreateTransactionResponse{} }
|
||||
func (m *CreateTransactionResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*CreateTransactionResponse) ProtoMessage() {}
|
||||
func (*CreateTransactionResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{31} }
|
||||
|
||||
// StartCommitRequest is the payload to StartCommit
|
||||
type StartCommitRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
TransactionId int64 `protobuf:"varint,4,opt,name=transaction_id,json=transactionId" json:"transaction_id,omitempty"`
|
||||
Dtid string `protobuf:"bytes,5,opt,name=dtid" json:"dtid,omitempty"`
|
||||
}
|
||||
|
||||
func (m *StartCommitRequest) Reset() { *m = StartCommitRequest{} }
|
||||
func (m *StartCommitRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*StartCommitRequest) ProtoMessage() {}
|
||||
func (*StartCommitRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{32} }
|
||||
|
||||
func (m *StartCommitRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *StartCommitRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *StartCommitRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// StartCommitResponse is the returned value from StartCommit
|
||||
type StartCommitResponse struct {
|
||||
}
|
||||
|
||||
func (m *StartCommitResponse) Reset() { *m = StartCommitResponse{} }
|
||||
func (m *StartCommitResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*StartCommitResponse) ProtoMessage() {}
|
||||
func (*StartCommitResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{33} }
|
||||
|
||||
// SetRollbackRequest is the payload to SetRollback
|
||||
type SetRollbackRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
TransactionId int64 `protobuf:"varint,4,opt,name=transaction_id,json=transactionId" json:"transaction_id,omitempty"`
|
||||
Dtid string `protobuf:"bytes,5,opt,name=dtid" json:"dtid,omitempty"`
|
||||
}
|
||||
|
||||
func (m *SetRollbackRequest) Reset() { *m = SetRollbackRequest{} }
|
||||
func (m *SetRollbackRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*SetRollbackRequest) ProtoMessage() {}
|
||||
func (*SetRollbackRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{34} }
|
||||
|
||||
func (m *SetRollbackRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *SetRollbackRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *SetRollbackRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// SetRollbackResponse is the returned value from SetRollback
|
||||
type SetRollbackResponse struct {
|
||||
}
|
||||
|
||||
func (m *SetRollbackResponse) Reset() { *m = SetRollbackResponse{} }
|
||||
func (m *SetRollbackResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*SetRollbackResponse) ProtoMessage() {}
|
||||
func (*SetRollbackResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{35} }
|
||||
|
||||
// ResolveTransactionRequest is the payload to ResolveTransaction
|
||||
type ResolveTransactionRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
Dtid string `protobuf:"bytes,4,opt,name=dtid" json:"dtid,omitempty"`
|
||||
}
|
||||
|
||||
func (m *ResolveTransactionRequest) Reset() { *m = ResolveTransactionRequest{} }
|
||||
func (m *ResolveTransactionRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*ResolveTransactionRequest) ProtoMessage() {}
|
||||
func (*ResolveTransactionRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{36} }
|
||||
|
||||
func (m *ResolveTransactionRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *ResolveTransactionRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *ResolveTransactionRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// ResolveTransactionResponse is the returned value from ResolveTransaction
|
||||
type ResolveTransactionResponse struct {
|
||||
}
|
||||
|
||||
func (m *ResolveTransactionResponse) Reset() { *m = ResolveTransactionResponse{} }
|
||||
func (m *ResolveTransactionResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*ResolveTransactionResponse) ProtoMessage() {}
|
||||
func (*ResolveTransactionResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{37} }
|
||||
|
||||
// ReadTransactionRequest is the payload to ReadTransaction
|
||||
type ReadTransactionRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
ImmediateCallerId *VTGateCallerID `protobuf:"bytes,2,opt,name=immediate_caller_id,json=immediateCallerId" json:"immediate_caller_id,omitempty"`
|
||||
Target *Target `protobuf:"bytes,3,opt,name=target" json:"target,omitempty"`
|
||||
Dtid string `protobuf:"bytes,4,opt,name=dtid" json:"dtid,omitempty"`
|
||||
}
|
||||
|
||||
func (m *ReadTransactionRequest) Reset() { *m = ReadTransactionRequest{} }
|
||||
func (m *ReadTransactionRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*ReadTransactionRequest) ProtoMessage() {}
|
||||
func (*ReadTransactionRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{38} }
|
||||
|
||||
func (m *ReadTransactionRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
return m.EffectiveCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *ReadTransactionRequest) GetImmediateCallerId() *VTGateCallerID {
|
||||
if m != nil {
|
||||
return m.ImmediateCallerId
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *ReadTransactionRequest) GetTarget() *Target {
|
||||
if m != nil {
|
||||
return m.Target
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// ReadTransactionResponse is the returned value from ReadTransaction
|
||||
type ReadTransactionResponse struct {
|
||||
Metadata *TransactionMetadata `protobuf:"bytes,1,opt,name=metadata" json:"metadata,omitempty"`
|
||||
}
|
||||
|
||||
func (m *ReadTransactionResponse) Reset() { *m = ReadTransactionResponse{} }
|
||||
func (m *ReadTransactionResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*ReadTransactionResponse) ProtoMessage() {}
|
||||
func (*ReadTransactionResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{39} }
|
||||
|
||||
func (m *ReadTransactionResponse) GetMetadata() *TransactionMetadata {
|
||||
if m != nil {
|
||||
return m.Metadata
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// BeginExecuteRequest is the payload to BeginExecute
|
||||
type BeginExecuteRequest struct {
|
||||
EffectiveCallerId *vtrpc.CallerID `protobuf:"bytes,1,opt,name=effective_caller_id,json=effectiveCallerId" json:"effective_caller_id,omitempty"`
|
||||
|
@ -968,7 +1348,7 @@ type BeginExecuteRequest struct {
|
|||
func (m *BeginExecuteRequest) Reset() { *m = BeginExecuteRequest{} }
|
||||
func (m *BeginExecuteRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*BeginExecuteRequest) ProtoMessage() {}
|
||||
func (*BeginExecuteRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{24} }
|
||||
func (*BeginExecuteRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{40} }
|
||||
|
||||
func (m *BeginExecuteRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
|
@ -1019,7 +1399,7 @@ type BeginExecuteResponse struct {
|
|||
func (m *BeginExecuteResponse) Reset() { *m = BeginExecuteResponse{} }
|
||||
func (m *BeginExecuteResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*BeginExecuteResponse) ProtoMessage() {}
|
||||
func (*BeginExecuteResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{25} }
|
||||
func (*BeginExecuteResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{41} }
|
||||
|
||||
func (m *BeginExecuteResponse) GetError() *vtrpc.RPCError {
|
||||
if m != nil {
|
||||
|
@ -1048,7 +1428,7 @@ type BeginExecuteBatchRequest struct {
|
|||
func (m *BeginExecuteBatchRequest) Reset() { *m = BeginExecuteBatchRequest{} }
|
||||
func (m *BeginExecuteBatchRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*BeginExecuteBatchRequest) ProtoMessage() {}
|
||||
func (*BeginExecuteBatchRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{26} }
|
||||
func (*BeginExecuteBatchRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{42} }
|
||||
|
||||
func (m *BeginExecuteBatchRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
|
@ -1099,7 +1479,7 @@ type BeginExecuteBatchResponse struct {
|
|||
func (m *BeginExecuteBatchResponse) Reset() { *m = BeginExecuteBatchResponse{} }
|
||||
func (m *BeginExecuteBatchResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*BeginExecuteBatchResponse) ProtoMessage() {}
|
||||
func (*BeginExecuteBatchResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{27} }
|
||||
func (*BeginExecuteBatchResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{43} }
|
||||
|
||||
func (m *BeginExecuteBatchResponse) GetError() *vtrpc.RPCError {
|
||||
if m != nil {
|
||||
|
@ -1141,7 +1521,7 @@ type SplitQueryRequest struct {
|
|||
func (m *SplitQueryRequest) Reset() { *m = SplitQueryRequest{} }
|
||||
func (m *SplitQueryRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*SplitQueryRequest) ProtoMessage() {}
|
||||
func (*SplitQueryRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{28} }
|
||||
func (*SplitQueryRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{44} }
|
||||
|
||||
func (m *SplitQueryRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
|
@ -1182,7 +1562,7 @@ type QuerySplit struct {
|
|||
func (m *QuerySplit) Reset() { *m = QuerySplit{} }
|
||||
func (m *QuerySplit) String() string { return proto.CompactTextString(m) }
|
||||
func (*QuerySplit) ProtoMessage() {}
|
||||
func (*QuerySplit) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{29} }
|
||||
func (*QuerySplit) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{45} }
|
||||
|
||||
func (m *QuerySplit) GetQuery() *BoundQuery {
|
||||
if m != nil {
|
||||
|
@ -1200,7 +1580,7 @@ type SplitQueryResponse struct {
|
|||
func (m *SplitQueryResponse) Reset() { *m = SplitQueryResponse{} }
|
||||
func (m *SplitQueryResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*SplitQueryResponse) ProtoMessage() {}
|
||||
func (*SplitQueryResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{30} }
|
||||
func (*SplitQueryResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{46} }
|
||||
|
||||
func (m *SplitQueryResponse) GetQueries() []*QuerySplit {
|
||||
if m != nil {
|
||||
|
@ -1216,7 +1596,7 @@ type StreamHealthRequest struct {
|
|||
func (m *StreamHealthRequest) Reset() { *m = StreamHealthRequest{} }
|
||||
func (m *StreamHealthRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*StreamHealthRequest) ProtoMessage() {}
|
||||
func (*StreamHealthRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{31} }
|
||||
func (*StreamHealthRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{47} }
|
||||
|
||||
// RealtimeStats contains information about the tablet status
|
||||
type RealtimeStats struct {
|
||||
|
@ -1252,7 +1632,7 @@ type RealtimeStats struct {
|
|||
func (m *RealtimeStats) Reset() { *m = RealtimeStats{} }
|
||||
func (m *RealtimeStats) String() string { return proto.CompactTextString(m) }
|
||||
func (*RealtimeStats) ProtoMessage() {}
|
||||
func (*RealtimeStats) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{32} }
|
||||
func (*RealtimeStats) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{48} }
|
||||
|
||||
// StreamHealthResponse is streamed by StreamHealth on a regular basis
|
||||
type StreamHealthResponse struct {
|
||||
|
@ -1276,7 +1656,7 @@ type StreamHealthResponse struct {
|
|||
func (m *StreamHealthResponse) Reset() { *m = StreamHealthResponse{} }
|
||||
func (m *StreamHealthResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*StreamHealthResponse) ProtoMessage() {}
|
||||
func (*StreamHealthResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{33} }
|
||||
func (*StreamHealthResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{49} }
|
||||
|
||||
func (m *StreamHealthResponse) GetTarget() *Target {
|
||||
if m != nil {
|
||||
|
@ -1310,7 +1690,7 @@ type UpdateStreamRequest struct {
|
|||
func (m *UpdateStreamRequest) Reset() { *m = UpdateStreamRequest{} }
|
||||
func (m *UpdateStreamRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*UpdateStreamRequest) ProtoMessage() {}
|
||||
func (*UpdateStreamRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{34} }
|
||||
func (*UpdateStreamRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{50} }
|
||||
|
||||
func (m *UpdateStreamRequest) GetEffectiveCallerId() *vtrpc.CallerID {
|
||||
if m != nil {
|
||||
|
@ -1341,7 +1721,7 @@ type UpdateStreamResponse struct {
|
|||
func (m *UpdateStreamResponse) Reset() { *m = UpdateStreamResponse{} }
|
||||
func (m *UpdateStreamResponse) String() string { return proto.CompactTextString(m) }
|
||||
func (*UpdateStreamResponse) ProtoMessage() {}
|
||||
func (*UpdateStreamResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{35} }
|
||||
func (*UpdateStreamResponse) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{51} }
|
||||
|
||||
func (m *UpdateStreamResponse) GetEvent() *StreamEvent {
|
||||
if m != nil {
|
||||
|
@ -1362,7 +1742,7 @@ type TransactionMetadata struct {
|
|||
func (m *TransactionMetadata) Reset() { *m = TransactionMetadata{} }
|
||||
func (m *TransactionMetadata) String() string { return proto.CompactTextString(m) }
|
||||
func (*TransactionMetadata) ProtoMessage() {}
|
||||
func (*TransactionMetadata) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{36} }
|
||||
func (*TransactionMetadata) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{52} }
|
||||
|
||||
func (m *TransactionMetadata) GetParticipants() []*Target {
|
||||
if m != nil {
|
||||
|
@ -1397,6 +1777,22 @@ func init() {
|
|||
proto.RegisterType((*CommitResponse)(nil), "query.CommitResponse")
|
||||
proto.RegisterType((*RollbackRequest)(nil), "query.RollbackRequest")
|
||||
proto.RegisterType((*RollbackResponse)(nil), "query.RollbackResponse")
|
||||
proto.RegisterType((*PrepareRequest)(nil), "query.PrepareRequest")
|
||||
proto.RegisterType((*PrepareResponse)(nil), "query.PrepareResponse")
|
||||
proto.RegisterType((*CommitPreparedRequest)(nil), "query.CommitPreparedRequest")
|
||||
proto.RegisterType((*CommitPreparedResponse)(nil), "query.CommitPreparedResponse")
|
||||
proto.RegisterType((*RollbackPreparedRequest)(nil), "query.RollbackPreparedRequest")
|
||||
proto.RegisterType((*RollbackPreparedResponse)(nil), "query.RollbackPreparedResponse")
|
||||
proto.RegisterType((*CreateTransactionRequest)(nil), "query.CreateTransactionRequest")
|
||||
proto.RegisterType((*CreateTransactionResponse)(nil), "query.CreateTransactionResponse")
|
||||
proto.RegisterType((*StartCommitRequest)(nil), "query.StartCommitRequest")
|
||||
proto.RegisterType((*StartCommitResponse)(nil), "query.StartCommitResponse")
|
||||
proto.RegisterType((*SetRollbackRequest)(nil), "query.SetRollbackRequest")
|
||||
proto.RegisterType((*SetRollbackResponse)(nil), "query.SetRollbackResponse")
|
||||
proto.RegisterType((*ResolveTransactionRequest)(nil), "query.ResolveTransactionRequest")
|
||||
proto.RegisterType((*ResolveTransactionResponse)(nil), "query.ResolveTransactionResponse")
|
||||
proto.RegisterType((*ReadTransactionRequest)(nil), "query.ReadTransactionRequest")
|
||||
proto.RegisterType((*ReadTransactionResponse)(nil), "query.ReadTransactionResponse")
|
||||
proto.RegisterType((*BeginExecuteRequest)(nil), "query.BeginExecuteRequest")
|
||||
proto.RegisterType((*BeginExecuteResponse)(nil), "query.BeginExecuteResponse")
|
||||
proto.RegisterType((*BeginExecuteBatchRequest)(nil), "query.BeginExecuteBatchRequest")
|
||||
|
@ -1420,142 +1816,154 @@ func init() {
|
|||
func init() { proto.RegisterFile("query.proto", fileDescriptor0) }
|
||||
|
||||
var fileDescriptor0 = []byte{
|
||||
// 2190 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xec, 0x59, 0x5b, 0x6f, 0x1b, 0xc7,
|
||||
0x15, 0xf6, 0xf2, 0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6, 0x04, 0x95, 0x94, 0x14, 0xf7, 0x92, 0x12, 0x37, 0x3b, 0x5c, 0x4d, 0x5a, 0x1d, 0xb4, 0x1c,
|
||||
0xee, 0x4f, 0x49, 0x69, 0x3f, 0x49, 0x5b, 0x1f, 0x00, 0x7e, 0x14, 0x24, 0x94, 0x1e, 0xb1, 0x69,
|
||||
0xa4, 0xf4, 0x88, 0x4d, 0xf1, 0x67, 0x93, 0x1e, 0x15, 0x6b, 0xe5, 0x48, 0x57, 0xe2, 0xac, 0x72,
|
||||
0xf3, 0xb5, 0xd4, 0x0d, 0x4d, 0xff, 0xb3, 0x06, 0x2b, 0xad, 0x07, 0x6c, 0x38, 0xe1, 0x6c, 0xd7,
|
||||
0x13, 0x39, 0x08, 0x70, 0x15, 0xca, 0xec, 0xc1, 0xd0, 0x9e, 0x8c, 0x98, 0x79, 0xcf, 0x62, 0xf6,
|
||||
0xc8, 0x14, 0x89, 0x0f, 0xa4, 0x8e, 0x3c, 0x59, 0x55, 0xac, 0x6d, 0xc1, 0xe9, 0x0a, 0x86, 0xc0,
|
||||
0x5b, 0x4e, 0x88, 0x67, 0xa2, 0x34, 0x4c, 0x2e, 0x6a, 0x43, 0xea, 0xcf, 0x93, 0x55, 0xc5, 0x4a,
|
||||
0x14, 0x4d, 0x1d, 0xca, 0x43, 0x77, 0xec, 0x51, 0x7f, 0x1e, 0x9f, 0x96, 0xf6, 0xae, 0x2a, 0x7b,
|
||||
0x67, 0x78, 0xb2, 0xaa, 0xd0, 0x33, 0x92, 0xfe, 0x3a, 0x64, 0xa5, 0x01, 0x18, 0x43, 0x26, 0x51,
|
||||
0xa6, 0x72, 0x1d, 0x27, 0x3d, 0xf5, 0x98, 0xa4, 0xeb, 0x5f, 0x84, 0x34, 0x71, 0x4f, 0x70, 0x05,
|
||||
0x96, 0x6c, 0xe6, 0x1c, 0xf0, 0x43, 0xe1, 0x5b, 0x7a, 0x03, 0x93, 0x68, 0x8b, 0x3f, 0x11, 0xe7,
|
||||
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0x9f, 0x9a, 0x06, 0xa5,
|
||||
0xa8, 0x79, 0x25, 0x91, 0x28, 0x26, 0x7e, 0x05, 0xc2, 0xbb, 0xb4, 0x92, 0x99, 0x2b, 0x88, 0xd9,
|
||||
0x3c, 0x25, 0x21, 0x1f, 0x5f, 0x84, 0x15, 0xee, 0x53, 0x27, 0xa0, 0x43, 0x31, 0xda, 0x84, 0x45,
|
||||
0x59, 0x79, 0x49, 0x95, 0x12, 0xd4, 0xf6, 0x08, 0x7f, 0x1e, 0x96, 0xdc, 0x70, 0xf8, 0x55, 0x72,
|
||||
0x73, 0x16, 0xcf, 0x4f, 0x46, 0x12, 0xa1, 0xf4, 0x2f, 0xc3, 0xd9, 0x38, 0x82, 0x81, 0xe7, 0x3a,
|
||||
0x01, 0xc3, 0x97, 0x20, 0xe7, 0xcb, 0x86, 0x50, 0x51, 0xc3, 0x4a, 0x44, 0xa2, 0xa3, 0x89, 0x42,
|
||||
0xe8, 0xff, 0x4d, 0x41, 0x59, 0x9d, 0x6f, 0x50, 0x3e, 0x3c, 0x7c, 0x46, 0xd3, 0x70, 0x19, 0x96,
|
||||
0x04, 0xdd, 0x8a, 0x4b, 0x76, 0x41, 0x22, 0x22, 0x84, 0x48, 0x05, 0x0d, 0xcc, 0x44, 0xdc, 0x65,
|
||||
0x2a, 0xf2, 0xa4, 0x44, 0x03, 0x63, 0x46, 0x5c, 0x90, 0xb1, 0xdc, 0x13, 0x32, 0xb6, 0xf4, 0x54,
|
||||
0x19, 0xdb, 0x82, 0xb5, 0xf9, 0x88, 0xab, 0xb4, 0x5d, 0x81, 0xa5, 0x30, 0x29, 0xd1, 0x70, 0x5a,
|
||||
0x94, 0xb7, 0x08, 0xa2, 0xff, 0x21, 0x05, 0x6b, 0x6a, 0x6e, 0x7c, 0x34, 0x1a, 0x28, 0x11, 0xe7,
|
||||
0xec, 0x53, 0xc5, 0xb9, 0x09, 0xe7, 0x4e, 0x05, 0xe8, 0x03, 0xf4, 0xc7, 0x5f, 0x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37, 0xce, 0xf4, 0xc7, 0xdd, 0xa8, 0x9f, 0x83,
|
||||
0x72, 0xf8, 0xbd, 0xf5, 0x06, 0xa3, 0x36, 0x8f, 0x06, 0x90, 0xfe, 0xa7, 0x14, 0x94, 0x88, 0xa0,
|
||||
0x58, 0x63, 0x26, 0x7e, 0xdc, 0x06, 0x22, 0xad, 0x87, 0x12, 0x62, 0xce, 0xfa, 0xa8, 0x40, 0x8a,
|
||||
0x21, 0x4d, 0xf6, 0x10, 0xae, 0xc1, 0xb9, 0x80, 0x0d, 0x5d, 0x67, 0x14, 0x98, 0xfb, 0xec, 0xd0,
|
||||
0x72, 0x46, 0xe6, 0x98, 0x06, 0x5c, 0x3d, 0x54, 0x94, 0x48, 0x59, 0x31, 0x1b, 0x92, 0xb7, 0x23,
|
||||
0x59, 0xf8, 0x2a, 0xac, 0xed, 0x5b, 0x8e, 0xed, 0x1e, 0x98, 0x9e, 0x4d, 0xa7, 0xcc, 0x0f, 0x94,
|
||||
0xab, 0xa2, 0x16, 0xb3, 0x04, 0x87, 0xbc, 0x5e, 0xc8, 0x0a, 0x6b, 0xe3, 0x1b, 0x70, 0x69, 0xa1,
|
||||
0x16, 0xf3, 0x9e, 0x65, 0x73, 0xe6, 0xb3, 0x91, 0xe9, 0x33, 0xcf, 0xb6, 0x86, 0x54, 0xce, 0x96,
|
||||
0xf0, 0x0e, 0x7d, 0x79, 0x81, 0xea, 0x6d, 0x05, 0x27, 0x33, 0xb4, 0x88, 0xf6, 0xd0, 0x9b, 0x98,
|
||||
0x93, 0x80, 0x1e, 0x30, 0x39, 0x96, 0x34, 0x92, 0x1f, 0x7a, 0x93, 0x81, 0xd8, 0x8b, 0x9f, 0xcc,
|
||||
0xf7, 0xbd, 0x70, 0x1a, 0x69, 0x44, 0x2c, 0xf5, 0x7f, 0x6b, 0xd1, 0xe7, 0x7c, 0x14, 0xbd, 0x78,
|
||||
0xda, 0x44, 0x3d, 0xa5, 0xbd, 0x57, 0x4f, 0x55, 0x60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
|
||||
0x0d, 0xba, 0xb7, 0xbb, 0xbb, 0x5f, 0xeb, 0xa2, 0x33, 0x62, 0xd3, 0x23, 0xad, 0x5e, 0x9d, 0xb4,
|
||||
0x90, 0x86, 0x01, 0x72, 0xcd, 0xdd, 0x9d, 0x9d, 0xb6, 0x81, 0x52, 0x78, 0x19, 0xf2, 0x64, 0xb7,
|
||||
0xd3, 0x69, 0xd4, 0x9b, 0xb7, 0x51, 0xba, 0xb1, 0x0e, 0x95, 0xa1, 0x3b, 0xae, 0x4e, 0xdd, 0x09,
|
||||
0x9f, 0xec, 0xb3, 0xea, 0xb1, 0xc5, 0x59, 0x10, 0x84, 0xff, 0xb3, 0xda, 0xcf, 0xc9, 0x3f, 0xd7,
|
||||
0xfe, 0x1f, 0x00, 0x00, 0xff, 0xff, 0x57, 0xc4, 0x48, 0x11, 0xed, 0x1a, 0x00, 0x00,
|
||||
// 2376 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xec, 0x5a, 0xdb, 0x6f, 0x1b, 0x59,
|
||||
0x19, 0xef, 0xf8, 0x16, 0xfb, 0x73, 0x9c, 0x9c, 0x1c, 0xa7, 0x5b, 0x6f, 0xb6, 0xb0, 0x65, 0xf6,
|
||||
0x56, 0xda, 0x12, 0xba, 0x6e, 0x08, 0xd5, 0xb2, 0x40, 0x1d, 0xc7, 0xe9, 0x5a, 0x75, 0x1c, 0xf7,
|
||||
0x78, 0x1c, 0x28, 0x5a, 0x69, 0x74, 0x62, 0x9f, 0x26, 0xa3, 0xd8, 0x33, 0xd3, 0x99, 0xe3, 0xa4,
|
||||
0x7e, 0x2b, 0xbb, 0xdc, 0xaf, 0x45, 0x5c, 0x96, 0x8b, 0xb4, 0x20, 0xf1, 0x27, 0xf0, 0x8c, 0x84,
|
||||
0xf8, 0x03, 0x90, 0x78, 0x05, 0x89, 0x37, 0x84, 0x78, 0x82, 0x67, 0x1e, 0x10, 0x3a, 0x67, 0xce,
|
||||
0x8c, 0xc7, 0x89, 0xbb, 0xed, 0x96, 0xa7, 0xa4, 0xfb, 0xe4, 0x73, 0xbe, 0xef, 0x9b, 0xf3, 0x9d,
|
||||
0xdf, 0x77, 0x3b, 0x37, 0x43, 0xfe, 0xde, 0x90, 0x79, 0xa3, 0x65, 0xd7, 0x73, 0xb8, 0x83, 0xd3,
|
||||
0xb2, 0xb3, 0x34, 0xc7, 0x1d, 0xd7, 0xe9, 0x51, 0x4e, 0x03, 0xf2, 0x52, 0xfe, 0x80, 0x7b, 0x6e,
|
||||
0x37, 0xe8, 0xe8, 0xf7, 0x20, 0x63, 0x50, 0x6f, 0x97, 0x71, 0xbc, 0x04, 0xd9, 0x7d, 0x36, 0xf2,
|
||||
0x5d, 0xda, 0x65, 0x25, 0xed, 0x82, 0x76, 0x31, 0x47, 0xa2, 0x3e, 0x5e, 0x84, 0xb4, 0xbf, 0x47,
|
||||
0xbd, 0x5e, 0x29, 0x21, 0x19, 0x41, 0x07, 0x7f, 0x06, 0xf2, 0x9c, 0xee, 0xf4, 0x19, 0x37, 0xf9,
|
||||
0xc8, 0x65, 0xa5, 0xe4, 0x05, 0xed, 0xe2, 0x5c, 0x79, 0x71, 0x39, 0x52, 0x67, 0x48, 0xa6, 0x31,
|
||||
0x72, 0x19, 0x01, 0x1e, 0xb5, 0xf5, 0x2b, 0x30, 0xb7, 0x6d, 0xdc, 0xa4, 0x9c, 0x55, 0x69, 0xbf,
|
||||
0xcf, 0xbc, 0xfa, 0xba, 0x50, 0x3d, 0xf4, 0x99, 0x67, 0xd3, 0x41, 0xa4, 0x3a, 0xec, 0xeb, 0x6f,
|
||||
0x03, 0xd4, 0x0e, 0x98, 0xcd, 0x0d, 0x67, 0x9f, 0xd9, 0xf8, 0x3c, 0xe4, 0xb8, 0x35, 0x60, 0x3e,
|
||||
0xa7, 0x03, 0x57, 0x8a, 0x26, 0xc9, 0x98, 0xf0, 0x88, 0x69, 0x2e, 0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ce, 0xa1, 0x6f, 0xd2, 0xbb, 0x77, 0x59, 0x97, 0xb3,
|
||||
0x20, 0xd9, 0x52, 0x64, 0x56, 0x10, 0x2b, 0x8a, 0x86, 0x5f, 0x80, 0x9c, 0x65, 0xfb, 0xcc, 0xe3,
|
||||
0xa6, 0xd5, 0x93, 0x86, 0x4e, 0x91, 0x6c, 0x40, 0xa8, 0xf7, 0xf0, 0xc7, 0x21, 0x25, 0x84, 0x4b,
|
||||
0x29, 0xa9, 0x05, 0x94, 0x16, 0xe2, 0x1c, 0x12, 0x49, 0xc7, 0x97, 0x21, 0xc3, 0x24, 0xde, 0x52,
|
||||
0x7a, 0x22, 0xa4, 0xe2, 0xa6, 0x20, 0x4a, 0x44, 0xff, 0x4d, 0x12, 0xf2, 0x6d, 0xee, 0x31, 0x3a,
|
||||
0x90, 0xf8, 0xf1, 0x9b, 0x00, 0x3e, 0xa7, 0x9c, 0x0d, 0x98, 0xcd, 0x43, 0x20, 0xe7, 0xd5, 0x00,
|
||||
0x31, 0xb9, 0xe5, 0x76, 0x28, 0x44, 0x62, 0xf2, 0x47, 0x0d, 0x9c, 0x78, 0x02, 0x03, 0x2f, 0xbd,
|
||||
0x9f, 0x80, 0x5c, 0x34, 0x1a, 0xae, 0x40, 0xb6, 0x4b, 0x39, 0xdb, 0x75, 0xbc, 0x91, 0xaa, 0x02,
|
||||
0xaf, 0x7c, 0x90, 0xf6, 0xe5, 0xaa, 0x12, 0x26, 0xd1, 0x67, 0xf8, 0x63, 0x10, 0x94, 0x4b, 0x99,
|
||||
0x07, 0xaa, 0x96, 0xe5, 0x24, 0x45, 0xc4, 0x3f, 0x7e, 0x03, 0xb0, 0xeb, 0x59, 0x03, 0xea, 0x8d,
|
||||
0xcc, 0x7d, 0x36, 0x32, 0x95, 0xcb, 0x92, 0x53, 0x5c, 0x86, 0x94, 0xdc, 0x2d, 0x36, 0xda, 0x08,
|
||||
0x9c, 0x77, 0x7d, 0xf2, 0x5b, 0x15, 0x74, 0xc7, 0x1d, 0x11, 0xfb, 0x52, 0xd6, 0x20, 0x3f, 0xac,
|
||||
0x36, 0x69, 0x19, 0x9f, 0xa2, 0xa9, 0xbf, 0x06, 0xd9, 0x70, 0xf2, 0x38, 0x07, 0xe9, 0x9a, 0xe7,
|
||||
0x39, 0x1e, 0x3a, 0x83, 0x67, 0x20, 0xb9, 0xbe, 0xd9, 0x40, 0x9a, 0x6c, 0xac, 0x37, 0x50, 0x42,
|
||||
0xff, 0x43, 0x22, 0x4a, 0x79, 0xc2, 0xee, 0x0d, 0x99, 0xcf, 0xf1, 0x17, 0xa1, 0xc8, 0x64, 0xac,
|
||||
0x58, 0x07, 0xcc, 0xec, 0xca, 0x75, 0x40, 0x44, 0x4a, 0x10, 0xd0, 0xf3, 0xcb, 0xc1, 0x0a, 0x15,
|
||||
0xae, 0x0f, 0x64, 0x21, 0x92, 0x55, 0xa4, 0x1e, 0xae, 0x41, 0xd1, 0x1a, 0x0c, 0x58, 0xcf, 0xa2,
|
||||
0x3c, 0x3e, 0x40, 0xe0, 0xb0, 0xb3, 0x61, 0xf9, 0x9c, 0x58, 0x66, 0xc8, 0x42, 0xf4, 0x45, 0x34,
|
||||
0xcc, 0x2b, 0x90, 0xe1, 0x72, 0xf9, 0x53, 0xd5, 0xa0, 0x10, 0x26, 0xaf, 0x24, 0x12, 0xc5, 0xc4,
|
||||
0xaf, 0x41, 0xb0, 0x96, 0x96, 0x52, 0x13, 0x01, 0x31, 0xae, 0xa7, 0x24, 0xe0, 0xe3, 0x57, 0x60,
|
||||
0x8e, 0x7b, 0xd4, 0xf6, 0x69, 0x57, 0x94, 0x36, 0x31, 0xa3, 0xb4, 0x5c, 0xa4, 0x0a, 0x31, 0x6a,
|
||||
0xbd, 0x87, 0x3f, 0x0d, 0x33, 0x4e, 0x50, 0xfc, 0x4a, 0x99, 0x89, 0x19, 0x4f, 0x56, 0x46, 0x12,
|
||||
0x4a, 0xe9, 0x9f, 0x87, 0xf9, 0xc8, 0x82, 0xbe, 0xeb, 0xd8, 0x3e, 0xc3, 0x97, 0x20, 0xe3, 0xc9,
|
||||
0x84, 0x50, 0x56, 0xc3, 0x6a, 0x88, 0x58, 0x46, 0x13, 0x25, 0xa1, 0xff, 0x3b, 0x01, 0x45, 0xf5,
|
||||
0xfd, 0x1a, 0xe5, 0xdd, 0xbd, 0x13, 0xea, 0x86, 0xcb, 0x30, 0x23, 0xe8, 0x56, 0x14, 0xb2, 0x53,
|
||||
0x1c, 0x11, 0x4a, 0x08, 0x57, 0x50, 0xdf, 0x8c, 0xd9, 0x5d, 0xba, 0x22, 0x4b, 0x0a, 0xd4, 0x37,
|
||||
0xc6, 0xc4, 0x29, 0x1e, 0xcb, 0x3c, 0xc6, 0x63, 0x33, 0x4f, 0xe4, 0xb1, 0x75, 0x58, 0x9c, 0xb4,
|
||||
0xb8, 0x72, 0xdb, 0x15, 0x98, 0x09, 0x9c, 0x12, 0x16, 0xa7, 0x69, 0x7e, 0x0b, 0x45, 0xf4, 0x5f,
|
||||
0x27, 0x60, 0x51, 0xd5, 0x8d, 0x67, 0x23, 0x81, 0x62, 0x76, 0x4e, 0x3f, 0x91, 0x9d, 0xab, 0x70,
|
||||
0xf6, 0x88, 0x81, 0x9e, 0x22, 0x3f, 0x7e, 0xaf, 0xc1, 0xec, 0x1a, 0xdb, 0xb5, 0xec, 0x93, 0x69,
|
||||
0x5e, 0x7d, 0x15, 0x0a, 0x6a, 0xfa, 0x0a, 0xfc, 0xf1, 0xa8, 0xd6, 0xa6, 0x44, 0xb5, 0xfe, 0x77,
|
||||
0x0d, 0x0a, 0x55, 0x67, 0x30, 0xb0, 0xf8, 0x09, 0x8d, 0xab, 0xe3, 0x38, 0x53, 0xd3, 0x70, 0x22,
|
||||
0x98, 0x0b, 0x61, 0x06, 0x06, 0xd2, 0xff, 0xa1, 0xc1, 0x3c, 0x71, 0xfa, 0xfd, 0x1d, 0xda, 0xdd,
|
||||
0x3f, 0xdd, 0xd8, 0x31, 0xa0, 0x31, 0x50,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x73, 0xc7, 0xc0, 0xa9, 0xfd, 0xe9, 0x2a, 0x64, 0x07, 0x8c, 0xd3,
|
||||
0x1e, 0xe5, 0x54, 0x41, 0x5a, 0x0a, 0xc7, 0x1d, 0x4b, 0x6f, 0x2a, 0x09, 0x12, 0xc9, 0xea, 0xef,
|
||||
0x27, 0xa0, 0x28, 0x77, 0xba, 0x1f, 0x1d, 0x87, 0xa6, 0x1f, 0x87, 0x1e, 0x6a, 0xb0, 0x38, 0x69,
|
||||
0xa0, 0xe8, 0x44, 0x90, 0x66, 0x9e, 0xe7, 0x78, 0x47, 0x6c, 0x42, 0x5a, 0x55, 0x79, 0x71, 0x43,
|
||||
0x02, 0x6e, 0xec, 0xd4, 0x94, 0x78, 0xdc, 0xa9, 0x69, 0x4a, 0x39, 0x48, 0x4e, 0xdb, 0x80, 0xfe,
|
||||
0x29, 0x01, 0xa5, 0xf8, 0x94, 0x3e, 0xba, 0x81, 0x98, 0xbc, 0x81, 0xf8, 0xd0, 0x97, 0x41, 0xef,
|
||||
0x69, 0xf0, 0xfc, 0x14, 0x83, 0x7e, 0x38, 0x47, 0xc7, 0xee, 0x21, 0x12, 0x8f, 0xbd, 0x87, 0x78,
|
||||
0x52, 0x57, 0xbf, 0x93, 0x82, 0x85, 0xb6, 0xdb, 0xb7, 0xb8, 0x1a, 0xe4, 0x74, 0x27, 0xe7, 0x27,
|
||||
0x60, 0xd6, 0x17, 0x60, 0xcd, 0xae, 0xd3, 0x1f, 0x0e, 0x6c, 0xb9, 0x79, 0xca, 0x91, 0xbc, 0xa4,
|
||||
0x55, 0x25, 0x09, 0xbf, 0x08, 0xf9, 0x50, 0x64, 0x68, 0x73, 0x75, 0xb5, 0x04, 0x4a, 0x62, 0x68,
|
||||
0x73, 0xbc, 0x02, 0xe7, 0xec, 0xe1, 0xc0, 0x94, 0x37, 0xea, 0x2e, 0xf3, 0x4c, 0x39, 0xb2, 0x29,
|
||||
0x36, 0x5c, 0xa5, 0xac, 0x14, 0x2e, 0xda, 0xc3, 0x01, 0x71, 0x0e, 0xfd, 0x16, 0xf3, 0xa4, 0xf2,
|
||||
0x16, 0xf5, 0x38, 0xbe, 0x01, 0x39, 0xda, 0xdf, 0x75, 0x3c, 0x8b, 0xef, 0x0d, 0x4a, 0x39, 0x79,
|
||||
0xcb, 0xac, 0x87, 0xb7, 0xcc, 0x47, 0xcd, 0xbf, 0x5c, 0x09, 0x25, 0xc9, 0xf8, 0x23, 0x7c, 0x19,
|
||||
0xf0, 0xd0, 0x67, 0x66, 0x30, 0xb9, 0x40, 0xe9, 0x41, 0xb9, 0x04, 0x32, 0x3e, 0xe7, 0x87, 0x3e,
|
||||
0x1b, 0x0f, 0xb3, 0x5d, 0xd6, 0xaf, 0x40, 0x2e, 0x1a, 0x04, 0x23, 0x98, 0xad, 0xdd, 0xee, 0x54,
|
||||
0x1a, 0x66, 0xbb, 0xd5, 0xa8, 0x1b, 0x6d, 0x74, 0x06, 0x17, 0x20, 0xb7, 0xd1, 0x69, 0x34, 0xcc,
|
||||
0x76, 0xb5, 0xd2, 0x44, 0x9a, 0x4e, 0x00, 0xe4, 0x87, 0x72, 0x88, 0xb1, 0x35, 0xb5, 0xc7, 0x58,
|
||||
0xf3, 0x05, 0xc8, 0x79, 0xce, 0xa1, 0x32, 0x54, 0x42, 0x62, 0xcf, 0x7a, 0xce, 0xa1, 0x34, 0x93,
|
||||
0x5e, 0x01, 0x1c, 0x07, 0xa6, 0x42, 0x3d, 0x96, 0x8d, 0xda, 0x44, 0x36, 0x8e, 0xf5, 0x47, 0xd9,
|
||||
0x18, 0xec, 0xcc, 0x3c, 0x46, 0x07, 0x6f, 0x31, 0xda, 0xe7, 0x61, 0x01, 0xd2, 0x7f, 0x9b, 0x80,
|
||||
0x02, 0x11, 0x14, 0x6b, 0xc0, 0xda, 0x9c, 0x72, 0x5f, 0xb8, 0x75, 0x4f, 0x8a, 0x98, 0xe3, 0x3c,
|
||||
0xca, 0x91, 0x7c, 0x40, 0x93, 0x39, 0x84, 0xcb, 0x70, 0xd6, 0x67, 0x5d, 0xc7, 0xee, 0xf9, 0xe6,
|
||||
0x0e, 0xdb, 0xb3, 0xec, 0x9e, 0x39, 0xa0, 0x3e, 0x57, 0x2f, 0x2c, 0x05, 0x52, 0x54, 0xcc, 0x35,
|
||||
0xc9, 0xdb, 0x94, 0x2c, 0x7c, 0x15, 0x16, 0x77, 0x2c, 0xbb, 0xef, 0xec, 0x9a, 0x6e, 0x9f, 0x8e,
|
||||
0x98, 0xe7, 0x2b, 0xa8, 0x22, 0x16, 0xd3, 0x04, 0x07, 0xbc, 0x56, 0xc0, 0x0a, 0x62, 0xe3, 0x2b,
|
||||
0x70, 0x69, 0xaa, 0x16, 0xf3, 0xae, 0xd5, 0xe7, 0xcc, 0x63, 0x3d, 0xd3, 0x63, 0x6e, 0xdf, 0xea,
|
||||
0x52, 0x59, 0x5b, 0x82, 0xad, 0xd8, 0xab, 0x53, 0x54, 0x6f, 0x28, 0x71, 0x32, 0x96, 0x16, 0xd6,
|
||||
0xee, 0xba, 0x43, 0x73, 0xe8, 0xd3, 0x5d, 0x26, 0xcb, 0x92, 0x46, 0xb2, 0x5d, 0x77, 0xd8, 0x11,
|
||||
0x7d, 0x8c, 0x20, 0x79, 0xcf, 0x0d, 0xaa, 0x91, 0x46, 0x44, 0x53, 0xff, 0xa7, 0x16, 0xde, 0x43,
|
||||
0x86, 0xd6, 0x8b, 0xaa, 0x4d, 0x98, 0x53, 0xda, 0x07, 0xe5, 0x54, 0x09, 0x66, 0x7c, 0xe6, 0x1d,
|
||||
0x58, 0xf6, 0x6e, 0xf8, 0x08, 0xa5, 0xba, 0xb8, 0x0d, 0xaf, 0xaa, 0x47, 0x64, 0x76, 0x9f, 0x33,
|
||||
0xcf, 0xa6, 0xfd, 0xfe, 0xc8, 0x0c, 0x8e, 0x61, 0x36, 0x67, 0x3d, 0x73, 0xfc, 0xdc, 0x1b, 0x54,
|
||||
0x9c, 0x97, 0x02, 0xe9, 0x5a, 0x24, 0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7, 0xa1, 0xe4, 0xdc, 0xa9, 0x55, 0x08, 0xfa, 0x51, 0x06, 0xe7, 0x61, 0x66, 0xbd,
|
||||
0x56, 0xad, 0x6f, 0x56, 0x1a, 0x08, 0xcb, 0x2f, 0x84, 0x55, 0x7e, 0x7c, 0x55, 0x34, 0xd7, 0x1a,
|
||||
0x5b, 0x6b, 0xe8, 0x27, 0x2d, 0xa1, 0x70, 0xbb, 0x42, 0xaa, 0x6f, 0x55, 0x08, 0xfa, 0xe9, 0x55,
|
||||
0xa1, 0x70, 0xbb, 0x42, 0x94, 0xbd, 0x7e, 0xd6, 0x12, 0x82, 0x92, 0xf5, 0xde, 0x55, 0x31, 0x69,
|
||||
0x45, 0xff, 0x79, 0x0b, 0x67, 0x21, 0xb9, 0x56, 0x37, 0xd0, 0x2f, 0xa4, 0xb6, 0x5a, 0xb3, 0xb3,
|
||||
0x89, 0x7e, 0x89, 0x04, 0xb1, 0x5d, 0x33, 0xd0, 0xaf, 0x04, 0x31, 0x6d, 0x74, 0x5a, 0x8d, 0x1a,
|
||||
0x3a, 0x7f, 0x69, 0x03, 0xd0, 0xd1, 0x90, 0x13, 0xd3, 0xea, 0x34, 0x6f, 0x35, 0xb7, 0xbe, 0xd4,
|
||||
0x44, 0x67, 0x44, 0xa7, 0x45, 0x6a, 0xad, 0x0a, 0xa9, 0x21, 0x0d, 0x03, 0x64, 0xaa, 0x5b, 0x9b,
|
||||
0x9b, 0x75, 0x03, 0x25, 0xf0, 0x2c, 0x64, 0xc9, 0x56, 0xa3, 0xb1, 0x56, 0xa9, 0xde, 0x42, 0xc9,
|
||||
0xb5, 0x25, 0x28, 0x75, 0x9d, 0xc1, 0xf2, 0xc8, 0x19, 0xf2, 0xe1, 0x0e, 0x5b, 0x3e, 0xb0, 0x38,
|
||||
0xf3, 0xfd, 0xe0, 0xcf, 0x36, 0x3b, 0x19, 0xf9, 0x73, 0xed, 0x7f, 0x01, 0x00, 0x00, 0xff, 0xff,
|
||||
0xe1, 0x6c, 0x20, 0x20, 0xa6, 0x23, 0x00, 0x00,
|
||||
}
|
||||
|
|
|
@ -61,6 +61,22 @@ type QueryClient interface {
|
|||
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)
|
||||
// ResolveTransaction marks the 2pc transaction as resolved.
|
||||
ResolveTransaction(ctx context.Context, in *query.ResolveTransactionRequest, opts ...grpc.CallOption) (*query.ResolveTransactionResponse, 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.
|
||||
|
@ -160,6 +176,78 @@ func (c *queryClient) Rollback(ctx context.Context, in *query.RollbackRequest, o
|
|||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) Prepare(ctx context.Context, in *query.PrepareRequest, opts ...grpc.CallOption) (*query.PrepareResponse, error) {
|
||||
out := new(query.PrepareResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/Prepare", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) CommitPrepared(ctx context.Context, in *query.CommitPreparedRequest, opts ...grpc.CallOption) (*query.CommitPreparedResponse, error) {
|
||||
out := new(query.CommitPreparedResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/CommitPrepared", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) RollbackPrepared(ctx context.Context, in *query.RollbackPreparedRequest, opts ...grpc.CallOption) (*query.RollbackPreparedResponse, error) {
|
||||
out := new(query.RollbackPreparedResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/RollbackPrepared", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) CreateTransaction(ctx context.Context, in *query.CreateTransactionRequest, opts ...grpc.CallOption) (*query.CreateTransactionResponse, error) {
|
||||
out := new(query.CreateTransactionResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/CreateTransaction", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) StartCommit(ctx context.Context, in *query.StartCommitRequest, opts ...grpc.CallOption) (*query.StartCommitResponse, error) {
|
||||
out := new(query.StartCommitResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/StartCommit", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) SetRollback(ctx context.Context, in *query.SetRollbackRequest, opts ...grpc.CallOption) (*query.SetRollbackResponse, error) {
|
||||
out := new(query.SetRollbackResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/SetRollback", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) ResolveTransaction(ctx context.Context, in *query.ResolveTransactionRequest, opts ...grpc.CallOption) (*query.ResolveTransactionResponse, error) {
|
||||
out := new(query.ResolveTransactionResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/ResolveTransaction", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) ReadTransaction(ctx context.Context, in *query.ReadTransactionRequest, opts ...grpc.CallOption) (*query.ReadTransactionResponse, error) {
|
||||
out := new(query.ReadTransactionResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/ReadTransaction", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *queryClient) BeginExecute(ctx context.Context, in *query.BeginExecuteRequest, opts ...grpc.CallOption) (*query.BeginExecuteResponse, error) {
|
||||
out := new(query.BeginExecuteResponse)
|
||||
err := grpc.Invoke(ctx, "/queryservice.Query/BeginExecute", in, out, c.cc, opts...)
|
||||
|
@ -271,6 +359,22 @@ type QueryServer interface {
|
|||
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)
|
||||
// ResolveTransaction marks the 2pc transaction as resolved.
|
||||
ResolveTransaction(context.Context, *query.ResolveTransactionRequest) (*query.ResolveTransactionResponse, 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.
|
||||
|
@ -400,6 +504,150 @@ func _Query_Rollback_Handler(srv interface{}, ctx context.Context, dec func(inte
|
|||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_Prepare_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.PrepareRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).Prepare(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/Prepare",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).Prepare(ctx, req.(*query.PrepareRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_CommitPrepared_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.CommitPreparedRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).CommitPrepared(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/CommitPrepared",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).CommitPrepared(ctx, req.(*query.CommitPreparedRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_RollbackPrepared_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.RollbackPreparedRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).RollbackPrepared(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/RollbackPrepared",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).RollbackPrepared(ctx, req.(*query.RollbackPreparedRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_CreateTransaction_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.CreateTransactionRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).CreateTransaction(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/CreateTransaction",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).CreateTransaction(ctx, req.(*query.CreateTransactionRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_StartCommit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.StartCommitRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).StartCommit(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/StartCommit",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).StartCommit(ctx, req.(*query.StartCommitRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_SetRollback_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.SetRollbackRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).SetRollback(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/SetRollback",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).SetRollback(ctx, req.(*query.SetRollbackRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_ResolveTransaction_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.ResolveTransactionRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).ResolveTransaction(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/ResolveTransaction",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).ResolveTransaction(ctx, req.(*query.ResolveTransactionRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_ReadTransaction_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.ReadTransactionRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(QueryServer).ReadTransaction(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/queryservice.Query/ReadTransaction",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(QueryServer).ReadTransaction(ctx, req.(*query.ReadTransactionRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Query_BeginExecute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(query.BeginExecuteRequest)
|
||||
if err := dec(in); err != nil {
|
||||
|
@ -520,6 +768,38 @@ var _Query_serviceDesc = grpc.ServiceDesc{
|
|||
MethodName: "Rollback",
|
||||
Handler: _Query_Rollback_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "Prepare",
|
||||
Handler: _Query_Prepare_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "CommitPrepared",
|
||||
Handler: _Query_CommitPrepared_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "RollbackPrepared",
|
||||
Handler: _Query_RollbackPrepared_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "CreateTransaction",
|
||||
Handler: _Query_CreateTransaction_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "StartCommit",
|
||||
Handler: _Query_StartCommit_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "SetRollback",
|
||||
Handler: _Query_SetRollback_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "ResolveTransaction",
|
||||
Handler: _Query_ResolveTransaction_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "ReadTransaction",
|
||||
Handler: _Query_ReadTransaction_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "BeginExecute",
|
||||
Handler: _Query_BeginExecute_Handler,
|
||||
|
@ -556,25 +836,34 @@ var _Query_serviceDesc = grpc.ServiceDesc{
|
|||
func init() { proto.RegisterFile("queryservice.proto", fileDescriptor0) }
|
||||
|
||||
var fileDescriptor0 = []byte{
|
||||
// 312 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x74, 0x93, 0xdf, 0x4a, 0xf3, 0x40,
|
||||
0x10, 0xc5, 0xbf, 0xef, 0xa2, 0x51, 0xc6, 0x78, 0xe1, 0x68, 0xfd, 0x93, 0x0a, 0x8a, 0x0f, 0x50,
|
||||
0x44, 0x05, 0x41, 0xf0, 0xa6, 0x45, 0x50, 0x0a, 0x82, 0x2d, 0x82, 0xb7, 0x69, 0x1c, 0x34, 0x98,
|
||||
0x74, 0xd3, 0x64, 0x23, 0xfa, 0x16, 0x3e, 0xb2, 0xb8, 0x9b, 0xd9, 0xee, 0xae, 0xeb, 0xe5, 0xfc,
|
||||
0xce, 0x99, 0xc3, 0x4c, 0x66, 0x03, 0xb8, 0x6c, 0xa9, 0xfe, 0x6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5, 0x7e, 0x37, 0xfb, 0x7c, 0x02, 0x83, 0x38, 0xeb,
|
||||
0x20, 0xa0, 0x98, 0x90, 0x09, 0xc4, 0xfa, 0x68, 0xb7, 0x94, 0x16, 0x72, 0xf5, 0x64, 0x6c, 0xe8,
|
||||
0x6f, 0xea, 0x6a, 0xd6, 0x91, 0x27, 0x10, 0x3f, 0x56, 0xcf, 0xa9, 0x24, 0xed, 0x30, 0x61, 0x36,
|
||||
0xf4, 0xc3, 0x5c, 0x6d, 0x15, 0x36, 0x8f, 0xd4, 0x9f, 0x71, 0xfe, 0x1d, 0x00, 0x00, 0xff, 0xff,
|
||||
0x29, 0x7f, 0x6d, 0xa7, 0x4a, 0x03, 0x00, 0x00,
|
||||
// 455 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x7c, 0x94, 0xdb, 0x8e, 0xd3, 0x40,
|
||||
0x0c, 0x86, 0xe1, 0x62, 0x77, 0x91, 0x1b, 0x4e, 0x03, 0x0b, 0x6c, 0x76, 0x7b, 0x80, 0x07, 0xa8,
|
||||
0x10, 0x20, 0x21, 0x55, 0xe2, 0xa6, 0x15, 0x08, 0x54, 0x89, 0x43, 0x4a, 0x25, 0x24, 0xae, 0xa6,
|
||||
0xa9, 0x05, 0x11, 0x69, 0x92, 0x4e, 0xa6, 0x15, 0x3c, 0x05, 0xaf, 0x8c, 0xc8, 0xc4, 0xce, 0xcc,
|
||||
0x24, 0xd9, 0x4b, 0xff, 0xbf, 0xfd, 0xc9, 0x13, 0xc7, 0x06, 0xb1, 0x3f, 0xa0, 0xfa, 0x53, 0xa2,
|
||||
0x3a, 0x26, 0x31, 0x4e, 0x0b, 0x95, 0xeb, 0x5c, 0x04, 0xb6, 0x16, 0x0e, 0xaa, 0xc8, 0x58, 0x2f,
|
||||
0xfe, 0x0e, 0xe0, 0xe4, 0xcb, 0xff, 0x58, 0xcc, 0xe0, 0xec, 0x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05, 0x00, 0x00,
|
||||
}
|
||||
|
|
|
@ -149,6 +149,46 @@ func (ftc *fakeTabletConn) Rollback(ctx context.Context, target *querypb.Target,
|
|||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// Prepare is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// CommitPrepared is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// RollbackPrepared is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error) {
|
||||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// CreateTransaction is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error) {
|
||||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// StartCommit is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// SetRollback is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error) {
|
||||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// ResolveTransaction is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// ReadTransaction is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
return nil, fmt.Errorf("not implemented in this test")
|
||||
}
|
||||
|
||||
// BeginExecute is part of the TabletConn interface
|
||||
func (ftc *fakeTabletConn) BeginExecute(ctx context.Context, target *querypb.Target, query string, bindVars map[string]interface{}, options *querypb.ExecuteOptions) (*sqltypes.Result, int64, error) {
|
||||
return nil, 0, fmt.Errorf("not implemented in this test")
|
||||
|
@ -667,7 +707,8 @@ func TestBinlogPlayerMapHorizontalSplitStopStartUntil(t *testing.T) {
|
|||
|
||||
// now restart the map until we get the right BlpPosition
|
||||
mysqlDaemon.BinlogPlayerEnabled = false
|
||||
ctx1, _ := context.WithTimeout(ctx, 5*time.Second)
|
||||
ctx1, cancel := context.WithTimeout(ctx, 5*time.Second)
|
||||
defer cancel()
|
||||
if err := bpm.RunUntil(ctx1, []*tabletmanagerdatapb.BlpPosition{
|
||||
{
|
||||
Uid: 1,
|
||||
|
|
|
@ -130,6 +130,119 @@ func (q *query) Rollback(ctx context.Context, request *querypb.RollbackRequest)
|
|||
return &querypb.RollbackResponse{}, nil
|
||||
}
|
||||
|
||||
// Prepare is part of the queryservice.QueryServer interface
|
||||
func (q *query) Prepare(ctx context.Context, request *querypb.PrepareRequest) (response *querypb.PrepareResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
if err := q.server.Prepare(ctx, request.Target, request.TransactionId, request.Dtid); err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.PrepareResponse{}, nil
|
||||
}
|
||||
|
||||
// CommitPrepared is part of the queryservice.QueryServer interface
|
||||
func (q *query) CommitPrepared(ctx context.Context, request *querypb.CommitPreparedRequest) (response *querypb.CommitPreparedResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
if err := q.server.CommitPrepared(ctx, request.Target, request.Dtid); err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.CommitPreparedResponse{}, nil
|
||||
}
|
||||
|
||||
// RollbackPrepared is part of the queryservice.QueryServer interface
|
||||
func (q *query) RollbackPrepared(ctx context.Context, request *querypb.RollbackPreparedRequest) (response *querypb.RollbackPreparedResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
if err := q.server.RollbackPrepared(ctx, request.Target, request.Dtid, request.TransactionId); err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.RollbackPreparedResponse{}, nil
|
||||
}
|
||||
|
||||
// CreateTransaction is part of the queryservice.QueryServer interface
|
||||
func (q *query) CreateTransaction(ctx context.Context, request *querypb.CreateTransactionRequest) (response *querypb.CreateTransactionResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
if err := q.server.CreateTransaction(ctx, request.Target, request.Dtid, request.Participants); err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.CreateTransactionResponse{}, nil
|
||||
}
|
||||
|
||||
// StartCommit is part of the queryservice.QueryServer interface
|
||||
func (q *query) StartCommit(ctx context.Context, request *querypb.StartCommitRequest) (response *querypb.StartCommitResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
if err := q.server.StartCommit(ctx, request.Target, request.TransactionId, request.Dtid); err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.StartCommitResponse{}, nil
|
||||
}
|
||||
|
||||
// SetRollback is part of the queryservice.QueryServer interface
|
||||
func (q *query) SetRollback(ctx context.Context, request *querypb.SetRollbackRequest) (response *querypb.SetRollbackResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
if err := q.server.SetRollback(ctx, request.Target, request.Dtid, request.TransactionId); err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.SetRollbackResponse{}, nil
|
||||
}
|
||||
|
||||
// ResolveTransaction is part of the queryservice.QueryServer interface
|
||||
func (q *query) ResolveTransaction(ctx context.Context, request *querypb.ResolveTransactionRequest) (response *querypb.ResolveTransactionResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
if err := q.server.ResolveTransaction(ctx, request.Target, request.Dtid); err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.ResolveTransactionResponse{}, nil
|
||||
}
|
||||
|
||||
// ReadTransaction is part of the queryservice.QueryServer interface
|
||||
func (q *query) ReadTransaction(ctx context.Context, request *querypb.ReadTransactionRequest) (response *querypb.ReadTransactionResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
ctx = callerid.NewContext(callinfo.GRPCCallInfo(ctx),
|
||||
request.EffectiveCallerId,
|
||||
request.ImmediateCallerId,
|
||||
)
|
||||
result, err := q.server.ReadTransaction(ctx, request.Target, request.Dtid)
|
||||
if err != nil {
|
||||
return nil, vterrors.ToGRPCError(err)
|
||||
}
|
||||
|
||||
return &querypb.ReadTransactionResponse{Metadata: result}, nil
|
||||
}
|
||||
|
||||
// BeginExecute is part of the queryservice.QueryServer interface
|
||||
func (q *query) BeginExecute(ctx context.Context, request *querypb.BeginExecuteRequest) (response *querypb.BeginExecuteResponse, err error) {
|
||||
defer q.server.HandlePanic(&err)
|
||||
|
|
|
@ -248,6 +248,182 @@ func (conn *gRPCQueryClient) Rollback(ctx context.Context, target *querypb.Targe
|
|||
return nil
|
||||
}
|
||||
|
||||
// Prepare executes a Prepare on the ongoing transaction.
|
||||
func (conn *gRPCQueryClient) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) error {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.PrepareRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
TransactionId: transactionID,
|
||||
Dtid: dtid,
|
||||
}
|
||||
_, err := conn.c.Prepare(ctx, req)
|
||||
if err != nil {
|
||||
return tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// CommitPrepared commits the prepared transaction.
|
||||
func (conn *gRPCQueryClient) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) error {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.CommitPreparedRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
Dtid: dtid,
|
||||
}
|
||||
_, err := conn.c.CommitPrepared(ctx, req)
|
||||
if err != nil {
|
||||
return tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RollbackPrepared rolls back the prepared transaction.
|
||||
func (conn *gRPCQueryClient) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) error {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.RollbackPreparedRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
TransactionId: originalID,
|
||||
Dtid: dtid,
|
||||
}
|
||||
_, err := conn.c.RollbackPrepared(ctx, req)
|
||||
if err != nil {
|
||||
return tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// CreateTransaction creates the metadata for a 2PC transaction.
|
||||
func (conn *gRPCQueryClient) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) error {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.CreateTransactionRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
Dtid: dtid,
|
||||
Participants: participants,
|
||||
}
|
||||
_, err := conn.c.CreateTransaction(ctx, req)
|
||||
if err != nil {
|
||||
return tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// StartCommit atomically commits the transaction along with the
|
||||
// decision to commit the associated 2pc transaction.
|
||||
func (conn *gRPCQueryClient) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) error {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.StartCommitRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
TransactionId: transactionID,
|
||||
Dtid: dtid,
|
||||
}
|
||||
_, err := conn.c.StartCommit(ctx, req)
|
||||
if err != nil {
|
||||
return tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// SetRollback transitions the 2pc transaction to the Rollback state.
|
||||
// If a transaction id is provided, that transaction is also rolled back.
|
||||
func (conn *gRPCQueryClient) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) error {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.SetRollbackRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
TransactionId: transactionID,
|
||||
Dtid: dtid,
|
||||
}
|
||||
_, err := conn.c.SetRollback(ctx, req)
|
||||
if err != nil {
|
||||
return tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// ResolveTransaction deletes the 2pc transaction metadata
|
||||
// essentially resolving it.
|
||||
func (conn *gRPCQueryClient) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) error {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.ResolveTransactionRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
Dtid: dtid,
|
||||
}
|
||||
_, err := conn.c.ResolveTransaction(ctx, req)
|
||||
if err != nil {
|
||||
return tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// ReadTransaction returns the metadata for the sepcified dtid.
|
||||
func (conn *gRPCQueryClient) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (*querypb.TransactionMetadata, error) {
|
||||
conn.mu.RLock()
|
||||
defer conn.mu.RUnlock()
|
||||
if conn.cc == nil {
|
||||
return nil, tabletconn.ConnClosed
|
||||
}
|
||||
|
||||
req := &querypb.ReadTransactionRequest{
|
||||
Target: target,
|
||||
EffectiveCallerId: callerid.EffectiveCallerIDFromContext(ctx),
|
||||
ImmediateCallerId: callerid.ImmediateCallerIDFromContext(ctx),
|
||||
Dtid: dtid,
|
||||
}
|
||||
response, err := conn.c.ReadTransaction(ctx, req)
|
||||
if err != nil {
|
||||
return nil, tabletconn.TabletErrorFromGRPC(err)
|
||||
}
|
||||
return response.Metadata, nil
|
||||
}
|
||||
|
||||
// BeginExecute starts a transaction and runs an Execute.
|
||||
func (conn *gRPCQueryClient) BeginExecute(ctx context.Context, target *querypb.Target, query string, bindVars map[string]interface{}, options *querypb.ExecuteOptions) (result *sqltypes.Result, transactionID int64, err error) {
|
||||
conn.mu.RLock()
|
||||
|
|
|
@ -34,6 +34,46 @@ func (e *ErrorQueryService) Rollback(ctx context.Context, target *querypb.Target
|
|||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// Prepare is part of QueryService interface
|
||||
func (e *ErrorQueryService) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// CommitPrepared is part of QueryService interface
|
||||
func (e *ErrorQueryService) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// RollbackPrepared is part of QueryService interface
|
||||
func (e *ErrorQueryService) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error) {
|
||||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// CreateTransaction is part of QueryService interface
|
||||
func (e *ErrorQueryService) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error) {
|
||||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// StartCommit is part of QueryService interface
|
||||
func (e *ErrorQueryService) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// SetRollback is part of QueryService interface
|
||||
func (e *ErrorQueryService) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error) {
|
||||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// ResolveTransaction is part of QueryService interface
|
||||
func (e *ErrorQueryService) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// ReadTransaction is part of QueryService interface
|
||||
func (e *ErrorQueryService) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
return nil, fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
}
|
||||
|
||||
// Execute is part of QueryService interface
|
||||
func (e *ErrorQueryService) Execute(ctx context.Context, target *querypb.Target, sql string, bindVariables map[string]interface{}, transactionID int64, options *querypb.ExecuteOptions) (*sqltypes.Result, error) {
|
||||
return nil, fmt.Errorf("ErrorQueryService does not implement any method")
|
||||
|
|
|
@ -28,6 +28,33 @@ type QueryService interface {
|
|||
// Rollback aborts the current transaction
|
||||
Rollback(ctx context.Context, target *querypb.Target, transactionID int64) error
|
||||
|
||||
// Prepare prepares the specified transaction.
|
||||
Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error)
|
||||
|
||||
// CommitPrepared commits the prepared transaction.
|
||||
CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error)
|
||||
|
||||
// RollbackPrepared rolls back the prepared transaction.
|
||||
RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error)
|
||||
|
||||
// CreateTransaction creates the metadata for a 2PC transaction.
|
||||
CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error)
|
||||
|
||||
// StartCommit atomically commits the transaction along with the
|
||||
// decision to commit the associated 2pc transaction.
|
||||
StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error)
|
||||
|
||||
// SetRollback transitions the 2pc transaction to the Rollback state.
|
||||
// If a transaction id is provided, that transaction is also rolled back.
|
||||
SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error)
|
||||
|
||||
// ResolveTransaction deletes the 2pc transaction metadata
|
||||
// essentially resolving it.
|
||||
ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error)
|
||||
|
||||
// ReadTransaction returns the metadata for the sepcified dtid.
|
||||
ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error)
|
||||
|
||||
// Query execution
|
||||
Execute(ctx context.Context, target *querypb.Target, sql string, bindVariables map[string]interface{}, transactionID int64, options *querypb.ExecuteOptions) (*sqltypes.Result, error)
|
||||
StreamExecute(ctx context.Context, target *querypb.Target, sql string, bindVariables map[string]interface{}, options *querypb.ExecuteOptions, sendReply func(*sqltypes.Result) error) error
|
||||
|
|
|
@ -63,6 +63,87 @@ func (_mr *_MockQueryServiceRecorder) Rollback(arg0, arg1, arg2 interface{}) *go
|
|||
return _mr.mock.ctrl.RecordCall(_mr.mock, "Rollback", arg0, arg1, arg2)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) Prepare(ctx context.Context, target *query.Target, transactionID int64, dtid string) error {
|
||||
ret := _m.ctrl.Call(_m, "Prepare", ctx, target, transactionID, dtid)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) Prepare(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "Prepare", arg0, arg1, arg2, arg3)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) CommitPrepared(ctx context.Context, target *query.Target, dtid string) error {
|
||||
ret := _m.ctrl.Call(_m, "CommitPrepared", ctx, target, dtid)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) CommitPrepared(arg0, arg1, arg2 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "CommitPrepared", arg0, arg1, arg2)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) RollbackPrepared(ctx context.Context, target *query.Target, dtid string, originalID int64) error {
|
||||
ret := _m.ctrl.Call(_m, "RollbackPrepared", ctx, target, dtid, originalID)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) RollbackPrepared(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "RollbackPrepared", arg0, arg1, arg2, arg3)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) CreateTransaction(ctx context.Context, target *query.Target, dtid string, participants []*query.Target) error {
|
||||
ret := _m.ctrl.Call(_m, "CreateTransaction", ctx, target, dtid, participants)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) CreateTransaction(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "CreateTransaction", arg0, arg1, arg2, arg3)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) StartCommit(ctx context.Context, target *query.Target, transactionID int64, dtid string) error {
|
||||
ret := _m.ctrl.Call(_m, "StartCommit", ctx, target, transactionID, dtid)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) StartCommit(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "StartCommit", arg0, arg1, arg2, arg3)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) SetRollback(ctx context.Context, target *query.Target, dtid string, transactionID int64) error {
|
||||
ret := _m.ctrl.Call(_m, "SetRollback", ctx, target, dtid, transactionID)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) SetRollback(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "SetRollback", arg0, arg1, arg2, arg3)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) ResolveTransaction(ctx context.Context, target *query.Target, dtid string) error {
|
||||
ret := _m.ctrl.Call(_m, "ResolveTransaction", ctx, target, dtid)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) ResolveTransaction(arg0, arg1, arg2 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "ResolveTransaction", arg0, arg1, arg2)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) ReadTransaction(ctx context.Context, target *query.Target, dtid string) (*query.TransactionMetadata, error) {
|
||||
ret := _m.ctrl.Call(_m, "ReadTransaction", ctx, target, dtid)
|
||||
ret0, _ := ret[0].(*query.TransactionMetadata)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
func (_mr *_MockQueryServiceRecorder) ReadTransaction(arg0, arg1, arg2 interface{}) *gomock.Call {
|
||||
return _mr.mock.ctrl.RecordCall(_mr.mock, "ReadTransaction", arg0, arg1, arg2)
|
||||
}
|
||||
|
||||
func (_m *MockQueryService) Execute(ctx context.Context, target *query.Target, sql string, bindVariables map[string]interface{}, transactionID int64, options *query.ExecuteOptions) (*sqltypes.Result, error) {
|
||||
ret := _m.ctrl.Call(_m, "Execute", ctx, target, sql, bindVariables, transactionID, options)
|
||||
ret0, _ := ret[0].(*sqltypes.Result)
|
||||
|
|
|
@ -34,11 +34,19 @@ type SandboxConn struct {
|
|||
|
||||
// These Count vars report how often the corresponding
|
||||
// functions were called.
|
||||
ExecCount sync2.AtomicInt64
|
||||
BeginCount sync2.AtomicInt64
|
||||
CommitCount sync2.AtomicInt64
|
||||
RollbackCount sync2.AtomicInt64
|
||||
AsTransactionCount sync2.AtomicInt64
|
||||
ExecCount sync2.AtomicInt64
|
||||
BeginCount sync2.AtomicInt64
|
||||
CommitCount sync2.AtomicInt64
|
||||
RollbackCount sync2.AtomicInt64
|
||||
AsTransactionCount sync2.AtomicInt64
|
||||
PrepareCount sync2.AtomicInt64
|
||||
CommitPreparedCount sync2.AtomicInt64
|
||||
RollbackPreparedCount sync2.AtomicInt64
|
||||
CreateTransactionCount sync2.AtomicInt64
|
||||
StartCommitCount sync2.AtomicInt64
|
||||
SetRollbackCount sync2.AtomicInt64
|
||||
ResolveTransactionCount sync2.AtomicInt64
|
||||
ReadTransactionCount sync2.AtomicInt64
|
||||
|
||||
// Queries stores the non-batch requests received.
|
||||
Queries []querytypes.BoundQuery
|
||||
|
@ -207,6 +215,57 @@ func (sbc *SandboxConn) Rollback(ctx context.Context, target *querypb.Target, tr
|
|||
return sbc.getError()
|
||||
}
|
||||
|
||||
// Prepare prepares the specified transaction.
|
||||
func (sbc *SandboxConn) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
sbc.PrepareCount.Add(1)
|
||||
return sbc.getError()
|
||||
}
|
||||
|
||||
// CommitPrepared commits the prepared transaction.
|
||||
func (sbc *SandboxConn) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
sbc.CommitPreparedCount.Add(1)
|
||||
return sbc.getError()
|
||||
}
|
||||
|
||||
// RollbackPrepared rolls back the prepared transaction.
|
||||
func (sbc *SandboxConn) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error) {
|
||||
sbc.RollbackPreparedCount.Add(1)
|
||||
return sbc.getError()
|
||||
}
|
||||
|
||||
// CreateTransaction creates the metadata for a 2PC transaction.
|
||||
func (sbc *SandboxConn) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error) {
|
||||
sbc.CreateTransactionCount.Add(1)
|
||||
return sbc.getError()
|
||||
}
|
||||
|
||||
// StartCommit atomically commits the transaction along with the
|
||||
// decision to commit the associated 2pc transaction.
|
||||
func (sbc *SandboxConn) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
sbc.StartCommitCount.Add(1)
|
||||
return sbc.getError()
|
||||
}
|
||||
|
||||
// SetRollback transitions the 2pc transaction to the Rollback state.
|
||||
// If a transaction id is provided, that transaction is also rolled back.
|
||||
func (sbc *SandboxConn) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error) {
|
||||
sbc.SetRollbackCount.Add(1)
|
||||
return sbc.getError()
|
||||
}
|
||||
|
||||
// ResolveTransaction deletes the 2pc transaction metadata
|
||||
// essentially resolving it.
|
||||
func (sbc *SandboxConn) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
sbc.ResolveTransactionCount.Add(1)
|
||||
return sbc.getError()
|
||||
}
|
||||
|
||||
// ReadTransaction returns the metadata for the sepcified dtid.
|
||||
func (sbc *SandboxConn) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
sbc.ReadTransactionCount.Add(1)
|
||||
return nil, sbc.getError()
|
||||
}
|
||||
|
||||
// BeginExecute is part of the TabletConn interface.
|
||||
func (sbc *SandboxConn) BeginExecute(ctx context.Context, target *querypb.Target, query string, bindVars map[string]interface{}, options *querypb.ExecuteOptions) (*sqltypes.Result, int64, error) {
|
||||
transactionID, err := sbc.Begin(ctx, target)
|
||||
|
|
|
@ -107,6 +107,14 @@ type TabletConn interface {
|
|||
Begin(ctx context.Context, target *querypb.Target) (transactionID int64, err error)
|
||||
Commit(ctx context.Context, target *querypb.Target, transactionID int64) error
|
||||
Rollback(ctx context.Context, target *querypb.Target, transactionID int64) error
|
||||
Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error)
|
||||
CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error)
|
||||
RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error)
|
||||
CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error)
|
||||
StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error)
|
||||
SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error)
|
||||
ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error)
|
||||
ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error)
|
||||
|
||||
// Combo RPC calls: they execute both a Begin and another call.
|
||||
// Note even if error is set, transactionID may be returned
|
||||
|
|
|
@ -153,6 +153,159 @@ func (f *FakeQueryService) Rollback(ctx context.Context, target *querypb.Target,
|
|||
return nil
|
||||
}
|
||||
|
||||
const Dtid string = "aa"
|
||||
|
||||
// Prepare is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
if f.HasError {
|
||||
return f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "Prepare", target)
|
||||
if transactionID != CommitTransactionID {
|
||||
f.t.Errorf("Prepare: invalid TransactionID: got %v expected %v", transactionID, CommitTransactionID)
|
||||
}
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("Prepare: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// CommitPrepared is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
if f.HasError {
|
||||
return f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "CommitPrepared", target)
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("CommitPrepared: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RollbackPrepared is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error) {
|
||||
if f.HasError {
|
||||
return f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "RollbackPrepared", target)
|
||||
if originalID != RollbackTransactionID {
|
||||
f.t.Errorf("RollbackPrepared: invalid TransactionID: got %v expected %v", originalID, RollbackTransactionID)
|
||||
}
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("RollbackPrepared: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var Participants = []*querypb.Target{{
|
||||
Keyspace: "ks0",
|
||||
Shard: "0",
|
||||
}, {
|
||||
Keyspace: "ks1",
|
||||
Shard: "1",
|
||||
}}
|
||||
|
||||
// CreateTransaction is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error) {
|
||||
if f.HasError {
|
||||
return f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "CreateTransaction", target)
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("CreateTransaction: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
if !reflect.DeepEqual(participants, Participants) {
|
||||
f.t.Errorf("invalid CreateTransaction participants: got %v, expected %v", participants, Participants)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// StartCommit is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
if f.HasError {
|
||||
return f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "StartCommit", target)
|
||||
if transactionID != CommitTransactionID {
|
||||
f.t.Errorf("StartCommit: invalid TransactionID: got %v expected %v", transactionID, CommitTransactionID)
|
||||
}
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("StartCommit: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// SetRollback is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error) {
|
||||
if f.HasError {
|
||||
return f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "SetRollback", target)
|
||||
if transactionID != CommitTransactionID {
|
||||
f.t.Errorf("SetRollback: invalid TransactionID: got %v expected %v", transactionID, CommitTransactionID)
|
||||
}
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("SetRollback: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// ResolveTransaction is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
if f.HasError {
|
||||
return f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "ResolveTransaction", target)
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("ResolveTransaction: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var Metadata = &querypb.TransactionMetadata{
|
||||
Dtid: "aa",
|
||||
State: querypb.TransactionState_PREPARE,
|
||||
TimeCreated: 1,
|
||||
TimeUpdated: 2,
|
||||
Participants: Participants,
|
||||
}
|
||||
|
||||
// ReadTransaction is part of the queryservice.QueryService interface
|
||||
func (f *FakeQueryService) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
if f.HasError {
|
||||
return nil, f.TabletError
|
||||
}
|
||||
if f.Panics {
|
||||
panic(fmt.Errorf("test-triggered panic"))
|
||||
}
|
||||
f.checkTargetCallerID(ctx, "ReadTransaction", target)
|
||||
if dtid != Dtid {
|
||||
f.t.Errorf("ReadTransaction: invalid dtid: got %s expected %s", dtid, Dtid)
|
||||
}
|
||||
return Metadata, nil
|
||||
}
|
||||
|
||||
const ExecuteQuery = "executeQuery"
|
||||
|
||||
var ExecuteBindVars = map[string]interface{}{
|
||||
|
|
|
@ -169,6 +169,219 @@ func testRollbackPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQuerySe
|
|||
})
|
||||
}
|
||||
|
||||
func testPrepare(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testPrepare")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
err := conn.Prepare(ctx, TestTarget, CommitTransactionID, Dtid)
|
||||
if err != nil {
|
||||
t.Fatalf("Prepare failed: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func testPrepareError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testPrepareError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "Prepare", func(ctx context.Context) error {
|
||||
return conn.Prepare(ctx, TestTarget, CommitTransactionID, Dtid)
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testPreparePanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testPreparePanics")
|
||||
testPanicHelper(t, f, "Prepare", func(ctx context.Context) error {
|
||||
return conn.Prepare(ctx, TestTarget, CommitTransactionID, Dtid)
|
||||
})
|
||||
}
|
||||
|
||||
func testCommitPrepared(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testCommitPrepared")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
err := conn.CommitPrepared(ctx, TestTarget, Dtid)
|
||||
if err != nil {
|
||||
t.Fatalf("CommitPrepared failed: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func testCommitPreparedError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testCommitPreparedError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "CommitPrepared", func(ctx context.Context) error {
|
||||
return conn.CommitPrepared(ctx, TestTarget, Dtid)
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testCommitPreparedPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testCommitPreparedPanics")
|
||||
testPanicHelper(t, f, "CommitPrepared", func(ctx context.Context) error {
|
||||
return conn.CommitPrepared(ctx, TestTarget, Dtid)
|
||||
})
|
||||
}
|
||||
|
||||
func testRollbackPrepared(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testRollbackPrepared")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
err := conn.RollbackPrepared(ctx, TestTarget, Dtid, RollbackTransactionID)
|
||||
if err != nil {
|
||||
t.Fatalf("RollbackPrepared failed: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func testRollbackPreparedError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testRollbackPreparedError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "RollbackPrepared", func(ctx context.Context) error {
|
||||
return conn.RollbackPrepared(ctx, TestTarget, Dtid, RollbackTransactionID)
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testRollbackPreparedPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testRollbackPreparedPanics")
|
||||
testPanicHelper(t, f, "RollbackPrepared", func(ctx context.Context) error {
|
||||
return conn.RollbackPrepared(ctx, TestTarget, Dtid, RollbackTransactionID)
|
||||
})
|
||||
}
|
||||
|
||||
func testCreateTransaction(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testCreateTransaction")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
err := conn.CreateTransaction(ctx, TestTarget, Dtid, Participants)
|
||||
if err != nil {
|
||||
t.Fatalf("CreateTransaction failed: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func testCreateTransactionError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testCreateTransactionError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "CreateTransaction", func(ctx context.Context) error {
|
||||
return conn.CreateTransaction(ctx, TestTarget, Dtid, Participants)
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testCreateTransactionPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testCreateTransactionPanics")
|
||||
testPanicHelper(t, f, "CreateTransaction", func(ctx context.Context) error {
|
||||
return conn.CreateTransaction(ctx, TestTarget, Dtid, Participants)
|
||||
})
|
||||
}
|
||||
|
||||
func testStartCommit(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testStartCommit")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
err := conn.StartCommit(ctx, TestTarget, CommitTransactionID, Dtid)
|
||||
if err != nil {
|
||||
t.Fatalf("StartCommit failed: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func testStartCommitError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testStartCommitError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "StartCommit", func(ctx context.Context) error {
|
||||
return conn.StartCommit(ctx, TestTarget, CommitTransactionID, Dtid)
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testStartCommitPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testStartCommitPanics")
|
||||
testPanicHelper(t, f, "StartCommit", func(ctx context.Context) error {
|
||||
return conn.StartCommit(ctx, TestTarget, CommitTransactionID, Dtid)
|
||||
})
|
||||
}
|
||||
|
||||
func testSetRollback(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testSetRollback")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
err := conn.SetRollback(ctx, TestTarget, Dtid, RollbackTransactionID)
|
||||
if err != nil {
|
||||
t.Fatalf("SetRollback failed: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func testSetRollbackError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testSetRollbackError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "SetRollback", func(ctx context.Context) error {
|
||||
return conn.SetRollback(ctx, TestTarget, Dtid, RollbackTransactionID)
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testSetRollbackPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testSetRollbackPanics")
|
||||
testPanicHelper(t, f, "SetRollback", func(ctx context.Context) error {
|
||||
return conn.SetRollback(ctx, TestTarget, Dtid, RollbackTransactionID)
|
||||
})
|
||||
}
|
||||
|
||||
func testResolveTransaction(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testResolveTransaction")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
err := conn.ResolveTransaction(ctx, TestTarget, Dtid)
|
||||
if err != nil {
|
||||
t.Fatalf("ResolveTransaction failed: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func testResolveTransactionError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testResolveTransactionError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "ResolveTransaction", func(ctx context.Context) error {
|
||||
return conn.ResolveTransaction(ctx, TestTarget, Dtid)
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testResolveTransactionPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testResolveTransactionPanics")
|
||||
testPanicHelper(t, f, "ResolveTransaction", func(ctx context.Context) error {
|
||||
return conn.ResolveTransaction(ctx, TestTarget, Dtid)
|
||||
})
|
||||
}
|
||||
|
||||
func testReadTransaction(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testReadTransaction")
|
||||
ctx := context.Background()
|
||||
ctx = callerid.NewContext(ctx, TestCallerID, TestVTGateCallerID)
|
||||
metadata, err := conn.ReadTransaction(ctx, TestTarget, Dtid)
|
||||
if err != nil {
|
||||
t.Fatalf("ReadTransaction failed: %v", err)
|
||||
}
|
||||
if !reflect.DeepEqual(metadata, Metadata) {
|
||||
t.Errorf("Unexpected result from Execute: got %v wanted %v", metadata, Metadata)
|
||||
}
|
||||
}
|
||||
|
||||
func testReadTransactionError(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testReadTransactionError")
|
||||
f.HasError = true
|
||||
testErrorHelper(t, f, "ReadTransaction", func(ctx context.Context) error {
|
||||
_, err := conn.ReadTransaction(ctx, TestTarget, Dtid)
|
||||
return err
|
||||
})
|
||||
f.HasError = false
|
||||
}
|
||||
|
||||
func testReadTransactionPanics(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testReadTransactionPanics")
|
||||
testPanicHelper(t, f, "ReadTransaction", func(ctx context.Context) error {
|
||||
_, err := conn.ReadTransaction(ctx, TestTarget, Dtid)
|
||||
return err
|
||||
})
|
||||
}
|
||||
|
||||
func testExecute(t *testing.T, conn tabletconn.TabletConn, f *FakeQueryService) {
|
||||
t.Log("testExecute")
|
||||
f.ExpectedTransactionID = ExecuteTransactionID
|
||||
|
@ -651,6 +864,14 @@ func TestSuite(t *testing.T, protocol string, tablet *topodatapb.Tablet, fake *F
|
|||
testBegin,
|
||||
testCommit,
|
||||
testRollback,
|
||||
testPrepare,
|
||||
testCommitPrepared,
|
||||
testRollbackPrepared,
|
||||
testCreateTransaction,
|
||||
testStartCommit,
|
||||
testSetRollback,
|
||||
testResolveTransaction,
|
||||
testReadTransaction,
|
||||
testExecute,
|
||||
testBeginExecute,
|
||||
testStreamExecute,
|
||||
|
@ -664,6 +885,14 @@ func TestSuite(t *testing.T, protocol string, tablet *topodatapb.Tablet, fake *F
|
|||
testBeginError,
|
||||
testCommitError,
|
||||
testRollbackError,
|
||||
testPrepareError,
|
||||
testCommitPreparedError,
|
||||
testRollbackPreparedError,
|
||||
testCreateTransactionError,
|
||||
testStartCommitError,
|
||||
testSetRollbackError,
|
||||
testResolveTransactionError,
|
||||
testReadTransactionError,
|
||||
testExecuteError,
|
||||
testBeginExecuteErrorInBegin,
|
||||
testBeginExecuteErrorInExecute,
|
||||
|
@ -678,6 +907,14 @@ func TestSuite(t *testing.T, protocol string, tablet *topodatapb.Tablet, fake *F
|
|||
testBeginPanics,
|
||||
testCommitPanics,
|
||||
testRollbackPanics,
|
||||
testPreparePanics,
|
||||
testCommitPreparedPanics,
|
||||
testRollbackPreparedPanics,
|
||||
testCreateTransactionPanics,
|
||||
testStartCommitPanics,
|
||||
testSetRollbackPanics,
|
||||
testResolveTransactionPanics,
|
||||
testReadTransactionPanics,
|
||||
testExecutePanics,
|
||||
testBeginExecutePanics,
|
||||
testStreamExecutePanics,
|
||||
|
|
|
@ -186,7 +186,8 @@ func TestTxPoolBeginWithShortDeadline(t *testing.T) {
|
|||
defer txPool.Close()
|
||||
|
||||
// A timeout < 10ms should always fail.
|
||||
ctx, _ := context.WithTimeout(context.Background(), 5*time.Millisecond)
|
||||
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Millisecond)
|
||||
defer cancel()
|
||||
_, err := txPool.Begin(ctx)
|
||||
want := "tx_pool_full: Transaction pool connection limit exceeded"
|
||||
if err == nil || err.Error() != want {
|
||||
|
|
|
@ -114,7 +114,7 @@ func (dg *discoveryGateway) Execute(ctx context.Context, keyspace, shard string,
|
|||
qr, innerErr = conn.Execute(ctx, target, query, bindVars, transactionID, options)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, transactionID != 0, false)
|
||||
return qr, err
|
||||
}
|
||||
|
||||
|
@ -126,7 +126,7 @@ func (dg *discoveryGateway) ExecuteBatch(ctx context.Context, keyspace, shard st
|
|||
qrs, innerErr = conn.ExecuteBatch(ctx, target, queries, asTransaction, transactionID, options)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, transactionID != 0, false)
|
||||
return qrs, err
|
||||
}
|
||||
|
||||
|
@ -137,7 +137,7 @@ func (dg *discoveryGateway) StreamExecute(ctx context.Context, keyspace, shard s
|
|||
var err error
|
||||
stream, err = conn.StreamExecute(ctx, target, query, bindVars, options)
|
||||
return err
|
||||
}, 0, true)
|
||||
}, false, true)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@ -153,7 +153,7 @@ func (dg *discoveryGateway) Begin(ctx context.Context, keyspace string, shard st
|
|||
transactionID, innerErr = conn.Begin(ctx, target)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return transactionID, err
|
||||
}
|
||||
|
||||
|
@ -164,7 +164,7 @@ func (dg *discoveryGateway) Commit(ctx context.Context, keyspace, shard string,
|
|||
innerErr := conn.Commit(ctx, target, transactionID)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// Rollback rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
|
@ -174,7 +174,89 @@ func (dg *discoveryGateway) Rollback(ctx context.Context, keyspace, shard string
|
|||
innerErr := conn.Rollback(ctx, target, transactionID)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// Prepare rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) Prepare(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, transactionID int64, dtid string) error {
|
||||
return dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.Prepare(ctx, target, transactionID, dtid)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// CommitPrepared rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) CommitPrepared(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (err error) {
|
||||
return dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.CommitPrepared(ctx, target, dtid)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// RollbackPrepared rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) RollbackPrepared(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, originalID int64) (err error) {
|
||||
return dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.RollbackPrepared(ctx, target, dtid, originalID)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// CreateTransaction rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) CreateTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, participants []*querypb.Target) (err error) {
|
||||
return dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.CreateTransaction(ctx, target, dtid, participants)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// StartCommit rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) StartCommit(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, transactionID int64, dtid string) (err error) {
|
||||
return dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.StartCommit(ctx, target, transactionID, dtid)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// SetRollback rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) SetRollback(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, transactionID int64) (err error) {
|
||||
return dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.SetRollback(ctx, target, dtid, transactionID)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// ResolveTransaction rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) ResolveTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (err error) {
|
||||
return dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.ResolveTransaction(ctx, target, dtid)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// ReadTransaction rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (dg *discoveryGateway) ReadTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
err = dg.withRetry(ctx, keyspace, shard, tabletType, func(conn tabletconn.TabletConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
var innerErr error
|
||||
metadata, innerErr = conn.ReadTransaction(ctx, target, dtid)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, false, false)
|
||||
return metadata, err
|
||||
}
|
||||
|
||||
// BeginExecute executes a begin and the non-streaming query for the
|
||||
|
@ -186,7 +268,7 @@ func (dg *discoveryGateway) BeginExecute(ctx context.Context, keyspace, shard st
|
|||
qr, transactionID, innerErr = conn.BeginExecute(ctx, target, query, bindVars, options)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return qr, transactionID, err
|
||||
}
|
||||
|
||||
|
@ -199,7 +281,7 @@ func (dg *discoveryGateway) BeginExecuteBatch(ctx context.Context, keyspace, sha
|
|||
qrs, transactionID, innerErr = conn.BeginExecuteBatch(ctx, target, queries, asTransaction, options)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return qrs, transactionID, err
|
||||
}
|
||||
|
||||
|
@ -214,7 +296,7 @@ func (dg *discoveryGateway) SplitQuery(ctx context.Context, keyspace, shard stri
|
|||
}, splitColumn, splitCount)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -241,7 +323,7 @@ func (dg *discoveryGateway) SplitQueryV2(
|
|||
}, splitColumns, splitCount, numRowsPerQueryPart, algorithm)
|
||||
dg.updateStats(keyspace, shard, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -253,7 +335,7 @@ func (dg *discoveryGateway) UpdateStream(ctx context.Context, keyspace, shard st
|
|||
var err error
|
||||
stream, err = conn.UpdateStream(ctx, target, position, timestamp)
|
||||
return err
|
||||
}, 0, true)
|
||||
}, false, true)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@ -286,10 +368,9 @@ func (dg *discoveryGateway) CacheStatus() TabletCacheStatusList {
|
|||
// the middle of a transaction. While returning the error check if it maybe a result of
|
||||
// a resharding event, and set the re-resolve bit and let the upper layers
|
||||
// re-resolve and retry.
|
||||
func (dg *discoveryGateway) withRetry(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, action func(conn tabletconn.TabletConn, target *querypb.Target) error, transactionID int64, isStreaming bool) error {
|
||||
func (dg *discoveryGateway) withRetry(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, action func(conn tabletconn.TabletConn, target *querypb.Target) error, inTransaction, isStreaming bool) error {
|
||||
var tabletLastUsed *topodatapb.Tablet
|
||||
var err error
|
||||
inTransaction := (transactionID != 0)
|
||||
invalidTablets := make(map[string]bool)
|
||||
|
||||
for i := 0; i < dg.retryCount+1; i++ {
|
||||
|
@ -332,7 +413,7 @@ func (dg *discoveryGateway) withRetry(ctx context.Context, keyspace, shard strin
|
|||
}
|
||||
|
||||
err = action(conn, ts.Target)
|
||||
if dg.canRetry(ctx, err, transactionID, isStreaming) {
|
||||
if dg.canRetry(ctx, err, inTransaction, isStreaming) {
|
||||
invalidTablets[ts.Key] = true
|
||||
continue
|
||||
}
|
||||
|
@ -344,7 +425,7 @@ func (dg *discoveryGateway) withRetry(ctx context.Context, keyspace, shard strin
|
|||
// canRetry determines whether a query can be retried or not.
|
||||
// OperationalErrors like retry/fatal are retryable if query is not in a txn.
|
||||
// All other errors are non-retryable.
|
||||
func (dg *discoveryGateway) canRetry(ctx context.Context, err error, transactionID int64, isStreaming bool) bool {
|
||||
func (dg *discoveryGateway) canRetry(ctx context.Context, err error, inTransaction, isStreaming bool) bool {
|
||||
if err == nil {
|
||||
return false
|
||||
}
|
||||
|
@ -369,7 +450,6 @@ func (dg *discoveryGateway) canRetry(ctx context.Context, err error, transaction
|
|||
case vtrpcpb.ErrorCode_QUERY_NOT_SERVED:
|
||||
// Retry on QUERY_NOT_SERVED and
|
||||
// INTERNAL_ERROR if not in a transaction.
|
||||
inTransaction := (transactionID != 0)
|
||||
return !inTransaction
|
||||
default:
|
||||
// Not retry for RESOURCE_EXHAUSTED and normal
|
||||
|
|
|
@ -53,6 +53,33 @@ type Gateway interface {
|
|||
// Rollback rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
Rollback(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, transactionID int64) error
|
||||
|
||||
// Prepare prepares the specified transaction.
|
||||
Prepare(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, transactionID int64, dtid string) (err error)
|
||||
|
||||
// CommitPrepared commits the prepared transaction.
|
||||
CommitPrepared(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (err error)
|
||||
|
||||
// RollbackPrepared commits the prepared transaction.
|
||||
RollbackPrepared(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, originalID int64) (err error)
|
||||
|
||||
// CreateTransaction creates the metadata for a 2PC transaction.
|
||||
CreateTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, participants []*querypb.Target) (err error)
|
||||
|
||||
// StartCommit atomically commits the transaction along with the
|
||||
// decision to commit the associated 2pc transaction.
|
||||
StartCommit(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, transactionID int64, dtid string) (err error)
|
||||
|
||||
// SetRollback transitions the 2pc transaction to the Rollback state.
|
||||
// If a transaction id is provided, that transaction is also rolled back.
|
||||
SetRollback(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, transactionID int64) (err error)
|
||||
|
||||
// ResolveTransaction deletes the 2pc transaction metadata
|
||||
// essentially resolving it.
|
||||
ResolveTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (err error)
|
||||
|
||||
// ReadTransaction returns the metadata for the sepcified dtid.
|
||||
ReadTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (metadata *querypb.TransactionMetadata, err error)
|
||||
|
||||
// BeginExecute executes a begin and the non-streaming query
|
||||
// for the specified keyspace, shard, and tablet type.
|
||||
BeginExecute(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, query string, bindVars map[string]interface{}, options *querypb.ExecuteOptions) (*sqltypes.Result, int64, error)
|
||||
|
|
|
@ -147,7 +147,7 @@ func (lg *l2VTGateGateway) Execute(ctx context.Context, keyspace, shard string,
|
|||
qr, innerErr = conn.conn.Execute(ctx, target, query, bindVars, transactionID, options)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, transactionID != 0, false)
|
||||
return qr, err
|
||||
}
|
||||
|
||||
|
@ -159,7 +159,7 @@ func (lg *l2VTGateGateway) ExecuteBatch(ctx context.Context, keyspace, shard str
|
|||
qrs, innerErr = conn.conn.ExecuteBatch(ctx, target, queries, asTransaction, transactionID, options)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, transactionID != 0, false)
|
||||
return qrs, err
|
||||
}
|
||||
|
||||
|
@ -170,7 +170,7 @@ func (lg *l2VTGateGateway) StreamExecute(ctx context.Context, keyspace, shard st
|
|||
var err error
|
||||
stream, err = conn.conn.StreamExecute(ctx, target, query, bindVars, options)
|
||||
return err
|
||||
}, 0, true)
|
||||
}, false, true)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@ -186,7 +186,7 @@ func (lg *l2VTGateGateway) Begin(ctx context.Context, keyspace string, shard str
|
|||
transactionID, innerErr = conn.conn.Begin(ctx, target)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return transactionID, err
|
||||
}
|
||||
|
||||
|
@ -197,7 +197,7 @@ func (lg *l2VTGateGateway) Commit(ctx context.Context, keyspace, shard string, t
|
|||
innerErr := conn.conn.Commit(ctx, target, transactionID)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// Rollback rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
|
@ -207,7 +207,89 @@ func (lg *l2VTGateGateway) Rollback(ctx context.Context, keyspace, shard string,
|
|||
innerErr := conn.conn.Rollback(ctx, target, transactionID)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, transactionID, false)
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// Prepare rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) Prepare(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, transactionID int64, dtid string) error {
|
||||
return lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.conn.Prepare(ctx, target, transactionID, dtid)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// CommitPrepared rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) CommitPrepared(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (err error) {
|
||||
return lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.conn.CommitPrepared(ctx, target, dtid)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// RollbackPrepared rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) RollbackPrepared(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, originalID int64) (err error) {
|
||||
return lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.conn.RollbackPrepared(ctx, target, dtid, originalID)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// CreateTransaction rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) CreateTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, participants []*querypb.Target) (err error) {
|
||||
return lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.conn.CreateTransaction(ctx, target, dtid, participants)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// StartCommit rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) StartCommit(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, transactionID int64, dtid string) (err error) {
|
||||
return lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.conn.StartCommit(ctx, target, transactionID, dtid)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// SetRollback rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) SetRollback(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string, transactionID int64) (err error) {
|
||||
return lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.conn.SetRollback(ctx, target, dtid, transactionID)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// ResolveTransaction rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) ResolveTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (err error) {
|
||||
return lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
innerErr := conn.conn.ResolveTransaction(ctx, target, dtid)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, true, false)
|
||||
}
|
||||
|
||||
// ReadTransaction rolls back the current transaction for the specified keyspace, shard, and tablet type.
|
||||
func (lg *l2VTGateGateway) ReadTransaction(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
err = lg.withRetry(ctx, keyspace, shard, tabletType, func(conn *l2VTGateConn, target *querypb.Target) error {
|
||||
startTime := time.Now()
|
||||
var innerErr error
|
||||
metadata, innerErr = conn.conn.ReadTransaction(ctx, target, dtid)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, false, false)
|
||||
return metadata, err
|
||||
}
|
||||
|
||||
// BeginExecute executes a begin and the non-streaming query for the
|
||||
|
@ -219,7 +301,7 @@ func (lg *l2VTGateGateway) BeginExecute(ctx context.Context, keyspace, shard str
|
|||
qr, transactionID, innerErr = conn.conn.BeginExecute(ctx, target, query, bindVars, options)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return qr, transactionID, err
|
||||
}
|
||||
|
||||
|
@ -232,7 +314,7 @@ func (lg *l2VTGateGateway) BeginExecuteBatch(ctx context.Context, keyspace, shar
|
|||
qrs, transactionID, innerErr = conn.conn.BeginExecuteBatch(ctx, target, queries, asTransaction, options)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return qrs, transactionID, err
|
||||
}
|
||||
|
||||
|
@ -247,7 +329,7 @@ func (lg *l2VTGateGateway) SplitQuery(ctx context.Context, keyspace, shard strin
|
|||
}, splitColumn, splitCount)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -274,7 +356,7 @@ func (lg *l2VTGateGateway) SplitQueryV2(
|
|||
}, splitColumns, splitCount, numRowsPerQueryPart, algorithm)
|
||||
lg.updateStats(conn, tabletType, startTime, innerErr)
|
||||
return innerErr
|
||||
}, 0, false)
|
||||
}, false, false)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -285,7 +367,7 @@ func (lg *l2VTGateGateway) UpdateStream(ctx context.Context, keyspace, shard str
|
|||
var err error
|
||||
stream, err = conn.conn.UpdateStream(ctx, target, position, timestamp)
|
||||
return err
|
||||
}, 0, true)
|
||||
}, false, true)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@ -349,9 +431,7 @@ func (lg *l2VTGateGateway) getConn(keyspace, shard string) (*l2VTGateConn, error
|
|||
// the middle of a transaction. While returning the error check if it maybe a result of
|
||||
// a resharding event, and set the re-resolve bit and let the upper layers
|
||||
// re-resolve and retry.
|
||||
func (lg *l2VTGateGateway) withRetry(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, action func(conn *l2VTGateConn, target *querypb.Target) error, transactionID int64, isStreaming bool) error {
|
||||
inTransaction := (transactionID != 0)
|
||||
|
||||
func (lg *l2VTGateGateway) withRetry(ctx context.Context, keyspace, shard string, tabletType topodatapb.TabletType, action func(conn *l2VTGateConn, target *querypb.Target) error, inTransaction, isStreaming bool) error {
|
||||
conn, err := lg.getConn(keyspace, shard)
|
||||
if err != nil {
|
||||
return fmt.Errorf("no configured destination for %v/%v: %v", keyspace, shard, err)
|
||||
|
@ -364,7 +444,7 @@ func (lg *l2VTGateGateway) withRetry(ctx context.Context, keyspace, shard string
|
|||
|
||||
for i := 0; i < lg.retryCount+1; i++ {
|
||||
err = action(conn, target)
|
||||
if lg.canRetry(ctx, err, transactionID, isStreaming) {
|
||||
if lg.canRetry(ctx, err, inTransaction, isStreaming) {
|
||||
continue
|
||||
}
|
||||
break
|
||||
|
@ -375,7 +455,7 @@ func (lg *l2VTGateGateway) withRetry(ctx context.Context, keyspace, shard string
|
|||
// canRetry determines whether a query can be retried or not.
|
||||
// OperationalErrors like retry/fatal are retryable if query is not in a txn.
|
||||
// All other errors are non-retryable.
|
||||
func (lg *l2VTGateGateway) canRetry(ctx context.Context, err error, transactionID int64, isStreaming bool) bool {
|
||||
func (lg *l2VTGateGateway) canRetry(ctx context.Context, err error, inTransaction, isStreaming bool) bool {
|
||||
if err == nil {
|
||||
return false
|
||||
}
|
||||
|
@ -400,7 +480,6 @@ func (lg *l2VTGateGateway) canRetry(ctx context.Context, err error, transactionI
|
|||
case vtrpcpb.ErrorCode_QUERY_NOT_SERVED:
|
||||
// Retry on QUERY_NOT_SERVED and
|
||||
// INTERNAL_ERROR if not in a transaction.
|
||||
inTransaction := (transactionID != 0)
|
||||
return !inTransaction
|
||||
default:
|
||||
// Not retry for RESOURCE_EXHAUSTED and normal
|
||||
|
|
|
@ -57,6 +57,38 @@ func (ga *gatewayAdapter) Rollback(ctx context.Context, target *querypb.Target,
|
|||
return ga.g.Rollback(ctx, target.Keyspace, target.Shard, target.TabletType, transactionID)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return ga.g.Prepare(ctx, target.Keyspace, target.Shard, target.TabletType, transactionID, dtid)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return ga.g.CommitPrepared(ctx, target.Keyspace, target.Shard, target.TabletType, dtid)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error) {
|
||||
return ga.g.RollbackPrepared(ctx, target.Keyspace, target.Shard, target.TabletType, dtid, originalID)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error) {
|
||||
return ga.g.CreateTransaction(ctx, target.Keyspace, target.Shard, target.TabletType, dtid, participants)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return ga.g.StartCommit(ctx, target.Keyspace, target.Shard, target.TabletType, transactionID, dtid)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error) {
|
||||
return ga.g.SetRollback(ctx, target.Keyspace, target.Shard, target.TabletType, dtid, transactionID)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return ga.g.ResolveTransaction(ctx, target.Keyspace, target.Shard, target.TabletType, dtid)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
return ga.g.ReadTransaction(ctx, target.Keyspace, target.Shard, target.TabletType, dtid)
|
||||
}
|
||||
|
||||
func (ga *gatewayAdapter) BeginExecute(ctx context.Context, target *querypb.Target, query string, bindVars map[string]interface{}, options *querypb.ExecuteOptions) (result *sqltypes.Result, transactionID int64, err error) {
|
||||
return ga.g.BeginExecute(ctx, target.Keyspace, target.Shard, target.TabletType, query, bindVars, options)
|
||||
}
|
||||
|
|
|
@ -80,6 +80,46 @@ func (l *L2VTGate) Rollback(ctx context.Context, target *querypb.Target, transac
|
|||
return l.gateway.Rollback(ctx, target.Keyspace, target.Shard, target.TabletType, transactionID)
|
||||
}
|
||||
|
||||
// Prepare is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) Prepare(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return l.gateway.Prepare(ctx, target.Keyspace, target.Shard, target.TabletType, transactionID, dtid)
|
||||
}
|
||||
|
||||
// CommitPrepared is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) CommitPrepared(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return l.gateway.CommitPrepared(ctx, target.Keyspace, target.Shard, target.TabletType, dtid)
|
||||
}
|
||||
|
||||
// RollbackPrepared is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) RollbackPrepared(ctx context.Context, target *querypb.Target, dtid string, originalID int64) (err error) {
|
||||
return l.gateway.RollbackPrepared(ctx, target.Keyspace, target.Shard, target.TabletType, dtid, originalID)
|
||||
}
|
||||
|
||||
// CreateTransaction is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) CreateTransaction(ctx context.Context, target *querypb.Target, dtid string, participants []*querypb.Target) (err error) {
|
||||
return l.gateway.CreateTransaction(ctx, target.Keyspace, target.Shard, target.TabletType, dtid, participants)
|
||||
}
|
||||
|
||||
// StartCommit is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) StartCommit(ctx context.Context, target *querypb.Target, transactionID int64, dtid string) (err error) {
|
||||
return l.gateway.StartCommit(ctx, target.Keyspace, target.Shard, target.TabletType, transactionID, dtid)
|
||||
}
|
||||
|
||||
// SetRollback is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) SetRollback(ctx context.Context, target *querypb.Target, dtid string, transactionID int64) (err error) {
|
||||
return l.gateway.SetRollback(ctx, target.Keyspace, target.Shard, target.TabletType, dtid, transactionID)
|
||||
}
|
||||
|
||||
// ResolveTransaction is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) ResolveTransaction(ctx context.Context, target *querypb.Target, dtid string) (err error) {
|
||||
return l.gateway.ResolveTransaction(ctx, target.Keyspace, target.Shard, target.TabletType, dtid)
|
||||
}
|
||||
|
||||
// ReadTransaction is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) ReadTransaction(ctx context.Context, target *querypb.Target, dtid string) (metadata *querypb.TransactionMetadata, err error) {
|
||||
return l.gateway.ReadTransaction(ctx, target.Keyspace, target.Shard, target.TabletType, dtid)
|
||||
}
|
||||
|
||||
// Execute is part of the queryservice.QueryService interface
|
||||
func (l *L2VTGate) Execute(ctx context.Context, target *querypb.Target, sql string, bindVariables map[string]interface{}, transactionID int64, options *querypb.ExecuteOptions) (*sqltypes.Result, error) {
|
||||
return l.gateway.Execute(ctx, target.Keyspace, target.Shard, target.TabletType, sql, bindVariables, transactionID, options)
|
||||
|
|
|
@ -0,0 +1,220 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class CommitPreparedRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.CommitPreparedRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\CommitPreparedRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class CommitPreparedResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.CommitPreparedResponse');
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,289 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class CreateTransactionRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target[] */
|
||||
public $participants = array();
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.CreateTransactionRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
// REPEATED MESSAGE participants = 5
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 5;
|
||||
$f->name = "participants";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_REPEATED;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <participants> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasParticipants(){
|
||||
return $this->_has(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <participants> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function clearParticipants(){
|
||||
return $this->_clear(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <participants> value
|
||||
*
|
||||
* @param int $idx
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getParticipants($idx = NULL){
|
||||
return $this->_get(5, $idx);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <participants> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function setParticipants(\Vitess\Proto\Query\Target $value, $idx = NULL){
|
||||
return $this->_set(5, $value, $idx);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get all elements of <participants>
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target[]
|
||||
*/
|
||||
public function getParticipantsList(){
|
||||
return $this->_get(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a new element to <participants>
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\CreateTransactionRequest
|
||||
*/
|
||||
public function addParticipants(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_add(5, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class CreateTransactionResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.CreateTransactionResponse');
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,268 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class PrepareRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var int */
|
||||
public $transaction_id = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.PrepareRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL INT64 transaction_id = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "transaction_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_INT64;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 5
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 5;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <transaction_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTransactionId(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <transaction_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function clearTransactionId(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <transaction_id> value
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getTransactionId(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <transaction_id> value
|
||||
*
|
||||
* @param int $value
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function setTransactionId( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\PrepareRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(5, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class PrepareResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.PrepareResponse');
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,220 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class ReadTransactionRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.ReadTransactionRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\ReadTransactionRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,74 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class ReadTransactionResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Query\TransactionMetadata */
|
||||
public $metadata = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.ReadTransactionResponse');
|
||||
|
||||
// OPTIONAL MESSAGE metadata = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "metadata";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\TransactionMetadata';
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <metadata> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasMetadata(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <metadata> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ReadTransactionResponse
|
||||
*/
|
||||
public function clearMetadata(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <metadata> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\TransactionMetadata
|
||||
*/
|
||||
public function getMetadata(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <metadata> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\TransactionMetadata $value
|
||||
* @return \Vitess\Proto\Query\ReadTransactionResponse
|
||||
*/
|
||||
public function setMetadata(\Vitess\Proto\Query\TransactionMetadata $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,220 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class ResolveTransactionRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.ResolveTransactionRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\ResolveTransactionRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class ResolveTransactionResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.ResolveTransactionResponse');
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,268 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class RollbackPreparedRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var int */
|
||||
public $transaction_id = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.RollbackPreparedRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL INT64 transaction_id = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "transaction_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_INT64;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 5
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 5;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <transaction_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTransactionId(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <transaction_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function clearTransactionId(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <transaction_id> value
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getTransactionId(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <transaction_id> value
|
||||
*
|
||||
* @param int $value
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function setTransactionId( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\RollbackPreparedRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(5, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class RollbackPreparedResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.RollbackPreparedResponse');
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,268 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class SetRollbackRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var int */
|
||||
public $transaction_id = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.SetRollbackRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL INT64 transaction_id = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "transaction_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_INT64;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 5
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 5;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <transaction_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTransactionId(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <transaction_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function clearTransactionId(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <transaction_id> value
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getTransactionId(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <transaction_id> value
|
||||
*
|
||||
* @param int $value
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function setTransactionId( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\SetRollbackRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(5, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class SetRollbackResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.SetRollbackResponse');
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,268 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class StartCommitRequest extends \DrSlump\Protobuf\Message {
|
||||
|
||||
/** @var \Vitess\Proto\Vtrpc\CallerID */
|
||||
public $effective_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\VTGateCallerID */
|
||||
public $immediate_caller_id = null;
|
||||
|
||||
/** @var \Vitess\Proto\Query\Target */
|
||||
public $target = null;
|
||||
|
||||
/** @var int */
|
||||
public $transaction_id = null;
|
||||
|
||||
/** @var string */
|
||||
public $dtid = null;
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.StartCommitRequest');
|
||||
|
||||
// OPTIONAL MESSAGE effective_caller_id = 1
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 1;
|
||||
$f->name = "effective_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Vtrpc\CallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE immediate_caller_id = 2
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 2;
|
||||
$f->name = "immediate_caller_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\VTGateCallerID';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL MESSAGE target = 3
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 3;
|
||||
$f->name = "target";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_MESSAGE;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$f->reference = '\Vitess\Proto\Query\Target';
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL INT64 transaction_id = 4
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 4;
|
||||
$f->name = "transaction_id";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_INT64;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
// OPTIONAL STRING dtid = 5
|
||||
$f = new \DrSlump\Protobuf\Field();
|
||||
$f->number = 5;
|
||||
$f->name = "dtid";
|
||||
$f->type = \DrSlump\Protobuf::TYPE_STRING;
|
||||
$f->rule = \DrSlump\Protobuf::RULE_OPTIONAL;
|
||||
$descriptor->addField($f);
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <effective_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasEffectiveCallerId(){
|
||||
return $this->_has(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function clearEffectiveCallerId(){
|
||||
return $this->_clear(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <effective_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Vtrpc\CallerID
|
||||
*/
|
||||
public function getEffectiveCallerId(){
|
||||
return $this->_get(1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <effective_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Vtrpc\CallerID $value
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function setEffectiveCallerId(\Vitess\Proto\Vtrpc\CallerID $value){
|
||||
return $this->_set(1, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <immediate_caller_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasImmediateCallerId(){
|
||||
return $this->_has(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function clearImmediateCallerId(){
|
||||
return $this->_clear(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <immediate_caller_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\VTGateCallerID
|
||||
*/
|
||||
public function getImmediateCallerId(){
|
||||
return $this->_get(2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <immediate_caller_id> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\VTGateCallerID $value
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function setImmediateCallerId(\Vitess\Proto\Query\VTGateCallerID $value){
|
||||
return $this->_set(2, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <target> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTarget(){
|
||||
return $this->_has(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function clearTarget(){
|
||||
return $this->_clear(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <target> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\Target
|
||||
*/
|
||||
public function getTarget(){
|
||||
return $this->_get(3);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <target> value
|
||||
*
|
||||
* @param \Vitess\Proto\Query\Target $value
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function setTarget(\Vitess\Proto\Query\Target $value){
|
||||
return $this->_set(3, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <transaction_id> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasTransactionId(){
|
||||
return $this->_has(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <transaction_id> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function clearTransactionId(){
|
||||
return $this->_clear(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <transaction_id> value
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getTransactionId(){
|
||||
return $this->_get(4);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <transaction_id> value
|
||||
*
|
||||
* @param int $value
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function setTransactionId( $value){
|
||||
return $this->_set(4, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if <dtid> has a value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasDtid(){
|
||||
return $this->_has(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear <dtid> value
|
||||
*
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function clearDtid(){
|
||||
return $this->_clear(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get <dtid> value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getDtid(){
|
||||
return $this->_get(5);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set <dtid> value
|
||||
*
|
||||
* @param string $value
|
||||
* @return \Vitess\Proto\Query\StartCommitRequest
|
||||
*/
|
||||
public function setDtid( $value){
|
||||
return $this->_set(5, $value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
// DO NOT EDIT! Generated by Protobuf-PHP protoc plugin 1.0
|
||||
// Source: query.proto
|
||||
|
||||
namespace Vitess\Proto\Query {
|
||||
|
||||
class StartCommitResponse extends \DrSlump\Protobuf\Message {
|
||||
|
||||
|
||||
/** @var \Closure[] */
|
||||
protected static $__extensions = array();
|
||||
|
||||
public static function descriptor()
|
||||
{
|
||||
$descriptor = new \DrSlump\Protobuf\Descriptor(__CLASS__, 'query.StartCommitResponse');
|
||||
|
||||
foreach (self::$__extensions as $cb) {
|
||||
$descriptor->addField($cb(), true);
|
||||
}
|
||||
|
||||
return $descriptor;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -45,6 +45,54 @@ namespace Vitess\Proto\Queryservice {
|
|||
public function Rollback(\Vitess\Proto\Query\RollbackRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/Rollback', $argument, '\Vitess\Proto\Query\RollbackResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\PrepareRequest $input
|
||||
*/
|
||||
public function Prepare(\Vitess\Proto\Query\PrepareRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/Prepare', $argument, '\Vitess\Proto\Query\PrepareResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\CommitPreparedRequest $input
|
||||
*/
|
||||
public function CommitPrepared(\Vitess\Proto\Query\CommitPreparedRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/CommitPrepared', $argument, '\Vitess\Proto\Query\CommitPreparedResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\RollbackPreparedRequest $input
|
||||
*/
|
||||
public function RollbackPrepared(\Vitess\Proto\Query\RollbackPreparedRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/RollbackPrepared', $argument, '\Vitess\Proto\Query\RollbackPreparedResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\CreateTransactionRequest $input
|
||||
*/
|
||||
public function CreateTransaction(\Vitess\Proto\Query\CreateTransactionRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/CreateTransaction', $argument, '\Vitess\Proto\Query\CreateTransactionResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\StartCommitRequest $input
|
||||
*/
|
||||
public function StartCommit(\Vitess\Proto\Query\StartCommitRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/StartCommit', $argument, '\Vitess\Proto\Query\StartCommitResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\SetRollbackRequest $input
|
||||
*/
|
||||
public function SetRollback(\Vitess\Proto\Query\SetRollbackRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/SetRollback', $argument, '\Vitess\Proto\Query\SetRollbackResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\ResolveTransactionRequest $input
|
||||
*/
|
||||
public function ResolveTransaction(\Vitess\Proto\Query\ResolveTransactionRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/ResolveTransaction', $argument, '\Vitess\Proto\Query\ResolveTransactionResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\ReadTransactionRequest $input
|
||||
*/
|
||||
public function ReadTransaction(\Vitess\Proto\Query\ReadTransactionRequest $argument, $metadata = array(), $options = array()) {
|
||||
return $this->_simpleRequest('/queryservice.Query/ReadTransaction', $argument, '\Vitess\Proto\Query\ReadTransactionResponse::deserialize', $metadata, $options);
|
||||
}
|
||||
/**
|
||||
* @param Vitess\Proto\Query\BeginExecuteRequest $input
|
||||
*/
|
||||
|
|
|
@ -349,6 +349,101 @@ message RollbackRequest {
|
|||
// RollbackResponse is the returned value from Rollback
|
||||
message RollbackResponse {}
|
||||
|
||||
// PrepareRequest is the payload to Prepare
|
||||
message PrepareRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
int64 transaction_id = 4;
|
||||
string dtid = 5;
|
||||
}
|
||||
|
||||
// PrepareResponse is the returned value from Prepare
|
||||
message PrepareResponse {}
|
||||
|
||||
// CommitPreparedRequest is the payload to CommitPrepared
|
||||
message CommitPreparedRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
string dtid = 4;
|
||||
}
|
||||
|
||||
// CommitPreparedResponse is the returned value from CommitPrepared
|
||||
message CommitPreparedResponse {}
|
||||
|
||||
// RollbackPreparedRequest is the payload to RollbackPrepared
|
||||
message RollbackPreparedRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
int64 transaction_id = 4;
|
||||
string dtid = 5;
|
||||
}
|
||||
|
||||
// RollbackPreparedResponse is the returned value from RollbackPrepared
|
||||
message RollbackPreparedResponse {}
|
||||
|
||||
// CreateTransactionRequest is the payload to CreateTransaction
|
||||
message CreateTransactionRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
string dtid = 4;
|
||||
repeated Target participants = 5;
|
||||
}
|
||||
|
||||
// CreateTransactionResponse is the returned value from CreateTransaction
|
||||
message CreateTransactionResponse {}
|
||||
|
||||
// StartCommitRequest is the payload to StartCommit
|
||||
message StartCommitRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
int64 transaction_id = 4;
|
||||
string dtid = 5;
|
||||
}
|
||||
|
||||
// StartCommitResponse is the returned value from StartCommit
|
||||
message StartCommitResponse {}
|
||||
|
||||
// SetRollbackRequest is the payload to SetRollback
|
||||
message SetRollbackRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
int64 transaction_id = 4;
|
||||
string dtid = 5;
|
||||
}
|
||||
|
||||
// SetRollbackResponse is the returned value from SetRollback
|
||||
message SetRollbackResponse {}
|
||||
|
||||
// ResolveTransactionRequest is the payload to ResolveTransaction
|
||||
message ResolveTransactionRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
string dtid = 4;
|
||||
}
|
||||
|
||||
// ResolveTransactionResponse is the returned value from ResolveTransaction
|
||||
message ResolveTransactionResponse {}
|
||||
|
||||
// ReadTransactionRequest is the payload to ReadTransaction
|
||||
message ReadTransactionRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
VTGateCallerID immediate_caller_id = 2;
|
||||
Target target = 3;
|
||||
string dtid = 4;
|
||||
}
|
||||
|
||||
// ReadTransactionResponse is the returned value from ReadTransaction
|
||||
message ReadTransactionResponse {
|
||||
TransactionMetadata metadata = 1;
|
||||
}
|
||||
|
||||
// BeginExecuteRequest is the payload to BeginExecute
|
||||
message BeginExecuteRequest {
|
||||
vtrpc.CallerID effective_caller_id = 1;
|
||||
|
|
|
@ -31,6 +31,30 @@ service Query {
|
|||
// Rollback a transaction.
|
||||
rpc Rollback(query.RollbackRequest) returns (query.RollbackResponse) {};
|
||||
|
||||
// Prepare preares a transaction.
|
||||
rpc Prepare(query.PrepareRequest) returns (query.PrepareResponse) {};
|
||||
|
||||
// CommitPrepared commits a prepared transaction.
|
||||
rpc CommitPrepared(query.CommitPreparedRequest) returns (query.CommitPreparedResponse) {};
|
||||
|
||||
// RollbackPrepared rolls back a prepared transaction.
|
||||
rpc RollbackPrepared(query.RollbackPreparedRequest) returns (query.RollbackPreparedResponse) {};
|
||||
|
||||
// CreateTransaction creates the metadata for a 2pc transaction.
|
||||
rpc CreateTransaction(query.CreateTransactionRequest) returns (query.CreateTransactionResponse) {};
|
||||
|
||||
// StartCommit initiates a commit for a 2pc transaction.
|
||||
rpc StartCommit(query.StartCommitRequest) returns (query.StartCommitResponse) {};
|
||||
|
||||
// SetRollback marks the 2pc transaction for rollback.
|
||||
rpc SetRollback(query.SetRollbackRequest) returns (query.SetRollbackResponse) {};
|
||||
|
||||
// ResolveTransaction marks the 2pc transaction as resolved.
|
||||
rpc ResolveTransaction(query.ResolveTransactionRequest) returns (query.ResolveTransactionResponse) {};
|
||||
|
||||
// ReadTransaction returns the 2pc transaction info.
|
||||
rpc ReadTransaction(query.ReadTransactionRequest) returns (query.ReadTransactionResponse) {};
|
||||
|
||||
// BeginExecute executes a begin and the specified SQL query.
|
||||
rpc BeginExecute(query.BeginExecuteRequest) returns (query.BeginExecuteResponse) {};
|
||||
|
||||
|
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -20,7 +20,7 @@ DESCRIPTOR = _descriptor.FileDescriptor(
|
|||
name='queryservice.proto',
|
||||
package='queryservice',
|
||||
syntax='proto3',
|
||||
serialized_pb=_b('\n\x12queryservice.proto\x12\x0cqueryservice\x1a\x0bquery.proto2\x90\x06\n\x05Query\x12:\n\x07\x45xecute\x12\x15.query.ExecuteRequest\x1a\x16.query.ExecuteResponse\"\x00\x12I\n\x0c\x45xecuteBatch\x12\x1a.query.ExecuteBatchRequest\x1a\x1b.query.ExecuteBatchResponse\"\x00\x12N\n\rStreamExecute\x12\x1b.query.StreamExecuteRequest\x1a\x1c.query.StreamExecuteResponse\"\x00\x30\x01\x12\x34\n\x05\x42\x65gin\x12\x13.query.BeginRequest\x1a\x14.query.BeginResponse\"\x00\x12\x37\n\x06\x43ommit\x12\x14.query.CommitRequest\x1a\x15.query.CommitResponse\"\x00\x12=\n\x08Rollback\x12\x16.query.RollbackRequest\x1a\x17.query.RollbackResponse\"\x00\x12I\n\x0c\x42\x65ginExecute\x12\x1a.query.BeginExecuteRequest\x1a\x1b.query.BeginExecuteResponse\"\x00\x12X\n\x11\x42\x65ginExecuteBatch\x12\x1f.query.BeginExecuteBatchRequest\x1a .query.BeginExecuteBatchResponse\"\x00\x12\x43\n\nSplitQuery\x12\x18.query.SplitQueryRequest\x1a\x19.query.SplitQueryResponse\"\x00\x12K\n\x0cStreamHealth\x12\x1a.query.StreamHealthRequest\x1a\x1b.query.StreamHealthResponse\"\x00\x30\x01\x12K\n\x0cUpdateStream\x12\x1a.query.UpdateStreamRequest\x1a\x1b.query.UpdateStreamResponse\"\x00\x30\x01\x62\x06proto3')
|
||||
serialized_pb=_b('\n\x12queryservice.proto\x12\x0cqueryservice\x1a\x0bquery.proto2\x8f\x0b\n\x05Query\x12:\n\x07\x45xecute\x12\x15.query.ExecuteRequest\x1a\x16.query.ExecuteResponse\"\x00\x12I\n\x0c\x45xecuteBatch\x12\x1a.query.ExecuteBatchRequest\x1a\x1b.query.ExecuteBatchResponse\"\x00\x12N\n\rStreamExecute\x12\x1b.query.StreamExecuteRequest\x1a\x1c.query.StreamExecuteResponse\"\x00\x30\x01\x12\x34\n\x05\x42\x65gin\x12\x13.query.BeginRequest\x1a\x14.query.BeginResponse\"\x00\x12\x37\n\x06\x43ommit\x12\x14.query.CommitRequest\x1a\x15.query.CommitResponse\"\x00\x12=\n\x08Rollback\x12\x16.query.RollbackRequest\x1a\x17.query.RollbackResponse\"\x00\x12:\n\x07Prepare\x12\x15.query.PrepareRequest\x1a\x16.query.PrepareResponse\"\x00\x12O\n\x0e\x43ommitPrepared\x12\x1c.query.CommitPreparedRequest\x1a\x1d.query.CommitPreparedResponse\"\x00\x12U\n\x10RollbackPrepared\x12\x1e.query.RollbackPreparedRequest\x1a\x1f.query.RollbackPreparedResponse\"\x00\x12X\n\x11\x43reateTransaction\x12\x1f.query.CreateTransactionRequest\x1a .query.CreateTransactionResponse\"\x00\x12\x46\n\x0bStartCommit\x12\x19.query.StartCommitRequest\x1a\x1a.query.StartCommitResponse\"\x00\x12\x46\n\x0bSetRollback\x12\x19.query.SetRollbackRequest\x1a\x1a.query.SetRollbackResponse\"\x00\x12[\n\x12ResolveTransaction\x12 .query.ResolveTransactionRequest\x1a!.query.ResolveTransactionResponse\"\x00\x12R\n\x0fReadTransaction\x12\x1d.query.ReadTransactionRequest\x1a\x1e.query.ReadTransactionResponse\"\x00\x12I\n\x0c\x42\x65ginExecute\x12\x1a.query.BeginExecuteRequest\x1a\x1b.query.BeginExecuteResponse\"\x00\x12X\n\x11\x42\x65ginExecuteBatch\x12\x1f.query.BeginExecuteBatchRequest\x1a .query.BeginExecuteBatchResponse\"\x00\x12\x43\n\nSplitQuery\x12\x18.query.SplitQueryRequest\x1a\x19.query.SplitQueryResponse\"\x00\x12K\n\x0cStreamHealth\x12\x1a.query.StreamHealthRequest\x1a\x1b.query.StreamHealthResponse\"\x00\x30\x01\x12K\n\x0cUpdateStream\x12\x1a.query.UpdateStreamRequest\x1a\x1b.query.UpdateStreamResponse\"\x00\x30\x01\x62\x06proto3')
|
||||
,
|
||||
dependencies=[query__pb2.DESCRIPTOR,])
|
||||
_sym_db.RegisterFileDescriptor(DESCRIPTOR)
|
||||
|
@ -76,6 +76,46 @@ class QueryStub(object):
|
|||
request_serializer=query__pb2.RollbackRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.RollbackResponse.FromString,
|
||||
)
|
||||
self.Prepare = channel.unary_unary(
|
||||
'/queryservice.Query/Prepare',
|
||||
request_serializer=query__pb2.PrepareRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.PrepareResponse.FromString,
|
||||
)
|
||||
self.CommitPrepared = channel.unary_unary(
|
||||
'/queryservice.Query/CommitPrepared',
|
||||
request_serializer=query__pb2.CommitPreparedRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.CommitPreparedResponse.FromString,
|
||||
)
|
||||
self.RollbackPrepared = channel.unary_unary(
|
||||
'/queryservice.Query/RollbackPrepared',
|
||||
request_serializer=query__pb2.RollbackPreparedRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.RollbackPreparedResponse.FromString,
|
||||
)
|
||||
self.CreateTransaction = channel.unary_unary(
|
||||
'/queryservice.Query/CreateTransaction',
|
||||
request_serializer=query__pb2.CreateTransactionRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.CreateTransactionResponse.FromString,
|
||||
)
|
||||
self.StartCommit = channel.unary_unary(
|
||||
'/queryservice.Query/StartCommit',
|
||||
request_serializer=query__pb2.StartCommitRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.StartCommitResponse.FromString,
|
||||
)
|
||||
self.SetRollback = channel.unary_unary(
|
||||
'/queryservice.Query/SetRollback',
|
||||
request_serializer=query__pb2.SetRollbackRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.SetRollbackResponse.FromString,
|
||||
)
|
||||
self.ResolveTransaction = channel.unary_unary(
|
||||
'/queryservice.Query/ResolveTransaction',
|
||||
request_serializer=query__pb2.ResolveTransactionRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.ResolveTransactionResponse.FromString,
|
||||
)
|
||||
self.ReadTransaction = channel.unary_unary(
|
||||
'/queryservice.Query/ReadTransaction',
|
||||
request_serializer=query__pb2.ReadTransactionRequest.SerializeToString,
|
||||
response_deserializer=query__pb2.ReadTransactionResponse.FromString,
|
||||
)
|
||||
self.BeginExecute = channel.unary_unary(
|
||||
'/queryservice.Query/BeginExecute',
|
||||
request_serializer=query__pb2.BeginExecuteRequest.SerializeToString,
|
||||
|
@ -154,6 +194,62 @@ class QueryServicer(object):
|
|||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def Prepare(self, request, context):
|
||||
"""Prepare preares a transaction.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def CommitPrepared(self, request, context):
|
||||
"""CommitPrepared commits a prepared transaction.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def RollbackPrepared(self, request, context):
|
||||
"""RollbackPrepared rolls back a prepared transaction.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def CreateTransaction(self, request, context):
|
||||
"""CreateTransaction creates the metadata for a 2pc transaction.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def StartCommit(self, request, context):
|
||||
"""StartCommit initiates a commit for a 2pc transaction.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def SetRollback(self, request, context):
|
||||
"""SetRollback marks the 2pc transaction for rollback.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def ResolveTransaction(self, request, context):
|
||||
"""ResolveTransaction marks the 2pc transaction as resolved.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def ReadTransaction(self, request, context):
|
||||
"""ReadTransaction returns the 2pc transaction info.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
raise NotImplementedError('Method not implemented!')
|
||||
|
||||
def BeginExecute(self, request, context):
|
||||
"""BeginExecute executes a begin and the specified SQL query.
|
||||
"""
|
||||
|
@ -224,6 +320,46 @@ def add_QueryServicer_to_server(servicer, server):
|
|||
request_deserializer=query__pb2.RollbackRequest.FromString,
|
||||
response_serializer=query__pb2.RollbackResponse.SerializeToString,
|
||||
),
|
||||
'Prepare': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.Prepare,
|
||||
request_deserializer=query__pb2.PrepareRequest.FromString,
|
||||
response_serializer=query__pb2.PrepareResponse.SerializeToString,
|
||||
),
|
||||
'CommitPrepared': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.CommitPrepared,
|
||||
request_deserializer=query__pb2.CommitPreparedRequest.FromString,
|
||||
response_serializer=query__pb2.CommitPreparedResponse.SerializeToString,
|
||||
),
|
||||
'RollbackPrepared': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.RollbackPrepared,
|
||||
request_deserializer=query__pb2.RollbackPreparedRequest.FromString,
|
||||
response_serializer=query__pb2.RollbackPreparedResponse.SerializeToString,
|
||||
),
|
||||
'CreateTransaction': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.CreateTransaction,
|
||||
request_deserializer=query__pb2.CreateTransactionRequest.FromString,
|
||||
response_serializer=query__pb2.CreateTransactionResponse.SerializeToString,
|
||||
),
|
||||
'StartCommit': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.StartCommit,
|
||||
request_deserializer=query__pb2.StartCommitRequest.FromString,
|
||||
response_serializer=query__pb2.StartCommitResponse.SerializeToString,
|
||||
),
|
||||
'SetRollback': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.SetRollback,
|
||||
request_deserializer=query__pb2.SetRollbackRequest.FromString,
|
||||
response_serializer=query__pb2.SetRollbackResponse.SerializeToString,
|
||||
),
|
||||
'ResolveTransaction': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.ResolveTransaction,
|
||||
request_deserializer=query__pb2.ResolveTransactionRequest.FromString,
|
||||
response_serializer=query__pb2.ResolveTransactionResponse.SerializeToString,
|
||||
),
|
||||
'ReadTransaction': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.ReadTransaction,
|
||||
request_deserializer=query__pb2.ReadTransactionRequest.FromString,
|
||||
response_serializer=query__pb2.ReadTransactionResponse.SerializeToString,
|
||||
),
|
||||
'BeginExecute': grpc.unary_unary_rpc_method_handler(
|
||||
servicer.BeginExecute,
|
||||
request_deserializer=query__pb2.BeginExecuteRequest.FromString,
|
||||
|
@ -287,6 +423,38 @@ class BetaQueryServicer(object):
|
|||
"""Rollback a transaction.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def Prepare(self, request, context):
|
||||
"""Prepare preares a transaction.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def CommitPrepared(self, request, context):
|
||||
"""CommitPrepared commits a prepared transaction.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def RollbackPrepared(self, request, context):
|
||||
"""RollbackPrepared rolls back a prepared transaction.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def CreateTransaction(self, request, context):
|
||||
"""CreateTransaction creates the metadata for a 2pc transaction.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def StartCommit(self, request, context):
|
||||
"""StartCommit initiates a commit for a 2pc transaction.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def SetRollback(self, request, context):
|
||||
"""SetRollback marks the 2pc transaction for rollback.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def ResolveTransaction(self, request, context):
|
||||
"""ResolveTransaction marks the 2pc transaction as resolved.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def ReadTransaction(self, request, context):
|
||||
"""ReadTransaction returns the 2pc transaction info.
|
||||
"""
|
||||
context.code(beta_interfaces.StatusCode.UNIMPLEMENTED)
|
||||
def BeginExecute(self, request, context):
|
||||
"""BeginExecute executes a begin and the specified SQL query.
|
||||
"""
|
||||
|
@ -348,6 +516,46 @@ class BetaQueryStub(object):
|
|||
"""
|
||||
raise NotImplementedError()
|
||||
Rollback.future = None
|
||||
def Prepare(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""Prepare preares a transaction.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
Prepare.future = None
|
||||
def CommitPrepared(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""CommitPrepared commits a prepared transaction.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
CommitPrepared.future = None
|
||||
def RollbackPrepared(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""RollbackPrepared rolls back a prepared transaction.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
RollbackPrepared.future = None
|
||||
def CreateTransaction(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""CreateTransaction creates the metadata for a 2pc transaction.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
CreateTransaction.future = None
|
||||
def StartCommit(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""StartCommit initiates a commit for a 2pc transaction.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
StartCommit.future = None
|
||||
def SetRollback(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""SetRollback marks the 2pc transaction for rollback.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
SetRollback.future = None
|
||||
def ResolveTransaction(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""ResolveTransaction marks the 2pc transaction as resolved.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
ResolveTransaction.future = None
|
||||
def ReadTransaction(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""ReadTransaction returns the 2pc transaction info.
|
||||
"""
|
||||
raise NotImplementedError()
|
||||
ReadTransaction.future = None
|
||||
def BeginExecute(self, request, timeout, metadata=None, with_call=False, protocol_options=None):
|
||||
"""BeginExecute executes a begin and the specified SQL query.
|
||||
"""
|
||||
|
@ -381,10 +589,18 @@ def beta_create_Query_server(servicer, pool=None, pool_size=None, default_timeou
|
|||
('queryservice.Query', 'BeginExecute'): query__pb2.BeginExecuteRequest.FromString,
|
||||
('queryservice.Query', 'BeginExecuteBatch'): query__pb2.BeginExecuteBatchRequest.FromString,
|
||||
('queryservice.Query', 'Commit'): query__pb2.CommitRequest.FromString,
|
||||
('queryservice.Query', 'CommitPrepared'): query__pb2.CommitPreparedRequest.FromString,
|
||||
('queryservice.Query', 'CreateTransaction'): query__pb2.CreateTransactionRequest.FromString,
|
||||
('queryservice.Query', 'Execute'): query__pb2.ExecuteRequest.FromString,
|
||||
('queryservice.Query', 'ExecuteBatch'): query__pb2.ExecuteBatchRequest.FromString,
|
||||
('queryservice.Query', 'Prepare'): query__pb2.PrepareRequest.FromString,
|
||||
('queryservice.Query', 'ReadTransaction'): query__pb2.ReadTransactionRequest.FromString,
|
||||
('queryservice.Query', 'ResolveTransaction'): query__pb2.ResolveTransactionRequest.FromString,
|
||||
('queryservice.Query', 'Rollback'): query__pb2.RollbackRequest.FromString,
|
||||
('queryservice.Query', 'RollbackPrepared'): query__pb2.RollbackPreparedRequest.FromString,
|
||||
('queryservice.Query', 'SetRollback'): query__pb2.SetRollbackRequest.FromString,
|
||||
('queryservice.Query', 'SplitQuery'): query__pb2.SplitQueryRequest.FromString,
|
||||
('queryservice.Query', 'StartCommit'): query__pb2.StartCommitRequest.FromString,
|
||||
('queryservice.Query', 'StreamExecute'): query__pb2.StreamExecuteRequest.FromString,
|
||||
('queryservice.Query', 'StreamHealth'): query__pb2.StreamHealthRequest.FromString,
|
||||
('queryservice.Query', 'UpdateStream'): query__pb2.UpdateStreamRequest.FromString,
|
||||
|
@ -394,10 +610,18 @@ def beta_create_Query_server(servicer, pool=None, pool_size=None, default_timeou
|
|||
('queryservice.Query', 'BeginExecute'): query__pb2.BeginExecuteResponse.SerializeToString,
|
||||
('queryservice.Query', 'BeginExecuteBatch'): query__pb2.BeginExecuteBatchResponse.SerializeToString,
|
||||
('queryservice.Query', 'Commit'): query__pb2.CommitResponse.SerializeToString,
|
||||
('queryservice.Query', 'CommitPrepared'): query__pb2.CommitPreparedResponse.SerializeToString,
|
||||
('queryservice.Query', 'CreateTransaction'): query__pb2.CreateTransactionResponse.SerializeToString,
|
||||
('queryservice.Query', 'Execute'): query__pb2.ExecuteResponse.SerializeToString,
|
||||
('queryservice.Query', 'ExecuteBatch'): query__pb2.ExecuteBatchResponse.SerializeToString,
|
||||
('queryservice.Query', 'Prepare'): query__pb2.PrepareResponse.SerializeToString,
|
||||
('queryservice.Query', 'ReadTransaction'): query__pb2.ReadTransactionResponse.SerializeToString,
|
||||
('queryservice.Query', 'ResolveTransaction'): query__pb2.ResolveTransactionResponse.SerializeToString,
|
||||
('queryservice.Query', 'Rollback'): query__pb2.RollbackResponse.SerializeToString,
|
||||
('queryservice.Query', 'RollbackPrepared'): query__pb2.RollbackPreparedResponse.SerializeToString,
|
||||
('queryservice.Query', 'SetRollback'): query__pb2.SetRollbackResponse.SerializeToString,
|
||||
('queryservice.Query', 'SplitQuery'): query__pb2.SplitQueryResponse.SerializeToString,
|
||||
('queryservice.Query', 'StartCommit'): query__pb2.StartCommitResponse.SerializeToString,
|
||||
('queryservice.Query', 'StreamExecute'): query__pb2.StreamExecuteResponse.SerializeToString,
|
||||
('queryservice.Query', 'StreamHealth'): query__pb2.StreamHealthResponse.SerializeToString,
|
||||
('queryservice.Query', 'UpdateStream'): query__pb2.UpdateStreamResponse.SerializeToString,
|
||||
|
@ -407,10 +631,18 @@ def beta_create_Query_server(servicer, pool=None, pool_size=None, default_timeou
|
|||
('queryservice.Query', 'BeginExecute'): face_utilities.unary_unary_inline(servicer.BeginExecute),
|
||||
('queryservice.Query', 'BeginExecuteBatch'): face_utilities.unary_unary_inline(servicer.BeginExecuteBatch),
|
||||
('queryservice.Query', 'Commit'): face_utilities.unary_unary_inline(servicer.Commit),
|
||||
('queryservice.Query', 'CommitPrepared'): face_utilities.unary_unary_inline(servicer.CommitPrepared),
|
||||
('queryservice.Query', 'CreateTransaction'): face_utilities.unary_unary_inline(servicer.CreateTransaction),
|
||||
('queryservice.Query', 'Execute'): face_utilities.unary_unary_inline(servicer.Execute),
|
||||
('queryservice.Query', 'ExecuteBatch'): face_utilities.unary_unary_inline(servicer.ExecuteBatch),
|
||||
('queryservice.Query', 'Prepare'): face_utilities.unary_unary_inline(servicer.Prepare),
|
||||
('queryservice.Query', 'ReadTransaction'): face_utilities.unary_unary_inline(servicer.ReadTransaction),
|
||||
('queryservice.Query', 'ResolveTransaction'): face_utilities.unary_unary_inline(servicer.ResolveTransaction),
|
||||
('queryservice.Query', 'Rollback'): face_utilities.unary_unary_inline(servicer.Rollback),
|
||||
('queryservice.Query', 'RollbackPrepared'): face_utilities.unary_unary_inline(servicer.RollbackPrepared),
|
||||
('queryservice.Query', 'SetRollback'): face_utilities.unary_unary_inline(servicer.SetRollback),
|
||||
('queryservice.Query', 'SplitQuery'): face_utilities.unary_unary_inline(servicer.SplitQuery),
|
||||
('queryservice.Query', 'StartCommit'): face_utilities.unary_unary_inline(servicer.StartCommit),
|
||||
('queryservice.Query', 'StreamExecute'): face_utilities.unary_stream_inline(servicer.StreamExecute),
|
||||
('queryservice.Query', 'StreamHealth'): face_utilities.unary_stream_inline(servicer.StreamHealth),
|
||||
('queryservice.Query', 'UpdateStream'): face_utilities.unary_stream_inline(servicer.UpdateStream),
|
||||
|
@ -425,10 +657,18 @@ def beta_create_Query_stub(channel, host=None, metadata_transformer=None, pool=N
|
|||
('queryservice.Query', 'BeginExecute'): query__pb2.BeginExecuteRequest.SerializeToString,
|
||||
('queryservice.Query', 'BeginExecuteBatch'): query__pb2.BeginExecuteBatchRequest.SerializeToString,
|
||||
('queryservice.Query', 'Commit'): query__pb2.CommitRequest.SerializeToString,
|
||||
('queryservice.Query', 'CommitPrepared'): query__pb2.CommitPreparedRequest.SerializeToString,
|
||||
('queryservice.Query', 'CreateTransaction'): query__pb2.CreateTransactionRequest.SerializeToString,
|
||||
('queryservice.Query', 'Execute'): query__pb2.ExecuteRequest.SerializeToString,
|
||||
('queryservice.Query', 'ExecuteBatch'): query__pb2.ExecuteBatchRequest.SerializeToString,
|
||||
('queryservice.Query', 'Prepare'): query__pb2.PrepareRequest.SerializeToString,
|
||||
('queryservice.Query', 'ReadTransaction'): query__pb2.ReadTransactionRequest.SerializeToString,
|
||||
('queryservice.Query', 'ResolveTransaction'): query__pb2.ResolveTransactionRequest.SerializeToString,
|
||||
('queryservice.Query', 'Rollback'): query__pb2.RollbackRequest.SerializeToString,
|
||||
('queryservice.Query', 'RollbackPrepared'): query__pb2.RollbackPreparedRequest.SerializeToString,
|
||||
('queryservice.Query', 'SetRollback'): query__pb2.SetRollbackRequest.SerializeToString,
|
||||
('queryservice.Query', 'SplitQuery'): query__pb2.SplitQueryRequest.SerializeToString,
|
||||
('queryservice.Query', 'StartCommit'): query__pb2.StartCommitRequest.SerializeToString,
|
||||
('queryservice.Query', 'StreamExecute'): query__pb2.StreamExecuteRequest.SerializeToString,
|
||||
('queryservice.Query', 'StreamHealth'): query__pb2.StreamHealthRequest.SerializeToString,
|
||||
('queryservice.Query', 'UpdateStream'): query__pb2.UpdateStreamRequest.SerializeToString,
|
||||
|
@ -438,10 +678,18 @@ def beta_create_Query_stub(channel, host=None, metadata_transformer=None, pool=N
|
|||
('queryservice.Query', 'BeginExecute'): query__pb2.BeginExecuteResponse.FromString,
|
||||
('queryservice.Query', 'BeginExecuteBatch'): query__pb2.BeginExecuteBatchResponse.FromString,
|
||||
('queryservice.Query', 'Commit'): query__pb2.CommitResponse.FromString,
|
||||
('queryservice.Query', 'CommitPrepared'): query__pb2.CommitPreparedResponse.FromString,
|
||||
('queryservice.Query', 'CreateTransaction'): query__pb2.CreateTransactionResponse.FromString,
|
||||
('queryservice.Query', 'Execute'): query__pb2.ExecuteResponse.FromString,
|
||||
('queryservice.Query', 'ExecuteBatch'): query__pb2.ExecuteBatchResponse.FromString,
|
||||
('queryservice.Query', 'Prepare'): query__pb2.PrepareResponse.FromString,
|
||||
('queryservice.Query', 'ReadTransaction'): query__pb2.ReadTransactionResponse.FromString,
|
||||
('queryservice.Query', 'ResolveTransaction'): query__pb2.ResolveTransactionResponse.FromString,
|
||||
('queryservice.Query', 'Rollback'): query__pb2.RollbackResponse.FromString,
|
||||
('queryservice.Query', 'RollbackPrepared'): query__pb2.RollbackPreparedResponse.FromString,
|
||||
('queryservice.Query', 'SetRollback'): query__pb2.SetRollbackResponse.FromString,
|
||||
('queryservice.Query', 'SplitQuery'): query__pb2.SplitQueryResponse.FromString,
|
||||
('queryservice.Query', 'StartCommit'): query__pb2.StartCommitResponse.FromString,
|
||||
('queryservice.Query', 'StreamExecute'): query__pb2.StreamExecuteResponse.FromString,
|
||||
('queryservice.Query', 'StreamHealth'): query__pb2.StreamHealthResponse.FromString,
|
||||
('queryservice.Query', 'UpdateStream'): query__pb2.UpdateStreamResponse.FromString,
|
||||
|
@ -451,10 +699,18 @@ def beta_create_Query_stub(channel, host=None, metadata_transformer=None, pool=N
|
|||
'BeginExecute': cardinality.Cardinality.UNARY_UNARY,
|
||||
'BeginExecuteBatch': cardinality.Cardinality.UNARY_UNARY,
|
||||
'Commit': cardinality.Cardinality.UNARY_UNARY,
|
||||
'CommitPrepared': cardinality.Cardinality.UNARY_UNARY,
|
||||
'CreateTransaction': cardinality.Cardinality.UNARY_UNARY,
|
||||
'Execute': cardinality.Cardinality.UNARY_UNARY,
|
||||
'ExecuteBatch': cardinality.Cardinality.UNARY_UNARY,
|
||||
'Prepare': cardinality.Cardinality.UNARY_UNARY,
|
||||
'ReadTransaction': cardinality.Cardinality.UNARY_UNARY,
|
||||
'ResolveTransaction': cardinality.Cardinality.UNARY_UNARY,
|
||||
'Rollback': cardinality.Cardinality.UNARY_UNARY,
|
||||
'RollbackPrepared': cardinality.Cardinality.UNARY_UNARY,
|
||||
'SetRollback': cardinality.Cardinality.UNARY_UNARY,
|
||||
'SplitQuery': cardinality.Cardinality.UNARY_UNARY,
|
||||
'StartCommit': cardinality.Cardinality.UNARY_UNARY,
|
||||
'StreamExecute': cardinality.Cardinality.UNARY_STREAM,
|
||||
'StreamHealth': cardinality.Cardinality.UNARY_STREAM,
|
||||
'UpdateStream': cardinality.Cardinality.UNARY_STREAM,
|
||||
|
|
Загрузка…
Ссылка в новой задаче