dev

package
v1.36.10-2025072813344... Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: unknown License: Apache-2.0 Imports: 8 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	TransactionMode_name = map[int32]string{
		0: "UNSPECIFIED",
		1: "SINGLE",
		2: "MULTI",
		3: "TWOPC",
	}
	TransactionMode_value = map[string]int32{
		"UNSPECIFIED": 0,
		"SINGLE":      1,
		"MULTI":       2,
		"TWOPC":       3,
	}
)

Enum value maps for TransactionMode.

View Source
var (
	CommitOrder_name = map[int32]string{
		0: "NORMAL",
		1: "PRE",
		2: "POST",
		3: "AUTOCOMMIT",
	}
	CommitOrder_value = map[string]int32{
		"NORMAL":     0,
		"PRE":        1,
		"POST":       2,
		"AUTOCOMMIT": 3,
	}
)

Enum value maps for CommitOrder.

View Source
var File_vitess_vtgate_dev_vtgate_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type CloseSessionRequest

type CloseSessionRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// session carries the session state.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// contains filtered or unexported fields
}

CloseSessionRequest is the payload to CloseSession.

func (*CloseSessionRequest) ClearCallerId

func (x *CloseSessionRequest) ClearCallerId()

func (*CloseSessionRequest) ClearSession

func (x *CloseSessionRequest) ClearSession()

func (*CloseSessionRequest) GetCallerId

func (x *CloseSessionRequest) GetCallerId() *dev1.CallerID

func (*CloseSessionRequest) GetSession

func (x *CloseSessionRequest) GetSession() *Session

func (*CloseSessionRequest) HasCallerId

func (x *CloseSessionRequest) HasCallerId() bool

func (*CloseSessionRequest) HasSession

func (x *CloseSessionRequest) HasSession() bool

func (*CloseSessionRequest) ProtoMessage

func (*CloseSessionRequest) ProtoMessage()

func (*CloseSessionRequest) ProtoReflect

func (x *CloseSessionRequest) ProtoReflect() protoreflect.Message

func (*CloseSessionRequest) Reset

func (x *CloseSessionRequest) Reset()

func (*CloseSessionRequest) SetCallerId

func (x *CloseSessionRequest) SetCallerId(v *dev1.CallerID)

func (*CloseSessionRequest) SetSession

func (x *CloseSessionRequest) SetSession(v *Session)

func (*CloseSessionRequest) String

func (x *CloseSessionRequest) String() string

type CloseSessionRequest_builder

type CloseSessionRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// session carries the session state.
	Session *Session
	// contains filtered or unexported fields
}

func (CloseSessionRequest_builder) Build

type CloseSessionResponse

type CloseSessionResponse struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
	// contains filtered or unexported fields
}

CloseSessionResponse is the returned value from CloseSession.

func (*CloseSessionResponse) ClearError

func (x *CloseSessionResponse) ClearError()

func (*CloseSessionResponse) GetError

func (x *CloseSessionResponse) GetError() *dev1.RPCError

func (*CloseSessionResponse) HasError

func (x *CloseSessionResponse) HasError() bool

func (*CloseSessionResponse) ProtoMessage

func (*CloseSessionResponse) ProtoMessage()

func (*CloseSessionResponse) ProtoReflect

func (x *CloseSessionResponse) ProtoReflect() protoreflect.Message

func (*CloseSessionResponse) Reset

func (x *CloseSessionResponse) Reset()

func (*CloseSessionResponse) SetError

func (x *CloseSessionResponse) SetError(v *dev1.RPCError)

func (*CloseSessionResponse) String

func (x *CloseSessionResponse) String() string

type CloseSessionResponse_builder

type CloseSessionResponse_builder struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError
	// contains filtered or unexported fields
}

func (CloseSessionResponse_builder) Build

type CommitOrder

type CommitOrder int32

CommitOrder is used to designate which of the ShardSessions get used for transactions.

const (
	// NORMAL is the default commit order.
	CommitOrder_NORMAL CommitOrder = 0
	// PRE is used to designate pre_sessions.
	CommitOrder_PRE CommitOrder = 1
	// POST is used to designate post_sessions.
	CommitOrder_POST CommitOrder = 2
	// AUTOCOMMIT is used to run the statement as autocommitted transaction.
	CommitOrder_AUTOCOMMIT CommitOrder = 3
)

func (CommitOrder) Descriptor

func (CommitOrder) Enum

func (x CommitOrder) Enum() *CommitOrder

func (CommitOrder) Number

func (x CommitOrder) Number() protoreflect.EnumNumber

func (CommitOrder) String

func (x CommitOrder) String() string

func (CommitOrder) Type

type ExecuteBatchRequest

type ExecuteBatchRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// session carries the session state.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// queries is a list of query and bind variables to execute.
	Queries []*dev.BoundQuery `protobuf:"bytes,3,rep,name=queries,proto3" json:"queries,omitempty"`
	// contains filtered or unexported fields
}

ExecuteBatchRequest is the payload to ExecuteBatch.

func (*ExecuteBatchRequest) ClearCallerId

func (x *ExecuteBatchRequest) ClearCallerId()

func (*ExecuteBatchRequest) ClearSession

func (x *ExecuteBatchRequest) ClearSession()

func (*ExecuteBatchRequest) GetCallerId

func (x *ExecuteBatchRequest) GetCallerId() *dev1.CallerID

func (*ExecuteBatchRequest) GetQueries

func (x *ExecuteBatchRequest) GetQueries() []*dev.BoundQuery

func (*ExecuteBatchRequest) GetSession

func (x *ExecuteBatchRequest) GetSession() *Session

func (*ExecuteBatchRequest) HasCallerId

func (x *ExecuteBatchRequest) HasCallerId() bool

func (*ExecuteBatchRequest) HasSession

func (x *ExecuteBatchRequest) HasSession() bool

func (*ExecuteBatchRequest) ProtoMessage

func (*ExecuteBatchRequest) ProtoMessage()

func (*ExecuteBatchRequest) ProtoReflect

func (x *ExecuteBatchRequest) ProtoReflect() protoreflect.Message

func (*ExecuteBatchRequest) Reset

func (x *ExecuteBatchRequest) Reset()

func (*ExecuteBatchRequest) SetCallerId

func (x *ExecuteBatchRequest) SetCallerId(v *dev1.CallerID)

func (*ExecuteBatchRequest) SetQueries

func (x *ExecuteBatchRequest) SetQueries(v []*dev.BoundQuery)

func (*ExecuteBatchRequest) SetSession

func (x *ExecuteBatchRequest) SetSession(v *Session)

func (*ExecuteBatchRequest) String

func (x *ExecuteBatchRequest) String() string

type ExecuteBatchRequest_builder

type ExecuteBatchRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// session carries the session state.
	Session *Session
	// queries is a list of query and bind variables to execute.
	Queries []*dev.BoundQuery
	// contains filtered or unexported fields
}

func (ExecuteBatchRequest_builder) Build

type ExecuteBatchResponse

type ExecuteBatchResponse struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
	// session is the updated session information.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// results contains the query results, only set if application level error is unset.
	Results []*dev.ResultWithError `protobuf:"bytes,3,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

ExecuteBatchResponse is the returned value from ExecuteBatch.

func (*ExecuteBatchResponse) ClearError

func (x *ExecuteBatchResponse) ClearError()

func (*ExecuteBatchResponse) ClearSession

func (x *ExecuteBatchResponse) ClearSession()

func (*ExecuteBatchResponse) GetError

func (x *ExecuteBatchResponse) GetError() *dev1.RPCError

func (*ExecuteBatchResponse) GetResults

func (x *ExecuteBatchResponse) GetResults() []*dev.ResultWithError

func (*ExecuteBatchResponse) GetSession

func (x *ExecuteBatchResponse) GetSession() *Session

func (*ExecuteBatchResponse) HasError

func (x *ExecuteBatchResponse) HasError() bool

func (*ExecuteBatchResponse) HasSession

func (x *ExecuteBatchResponse) HasSession() bool

func (*ExecuteBatchResponse) ProtoMessage

func (*ExecuteBatchResponse) ProtoMessage()

func (*ExecuteBatchResponse) ProtoReflect

func (x *ExecuteBatchResponse) ProtoReflect() protoreflect.Message

func (*ExecuteBatchResponse) Reset

func (x *ExecuteBatchResponse) Reset()

func (*ExecuteBatchResponse) SetError

func (x *ExecuteBatchResponse) SetError(v *dev1.RPCError)

func (*ExecuteBatchResponse) SetResults

func (x *ExecuteBatchResponse) SetResults(v []*dev.ResultWithError)

func (*ExecuteBatchResponse) SetSession

func (x *ExecuteBatchResponse) SetSession(v *Session)

func (*ExecuteBatchResponse) String

func (x *ExecuteBatchResponse) String() string

type ExecuteBatchResponse_builder

type ExecuteBatchResponse_builder struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError
	// session is the updated session information.
	Session *Session
	// results contains the query results, only set if application level error is unset.
	Results []*dev.ResultWithError
	// contains filtered or unexported fields
}

func (ExecuteBatchResponse_builder) Build

type ExecuteMultiRequest

type ExecuteMultiRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// sql contains the set of queries to execute.
	Sql string `protobuf:"bytes,2,opt,name=sql,proto3" json:"sql,omitempty"`
	// session carries the session state.
	Session *Session `protobuf:"bytes,3,opt,name=session,proto3" json:"session,omitempty"`
	// contains filtered or unexported fields
}

ExecuteMultiRequest is the payload to ExecuteMulti.

func (*ExecuteMultiRequest) ClearCallerId

func (x *ExecuteMultiRequest) ClearCallerId()

func (*ExecuteMultiRequest) ClearSession

func (x *ExecuteMultiRequest) ClearSession()

func (*ExecuteMultiRequest) GetCallerId

func (x *ExecuteMultiRequest) GetCallerId() *dev1.CallerID

func (*ExecuteMultiRequest) GetSession

func (x *ExecuteMultiRequest) GetSession() *Session

func (*ExecuteMultiRequest) GetSql

func (x *ExecuteMultiRequest) GetSql() string

func (*ExecuteMultiRequest) HasCallerId

func (x *ExecuteMultiRequest) HasCallerId() bool

func (*ExecuteMultiRequest) HasSession

func (x *ExecuteMultiRequest) HasSession() bool

func (*ExecuteMultiRequest) ProtoMessage

func (*ExecuteMultiRequest) ProtoMessage()

func (*ExecuteMultiRequest) ProtoReflect

func (x *ExecuteMultiRequest) ProtoReflect() protoreflect.Message

func (*ExecuteMultiRequest) Reset

func (x *ExecuteMultiRequest) Reset()

func (*ExecuteMultiRequest) SetCallerId

func (x *ExecuteMultiRequest) SetCallerId(v *dev1.CallerID)

func (*ExecuteMultiRequest) SetSession

func (x *ExecuteMultiRequest) SetSession(v *Session)

func (*ExecuteMultiRequest) SetSql

func (x *ExecuteMultiRequest) SetSql(v string)

func (*ExecuteMultiRequest) String

func (x *ExecuteMultiRequest) String() string

type ExecuteMultiRequest_builder

type ExecuteMultiRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// sql contains the set of queries to execute.
	Sql string
	// session carries the session state.
	Session *Session
	// contains filtered or unexported fields
}

func (ExecuteMultiRequest_builder) Build

type ExecuteMultiResponse

type ExecuteMultiResponse struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
	// session is the updated session information.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// results contain the query results. There can be some results even if the
	// error is set.
	Results []*dev.QueryResult `protobuf:"bytes,3,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

ExecuteMultiResponse is the returned value from ExecuteMulti.

func (*ExecuteMultiResponse) ClearError

func (x *ExecuteMultiResponse) ClearError()

func (*ExecuteMultiResponse) ClearSession

func (x *ExecuteMultiResponse) ClearSession()

func (*ExecuteMultiResponse) GetError

func (x *ExecuteMultiResponse) GetError() *dev1.RPCError

func (*ExecuteMultiResponse) GetResults

func (x *ExecuteMultiResponse) GetResults() []*dev.QueryResult

func (*ExecuteMultiResponse) GetSession

func (x *ExecuteMultiResponse) GetSession() *Session

func (*ExecuteMultiResponse) HasError

func (x *ExecuteMultiResponse) HasError() bool

func (*ExecuteMultiResponse) HasSession

func (x *ExecuteMultiResponse) HasSession() bool

func (*ExecuteMultiResponse) ProtoMessage

func (*ExecuteMultiResponse) ProtoMessage()

func (*ExecuteMultiResponse) ProtoReflect

func (x *ExecuteMultiResponse) ProtoReflect() protoreflect.Message

func (*ExecuteMultiResponse) Reset

func (x *ExecuteMultiResponse) Reset()

func (*ExecuteMultiResponse) SetError

func (x *ExecuteMultiResponse) SetError(v *dev1.RPCError)

func (*ExecuteMultiResponse) SetResults

func (x *ExecuteMultiResponse) SetResults(v []*dev.QueryResult)

func (*ExecuteMultiResponse) SetSession

func (x *ExecuteMultiResponse) SetSession(v *Session)

func (*ExecuteMultiResponse) String

func (x *ExecuteMultiResponse) String() string

type ExecuteMultiResponse_builder

type ExecuteMultiResponse_builder struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError
	// session is the updated session information.
	Session *Session
	// results contain the query results. There can be some results even if the
	// error is set.
	Results []*dev.QueryResult
	// contains filtered or unexported fields
}

func (ExecuteMultiResponse_builder) Build

type ExecuteRequest

type ExecuteRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// session carries the session state.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// query is the query and bind variables to execute.
	Query    *dev.BoundQuery `protobuf:"bytes,3,opt,name=query,proto3" json:"query,omitempty"`
	Prepared bool            `protobuf:"varint,8,opt,name=prepared,proto3" json:"prepared,omitempty"`
	// contains filtered or unexported fields
}

ExecuteRequest is the payload to Execute.

func (*ExecuteRequest) ClearCallerId

func (x *ExecuteRequest) ClearCallerId()

func (*ExecuteRequest) ClearQuery

func (x *ExecuteRequest) ClearQuery()

func (*ExecuteRequest) ClearSession

func (x *ExecuteRequest) ClearSession()

func (*ExecuteRequest) GetCallerId

func (x *ExecuteRequest) GetCallerId() *dev1.CallerID

func (*ExecuteRequest) GetPrepared

func (x *ExecuteRequest) GetPrepared() bool

func (*ExecuteRequest) GetQuery

func (x *ExecuteRequest) GetQuery() *dev.BoundQuery

func (*ExecuteRequest) GetSession

func (x *ExecuteRequest) GetSession() *Session

func (*ExecuteRequest) HasCallerId

func (x *ExecuteRequest) HasCallerId() bool

func (*ExecuteRequest) HasQuery

func (x *ExecuteRequest) HasQuery() bool

func (*ExecuteRequest) HasSession

func (x *ExecuteRequest) HasSession() bool

func (*ExecuteRequest) ProtoMessage

func (*ExecuteRequest) ProtoMessage()

func (*ExecuteRequest) ProtoReflect

func (x *ExecuteRequest) ProtoReflect() protoreflect.Message

func (*ExecuteRequest) Reset

func (x *ExecuteRequest) Reset()

func (*ExecuteRequest) SetCallerId

func (x *ExecuteRequest) SetCallerId(v *dev1.CallerID)

func (*ExecuteRequest) SetPrepared

func (x *ExecuteRequest) SetPrepared(v bool)

func (*ExecuteRequest) SetQuery

func (x *ExecuteRequest) SetQuery(v *dev.BoundQuery)

func (*ExecuteRequest) SetSession

func (x *ExecuteRequest) SetSession(v *Session)

func (*ExecuteRequest) String

func (x *ExecuteRequest) String() string

type ExecuteRequest_builder

type ExecuteRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// session carries the session state.
	Session *Session
	// query is the query and bind variables to execute.
	Query    *dev.BoundQuery
	Prepared bool
	// contains filtered or unexported fields
}

func (ExecuteRequest_builder) Build

type ExecuteResponse

type ExecuteResponse struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
	// session is the updated session information.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// result contains the query result, only set if error is unset.
	Result *dev.QueryResult `protobuf:"bytes,3,opt,name=result,proto3" json:"result,omitempty"`
	// contains filtered or unexported fields
}

ExecuteResponse is the returned value from Execute.

func (*ExecuteResponse) ClearError

func (x *ExecuteResponse) ClearError()

func (*ExecuteResponse) ClearResult

func (x *ExecuteResponse) ClearResult()

func (*ExecuteResponse) ClearSession

func (x *ExecuteResponse) ClearSession()

func (*ExecuteResponse) GetError

func (x *ExecuteResponse) GetError() *dev1.RPCError

func (*ExecuteResponse) GetResult

func (x *ExecuteResponse) GetResult() *dev.QueryResult

func (*ExecuteResponse) GetSession

func (x *ExecuteResponse) GetSession() *Session

func (*ExecuteResponse) HasError

func (x *ExecuteResponse) HasError() bool

func (*ExecuteResponse) HasResult

func (x *ExecuteResponse) HasResult() bool

func (*ExecuteResponse) HasSession

func (x *ExecuteResponse) HasSession() bool

func (*ExecuteResponse) ProtoMessage

func (*ExecuteResponse) ProtoMessage()

func (*ExecuteResponse) ProtoReflect

func (x *ExecuteResponse) ProtoReflect() protoreflect.Message

func (*ExecuteResponse) Reset

func (x *ExecuteResponse) Reset()

func (*ExecuteResponse) SetError

func (x *ExecuteResponse) SetError(v *dev1.RPCError)

func (*ExecuteResponse) SetResult

func (x *ExecuteResponse) SetResult(v *dev.QueryResult)

func (*ExecuteResponse) SetSession

func (x *ExecuteResponse) SetSession(v *Session)

func (*ExecuteResponse) String

func (x *ExecuteResponse) String() string

type ExecuteResponse_builder

type ExecuteResponse_builder struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError
	// session is the updated session information.
	Session *Session
	// result contains the query result, only set if error is unset.
	Result *dev.QueryResult
	// contains filtered or unexported fields
}

func (ExecuteResponse_builder) Build

type PrepareData

type PrepareData struct {
	PrepareStatement string `protobuf:"bytes,1,opt,name=prepare_statement,json=prepareStatement,proto3" json:"prepare_statement,omitempty"`
	ParamsCount      int32  `protobuf:"varint,2,opt,name=params_count,json=paramsCount,proto3" json:"params_count,omitempty"`
	// contains filtered or unexported fields
}

PrepareData keeps the prepared statement and other information related for execution of it.

func (*PrepareData) GetParamsCount

func (x *PrepareData) GetParamsCount() int32

func (*PrepareData) GetPrepareStatement

func (x *PrepareData) GetPrepareStatement() string

func (*PrepareData) ProtoMessage

func (*PrepareData) ProtoMessage()

func (*PrepareData) ProtoReflect

func (x *PrepareData) ProtoReflect() protoreflect.Message

func (*PrepareData) Reset

func (x *PrepareData) Reset()

func (*PrepareData) SetParamsCount

func (x *PrepareData) SetParamsCount(v int32)

func (*PrepareData) SetPrepareStatement

func (x *PrepareData) SetPrepareStatement(v string)

func (*PrepareData) String

func (x *PrepareData) String() string

type PrepareData_builder

type PrepareData_builder struct {
	PrepareStatement string
	ParamsCount      int32
	// contains filtered or unexported fields
}

func (PrepareData_builder) Build

func (b0 PrepareData_builder) Build() *PrepareData

type PrepareRequest

type PrepareRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// session carries the session state.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// query is the query and bind variables to execute.
	Query *dev.BoundQuery `protobuf:"bytes,3,opt,name=query,proto3" json:"query,omitempty"`
	// contains filtered or unexported fields
}

PrepareRequest is the payload to Prepare.

func (*PrepareRequest) ClearCallerId

func (x *PrepareRequest) ClearCallerId()

func (*PrepareRequest) ClearQuery

func (x *PrepareRequest) ClearQuery()

func (*PrepareRequest) ClearSession

func (x *PrepareRequest) ClearSession()

func (*PrepareRequest) GetCallerId

func (x *PrepareRequest) GetCallerId() *dev1.CallerID

func (*PrepareRequest) GetQuery

func (x *PrepareRequest) GetQuery() *dev.BoundQuery

func (*PrepareRequest) GetSession

func (x *PrepareRequest) GetSession() *Session

func (*PrepareRequest) HasCallerId

func (x *PrepareRequest) HasCallerId() bool

func (*PrepareRequest) HasQuery

func (x *PrepareRequest) HasQuery() bool

func (*PrepareRequest) HasSession

func (x *PrepareRequest) HasSession() bool

func (*PrepareRequest) ProtoMessage

func (*PrepareRequest) ProtoMessage()

func (*PrepareRequest) ProtoReflect

func (x *PrepareRequest) ProtoReflect() protoreflect.Message

func (*PrepareRequest) Reset

func (x *PrepareRequest) Reset()

func (*PrepareRequest) SetCallerId

func (x *PrepareRequest) SetCallerId(v *dev1.CallerID)

func (*PrepareRequest) SetQuery

func (x *PrepareRequest) SetQuery(v *dev.BoundQuery)

func (*PrepareRequest) SetSession

func (x *PrepareRequest) SetSession(v *Session)

func (*PrepareRequest) String

func (x *PrepareRequest) String() string

type PrepareRequest_builder

type PrepareRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// session carries the session state.
	Session *Session
	// query is the query and bind variables to execute.
	Query *dev.BoundQuery
	// contains filtered or unexported fields
}

func (PrepareRequest_builder) Build

type PrepareResponse

type PrepareResponse struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
	// session is the updated session information.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// fields contains the fields, only set if error is unset.
	Fields      []*dev.Field `protobuf:"bytes,3,rep,name=fields,proto3" json:"fields,omitempty"`
	ParamsCount uint32       `protobuf:"varint,4,opt,name=params_count,json=paramsCount,proto3" json:"params_count,omitempty"`
	// contains filtered or unexported fields
}

PrepareResponse is the returned value from Prepare.

func (*PrepareResponse) ClearError

func (x *PrepareResponse) ClearError()

func (*PrepareResponse) ClearSession

func (x *PrepareResponse) ClearSession()

func (*PrepareResponse) GetError

func (x *PrepareResponse) GetError() *dev1.RPCError

func (*PrepareResponse) GetFields

func (x *PrepareResponse) GetFields() []*dev.Field

func (*PrepareResponse) GetParamsCount

func (x *PrepareResponse) GetParamsCount() uint32

func (*PrepareResponse) GetSession

func (x *PrepareResponse) GetSession() *Session

func (*PrepareResponse) HasError

func (x *PrepareResponse) HasError() bool

func (*PrepareResponse) HasSession

func (x *PrepareResponse) HasSession() bool

func (*PrepareResponse) ProtoMessage

func (*PrepareResponse) ProtoMessage()

func (*PrepareResponse) ProtoReflect

func (x *PrepareResponse) ProtoReflect() protoreflect.Message

func (*PrepareResponse) Reset

func (x *PrepareResponse) Reset()

func (*PrepareResponse) SetError

func (x *PrepareResponse) SetError(v *dev1.RPCError)

func (*PrepareResponse) SetFields

func (x *PrepareResponse) SetFields(v []*dev.Field)

func (*PrepareResponse) SetParamsCount

func (x *PrepareResponse) SetParamsCount(v uint32)

func (*PrepareResponse) SetSession

func (x *PrepareResponse) SetSession(v *Session)

func (*PrepareResponse) String

func (x *PrepareResponse) String() string

type PrepareResponse_builder

type PrepareResponse_builder struct {

	// error contains an application level error if necessary. Note the
	// session may have changed, even when an error is returned (for
	// instance if a database integrity error happened).
	Error *dev1.RPCError
	// session is the updated session information.
	Session *Session
	// fields contains the fields, only set if error is unset.
	Fields      []*dev.Field
	ParamsCount uint32
	// contains filtered or unexported fields
}

func (PrepareResponse_builder) Build

type ReadAfterWrite

type ReadAfterWrite struct {
	ReadAfterWriteGtid    string  `protobuf:"bytes,1,opt,name=read_after_write_gtid,json=readAfterWriteGtid,proto3" json:"read_after_write_gtid,omitempty"`
	ReadAfterWriteTimeout float64 `` /* 130-byte string literal not displayed */
	SessionTrackGtids     bool    `protobuf:"varint,3,opt,name=session_track_gtids,json=sessionTrackGtids,proto3" json:"session_track_gtids,omitempty"`
	// contains filtered or unexported fields
}

ReadAfterWrite contains information regarding gtid set and timeout Also if the gtid information needs to be passed to client.

func (*ReadAfterWrite) GetReadAfterWriteGtid

func (x *ReadAfterWrite) GetReadAfterWriteGtid() string

func (*ReadAfterWrite) GetReadAfterWriteTimeout

func (x *ReadAfterWrite) GetReadAfterWriteTimeout() float64

func (*ReadAfterWrite) GetSessionTrackGtids

func (x *ReadAfterWrite) GetSessionTrackGtids() bool

func (*ReadAfterWrite) ProtoMessage

func (*ReadAfterWrite) ProtoMessage()

func (*ReadAfterWrite) ProtoReflect

func (x *ReadAfterWrite) ProtoReflect() protoreflect.Message

func (*ReadAfterWrite) Reset

func (x *ReadAfterWrite) Reset()

func (*ReadAfterWrite) SetReadAfterWriteGtid

func (x *ReadAfterWrite) SetReadAfterWriteGtid(v string)

func (*ReadAfterWrite) SetReadAfterWriteTimeout

func (x *ReadAfterWrite) SetReadAfterWriteTimeout(v float64)

func (*ReadAfterWrite) SetSessionTrackGtids

func (x *ReadAfterWrite) SetSessionTrackGtids(v bool)

func (*ReadAfterWrite) String

func (x *ReadAfterWrite) String() string

type ReadAfterWrite_builder

type ReadAfterWrite_builder struct {
	ReadAfterWriteGtid    string
	ReadAfterWriteTimeout float64
	SessionTrackGtids     bool
	// contains filtered or unexported fields
}

func (ReadAfterWrite_builder) Build

type ResolveTransactionRequest

type ResolveTransactionRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// dtid is the dtid of the transaction to be resolved.
	Dtid string `protobuf:"bytes,2,opt,name=dtid,proto3" json:"dtid,omitempty"`
	// contains filtered or unexported fields
}

ResolveTransactionRequest is the payload to ResolveTransaction.

func (*ResolveTransactionRequest) ClearCallerId

func (x *ResolveTransactionRequest) ClearCallerId()

func (*ResolveTransactionRequest) GetCallerId

func (x *ResolveTransactionRequest) GetCallerId() *dev1.CallerID

func (*ResolveTransactionRequest) GetDtid

func (x *ResolveTransactionRequest) GetDtid() string

func (*ResolveTransactionRequest) HasCallerId

func (x *ResolveTransactionRequest) HasCallerId() bool

func (*ResolveTransactionRequest) ProtoMessage

func (*ResolveTransactionRequest) ProtoMessage()

func (*ResolveTransactionRequest) ProtoReflect

func (*ResolveTransactionRequest) Reset

func (x *ResolveTransactionRequest) Reset()

func (*ResolveTransactionRequest) SetCallerId

func (x *ResolveTransactionRequest) SetCallerId(v *dev1.CallerID)

func (*ResolveTransactionRequest) SetDtid

func (x *ResolveTransactionRequest) SetDtid(v string)

func (*ResolveTransactionRequest) String

func (x *ResolveTransactionRequest) String() string

type ResolveTransactionRequest_builder

type ResolveTransactionRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// dtid is the dtid of the transaction to be resolved.
	Dtid string
	// contains filtered or unexported fields
}

func (ResolveTransactionRequest_builder) Build

type ResolveTransactionResponse

type ResolveTransactionResponse struct {
	// contains filtered or unexported fields
}

ResolveTransactionResponse is the returned value from Rollback.

func (*ResolveTransactionResponse) ProtoMessage

func (*ResolveTransactionResponse) ProtoMessage()

func (*ResolveTransactionResponse) ProtoReflect

func (*ResolveTransactionResponse) Reset

func (x *ResolveTransactionResponse) Reset()

func (*ResolveTransactionResponse) String

func (x *ResolveTransactionResponse) String() string

type ResolveTransactionResponse_builder

type ResolveTransactionResponse_builder struct {
	// contains filtered or unexported fields
}

func (ResolveTransactionResponse_builder) Build

type Session

type Session struct {

	// in_transaction is set to true if the session is in a transaction.
	InTransaction bool `protobuf:"varint,1,opt,name=in_transaction,json=inTransaction,proto3" json:"in_transaction,omitempty"`
	// shard_sessions keep track of per-shard transaction info.
	ShardSessions []*Session_ShardSession `protobuf:"bytes,2,rep,name=shard_sessions,json=shardSessions,proto3" json:"shard_sessions,omitempty"`
	// autocommit specifies if the session is in autocommit mode.
	// This is used only for V3.
	Autocommit bool `protobuf:"varint,4,opt,name=autocommit,proto3" json:"autocommit,omitempty"`
	// target_string is the target expressed as a string. Valid
	// names are: keyspace:shard@target, keyspace@target or @target.
	// This is used only for V3.
	TargetString string `protobuf:"bytes,5,opt,name=target_string,json=targetString,proto3" json:"target_string,omitempty"`
	// options is used only for V3.
	Options *dev.ExecuteOptions `protobuf:"bytes,6,opt,name=options,proto3" json:"options,omitempty"`
	// transaction_mode specifies the current transaction mode.
	TransactionMode TransactionMode `` /* 146-byte string literal not displayed */
	// warnings contains non-fatal warnings from the previous query
	Warnings []*dev.QueryWarning `protobuf:"bytes,8,rep,name=warnings,proto3" json:"warnings,omitempty"`
	// pre_sessions contains sessions that have to be committed first.
	PreSessions []*Session_ShardSession `protobuf:"bytes,9,rep,name=pre_sessions,json=preSessions,proto3" json:"pre_sessions,omitempty"`
	// post_sessions contains sessions that have to be committed last.
	PostSessions []*Session_ShardSession `protobuf:"bytes,10,rep,name=post_sessions,json=postSessions,proto3" json:"post_sessions,omitempty"`
	// last_insert_id keeps track of the last seen insert_id for this session
	LastInsertId uint64 `protobuf:"varint,11,opt,name=last_insert_id,json=lastInsertId,proto3" json:"last_insert_id,omitempty"`
	// found_rows keeps track of how many rows the last query returned
	FoundRows uint64 `protobuf:"varint,12,opt,name=found_rows,json=foundRows,proto3" json:"found_rows,omitempty"`
	// user_defined_variables contains all the @variables defined for this session
	UserDefinedVariables map[string]*dev.BindVariable `` /* 198-byte string literal not displayed */
	// system_variables keeps track of all session variables set for this connection
	// TODO: systay should we keep this so we can apply it ordered?
	SystemVariables map[string]string `` /* 181-byte string literal not displayed */
	// row_count keeps track of the last seen rows affected for this session
	RowCount int64 `protobuf:"varint,15,opt,name=row_count,json=rowCount,proto3" json:"row_count,omitempty"`
	// Stores savepoint and release savepoint calls inside a transaction
	// and is reset once transaction is committed or rolled back.
	Savepoints []string `protobuf:"bytes,16,rep,name=savepoints,proto3" json:"savepoints,omitempty"`
	// in_reserved_conn is set to true if the session should be using reserved connections.
	InReservedConn bool `protobuf:"varint,17,opt,name=in_reserved_conn,json=inReservedConn,proto3" json:"in_reserved_conn,omitempty"`
	// lock_session keep tracks of shard on which the lock query is sent.
	LockSession *Session_ShardSession `protobuf:"bytes,18,opt,name=lock_session,json=lockSession,proto3" json:"lock_session,omitempty"`
	// last_lock_heartbeat keep tracks of when last lock heartbeat was sent.
	LastLockHeartbeat int64 `protobuf:"varint,19,opt,name=last_lock_heartbeat,json=lastLockHeartbeat,proto3" json:"last_lock_heartbeat,omitempty"`
	// read_after_write tracks the ReadAfterWrite settings for this session.
	ReadAfterWrite *ReadAfterWrite `protobuf:"bytes,20,opt,name=read_after_write,json=readAfterWrite,proto3" json:"read_after_write,omitempty"`
	// DDL strategy
	DDLStrategy string `protobuf:"bytes,21,opt,name=DDLStrategy,proto3" json:"DDLStrategy,omitempty"`
	// Session UUID
	SessionUUID string `protobuf:"bytes,22,opt,name=SessionUUID,proto3" json:"SessionUUID,omitempty"`
	// enable_system_settings defines if we can use reserved connections.
	EnableSystemSettings bool             `protobuf:"varint,23,opt,name=enable_system_settings,json=enableSystemSettings,proto3" json:"enable_system_settings,omitempty"`
	AdvisoryLock         map[string]int64 `` /* 173-byte string literal not displayed */
	// query_timeout is the maximum amount of time a query is permitted to run
	QueryTimeout     int64                   `protobuf:"varint,25,opt,name=query_timeout,json=queryTimeout,proto3" json:"query_timeout,omitempty"`
	PrepareStatement map[string]*PrepareData `` /* 184-byte string literal not displayed */
	// MigrationContext
	MigrationContext   string `protobuf:"bytes,27,opt,name=migration_context,json=migrationContext,proto3" json:"migration_context,omitempty"`
	ErrorUntilRollback bool   `protobuf:"varint,28,opt,name=error_until_rollback,json=errorUntilRollback,proto3" json:"error_until_rollback,omitempty"`
	// contains filtered or unexported fields
}

Session objects are exchanged like cookies through various calls to VTGate. The behavior differs between V2 & V3 APIs. V3 APIs are Execute, ExecuteBatch and StreamExecute. All other APIs are V2. For the V3 APIs, the session must be sent with every call to Execute or ExecuteBatch. For the V2 APIs, Begin does not accept a session. It instead returns a brand new one with in_transaction set to true. After a call to Commit or Rollback, the session can be discarded. If you're not in a transaction, Session is an optional parameter for the V2 APIs.

func (*Session) ClearLockSession

func (x *Session) ClearLockSession()

func (*Session) ClearOptions

func (x *Session) ClearOptions()

func (*Session) ClearReadAfterWrite

func (x *Session) ClearReadAfterWrite()

func (*Session) GetAdvisoryLock

func (x *Session) GetAdvisoryLock() map[string]int64

func (*Session) GetAutocommit

func (x *Session) GetAutocommit() bool

func (*Session) GetDDLStrategy

func (x *Session) GetDDLStrategy() string

func (*Session) GetEnableSystemSettings

func (x *Session) GetEnableSystemSettings() bool

func (*Session) GetErrorUntilRollback

func (x *Session) GetErrorUntilRollback() bool

func (*Session) GetFoundRows

func (x *Session) GetFoundRows() uint64

func (*Session) GetInReservedConn

func (x *Session) GetInReservedConn() bool

func (*Session) GetInTransaction

func (x *Session) GetInTransaction() bool

func (*Session) GetLastInsertId

func (x *Session) GetLastInsertId() uint64

func (*Session) GetLastLockHeartbeat

func (x *Session) GetLastLockHeartbeat() int64

func (*Session) GetLockSession

func (x *Session) GetLockSession() *Session_ShardSession

func (*Session) GetMigrationContext

func (x *Session) GetMigrationContext() string

func (*Session) GetOptions

func (x *Session) GetOptions() *dev.ExecuteOptions

func (*Session) GetPostSessions

func (x *Session) GetPostSessions() []*Session_ShardSession

func (*Session) GetPreSessions

func (x *Session) GetPreSessions() []*Session_ShardSession

func (*Session) GetPrepareStatement

func (x *Session) GetPrepareStatement() map[string]*PrepareData

func (*Session) GetQueryTimeout

func (x *Session) GetQueryTimeout() int64

func (*Session) GetReadAfterWrite

func (x *Session) GetReadAfterWrite() *ReadAfterWrite

func (*Session) GetRowCount

func (x *Session) GetRowCount() int64

func (*Session) GetSavepoints

func (x *Session) GetSavepoints() []string

func (*Session) GetSessionUUID

func (x *Session) GetSessionUUID() string

func (*Session) GetShardSessions

func (x *Session) GetShardSessions() []*Session_ShardSession

func (*Session) GetSystemVariables

func (x *Session) GetSystemVariables() map[string]string

func (*Session) GetTargetString

func (x *Session) GetTargetString() string

func (*Session) GetTransactionMode

func (x *Session) GetTransactionMode() TransactionMode

func (*Session) GetUserDefinedVariables

func (x *Session) GetUserDefinedVariables() map[string]*dev.BindVariable

func (*Session) GetWarnings

func (x *Session) GetWarnings() []*dev.QueryWarning

func (*Session) HasLockSession

func (x *Session) HasLockSession() bool

func (*Session) HasOptions

func (x *Session) HasOptions() bool

func (*Session) HasReadAfterWrite

func (x *Session) HasReadAfterWrite() bool

func (*Session) ProtoMessage

func (*Session) ProtoMessage()

func (*Session) ProtoReflect

func (x *Session) ProtoReflect() protoreflect.Message

func (*Session) Reset

func (x *Session) Reset()

func (*Session) SetAdvisoryLock

func (x *Session) SetAdvisoryLock(v map[string]int64)

func (*Session) SetAutocommit

func (x *Session) SetAutocommit(v bool)

func (*Session) SetDDLStrategy

func (x *Session) SetDDLStrategy(v string)

func (*Session) SetEnableSystemSettings

func (x *Session) SetEnableSystemSettings(v bool)

func (*Session) SetErrorUntilRollback

func (x *Session) SetErrorUntilRollback(v bool)

func (*Session) SetFoundRows

func (x *Session) SetFoundRows(v uint64)

func (*Session) SetInReservedConn

func (x *Session) SetInReservedConn(v bool)

func (*Session) SetInTransaction

func (x *Session) SetInTransaction(v bool)

func (*Session) SetLastInsertId

func (x *Session) SetLastInsertId(v uint64)

func (*Session) SetLastLockHeartbeat

func (x *Session) SetLastLockHeartbeat(v int64)

func (*Session) SetLockSession

func (x *Session) SetLockSession(v *Session_ShardSession)

func (*Session) SetMigrationContext

func (x *Session) SetMigrationContext(v string)

func (*Session) SetOptions

func (x *Session) SetOptions(v *dev.ExecuteOptions)

func (*Session) SetPostSessions

func (x *Session) SetPostSessions(v []*Session_ShardSession)

func (*Session) SetPreSessions

func (x *Session) SetPreSessions(v []*Session_ShardSession)

func (*Session) SetPrepareStatement

func (x *Session) SetPrepareStatement(v map[string]*PrepareData)

func (*Session) SetQueryTimeout

func (x *Session) SetQueryTimeout(v int64)

func (*Session) SetReadAfterWrite

func (x *Session) SetReadAfterWrite(v *ReadAfterWrite)

func (*Session) SetRowCount

func (x *Session) SetRowCount(v int64)

func (*Session) SetSavepoints

func (x *Session) SetSavepoints(v []string)

func (*Session) SetSessionUUID

func (x *Session) SetSessionUUID(v string)

func (*Session) SetShardSessions

func (x *Session) SetShardSessions(v []*Session_ShardSession)

func (*Session) SetSystemVariables

func (x *Session) SetSystemVariables(v map[string]string)

func (*Session) SetTargetString

func (x *Session) SetTargetString(v string)

func (*Session) SetTransactionMode

func (x *Session) SetTransactionMode(v TransactionMode)

func (*Session) SetUserDefinedVariables

func (x *Session) SetUserDefinedVariables(v map[string]*dev.BindVariable)

func (*Session) SetWarnings

func (x *Session) SetWarnings(v []*dev.QueryWarning)

func (*Session) String

func (x *Session) String() string

type Session_ShardSession

type Session_ShardSession struct {
	Target        *dev.Target       `protobuf:"bytes,1,opt,name=target,proto3" json:"target,omitempty"`
	TransactionId int64             `protobuf:"varint,2,opt,name=transaction_id,json=transactionId,proto3" json:"transaction_id,omitempty"`
	TabletAlias   *dev2.TabletAlias `protobuf:"bytes,3,opt,name=tablet_alias,json=tabletAlias,proto3" json:"tablet_alias,omitempty"`
	// reserved connection if a dedicated connection is needed
	ReservedId int64 `protobuf:"varint,4,opt,name=reserved_id,json=reservedId,proto3" json:"reserved_id,omitempty"`
	// read_only is true if the session has only executed read queries.
	ReadOnly bool `protobuf:"varint,5,opt,name=read_only,json=readOnly,proto3" json:"read_only,omitempty"`
	// rows_affected tracks if any query has modified the rows.
	RowsAffected bool `protobuf:"varint,6,opt,name=rows_affected,json=rowsAffected,proto3" json:"rows_affected,omitempty"`
	// contains filtered or unexported fields
}

func (*Session_ShardSession) ClearTabletAlias

func (x *Session_ShardSession) ClearTabletAlias()

func (*Session_ShardSession) ClearTarget

func (x *Session_ShardSession) ClearTarget()

func (*Session_ShardSession) GetReadOnly

func (x *Session_ShardSession) GetReadOnly() bool

func (*Session_ShardSession) GetReservedId

func (x *Session_ShardSession) GetReservedId() int64

func (*Session_ShardSession) GetRowsAffected

func (x *Session_ShardSession) GetRowsAffected() bool

func (*Session_ShardSession) GetTabletAlias

func (x *Session_ShardSession) GetTabletAlias() *dev2.TabletAlias

func (*Session_ShardSession) GetTarget

func (x *Session_ShardSession) GetTarget() *dev.Target

func (*Session_ShardSession) GetTransactionId

func (x *Session_ShardSession) GetTransactionId() int64

func (*Session_ShardSession) HasTabletAlias

func (x *Session_ShardSession) HasTabletAlias() bool

func (*Session_ShardSession) HasTarget

func (x *Session_ShardSession) HasTarget() bool

func (*Session_ShardSession) ProtoMessage

func (*Session_ShardSession) ProtoMessage()

func (*Session_ShardSession) ProtoReflect

func (x *Session_ShardSession) ProtoReflect() protoreflect.Message

func (*Session_ShardSession) Reset

func (x *Session_ShardSession) Reset()

func (*Session_ShardSession) SetReadOnly

func (x *Session_ShardSession) SetReadOnly(v bool)

func (*Session_ShardSession) SetReservedId

func (x *Session_ShardSession) SetReservedId(v int64)

func (*Session_ShardSession) SetRowsAffected

func (x *Session_ShardSession) SetRowsAffected(v bool)

func (*Session_ShardSession) SetTabletAlias

func (x *Session_ShardSession) SetTabletAlias(v *dev2.TabletAlias)

func (*Session_ShardSession) SetTarget

func (x *Session_ShardSession) SetTarget(v *dev.Target)

func (*Session_ShardSession) SetTransactionId

func (x *Session_ShardSession) SetTransactionId(v int64)

func (*Session_ShardSession) String

func (x *Session_ShardSession) String() string

type Session_ShardSession_builder

type Session_ShardSession_builder struct {
	Target        *dev.Target
	TransactionId int64
	TabletAlias   *dev2.TabletAlias
	// reserved connection if a dedicated connection is needed
	ReservedId int64
	// read_only is true if the session has only executed read queries.
	ReadOnly bool
	// rows_affected tracks if any query has modified the rows.
	RowsAffected bool
	// contains filtered or unexported fields
}

func (Session_ShardSession_builder) Build

type Session_builder

type Session_builder struct {

	// in_transaction is set to true if the session is in a transaction.
	InTransaction bool
	// shard_sessions keep track of per-shard transaction info.
	ShardSessions []*Session_ShardSession
	// autocommit specifies if the session is in autocommit mode.
	// This is used only for V3.
	Autocommit bool
	// target_string is the target expressed as a string. Valid
	// names are: keyspace:shard@target, keyspace@target or @target.
	// This is used only for V3.
	TargetString string
	// options is used only for V3.
	Options *dev.ExecuteOptions
	// transaction_mode specifies the current transaction mode.
	TransactionMode TransactionMode
	// warnings contains non-fatal warnings from the previous query
	Warnings []*dev.QueryWarning
	// pre_sessions contains sessions that have to be committed first.
	PreSessions []*Session_ShardSession
	// post_sessions contains sessions that have to be committed last.
	PostSessions []*Session_ShardSession
	// last_insert_id keeps track of the last seen insert_id for this session
	LastInsertId uint64
	// found_rows keeps track of how many rows the last query returned
	FoundRows uint64
	// user_defined_variables contains all the @variables defined for this session
	UserDefinedVariables map[string]*dev.BindVariable
	// system_variables keeps track of all session variables set for this connection
	// TODO: systay should we keep this so we can apply it ordered?
	SystemVariables map[string]string
	// row_count keeps track of the last seen rows affected for this session
	RowCount int64
	// Stores savepoint and release savepoint calls inside a transaction
	// and is reset once transaction is committed or rolled back.
	Savepoints []string
	// in_reserved_conn is set to true if the session should be using reserved connections.
	InReservedConn bool
	// lock_session keep tracks of shard on which the lock query is sent.
	LockSession *Session_ShardSession
	// last_lock_heartbeat keep tracks of when last lock heartbeat was sent.
	LastLockHeartbeat int64
	// read_after_write tracks the ReadAfterWrite settings for this session.
	ReadAfterWrite *ReadAfterWrite
	// DDL strategy
	DDLStrategy string
	// Session UUID
	SessionUUID string
	// enable_system_settings defines if we can use reserved connections.
	EnableSystemSettings bool
	AdvisoryLock         map[string]int64
	// query_timeout is the maximum amount of time a query is permitted to run
	QueryTimeout     int64
	PrepareStatement map[string]*PrepareData
	// MigrationContext
	MigrationContext   string
	ErrorUntilRollback bool
	// contains filtered or unexported fields
}

func (Session_builder) Build

func (b0 Session_builder) Build() *Session

type StreamExecuteMultiRequest

type StreamExecuteMultiRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// sql contains the set of queries to execute.
	Sql string `protobuf:"bytes,2,opt,name=sql,proto3" json:"sql,omitempty"`
	// session carries the session state.
	Session *Session `protobuf:"bytes,3,opt,name=session,proto3" json:"session,omitempty"`
	// contains filtered or unexported fields
}

StreamExecuteMultiRequest is the payload to StreamExecuteMulti.

func (*StreamExecuteMultiRequest) ClearCallerId

func (x *StreamExecuteMultiRequest) ClearCallerId()

func (*StreamExecuteMultiRequest) ClearSession

func (x *StreamExecuteMultiRequest) ClearSession()

func (*StreamExecuteMultiRequest) GetCallerId

func (x *StreamExecuteMultiRequest) GetCallerId() *dev1.CallerID

func (*StreamExecuteMultiRequest) GetSession

func (x *StreamExecuteMultiRequest) GetSession() *Session

func (*StreamExecuteMultiRequest) GetSql

func (x *StreamExecuteMultiRequest) GetSql() string

func (*StreamExecuteMultiRequest) HasCallerId

func (x *StreamExecuteMultiRequest) HasCallerId() bool

func (*StreamExecuteMultiRequest) HasSession

func (x *StreamExecuteMultiRequest) HasSession() bool

func (*StreamExecuteMultiRequest) ProtoMessage

func (*StreamExecuteMultiRequest) ProtoMessage()

func (*StreamExecuteMultiRequest) ProtoReflect

func (*StreamExecuteMultiRequest) Reset

func (x *StreamExecuteMultiRequest) Reset()

func (*StreamExecuteMultiRequest) SetCallerId

func (x *StreamExecuteMultiRequest) SetCallerId(v *dev1.CallerID)

func (*StreamExecuteMultiRequest) SetSession

func (x *StreamExecuteMultiRequest) SetSession(v *Session)

func (*StreamExecuteMultiRequest) SetSql

func (x *StreamExecuteMultiRequest) SetSql(v string)

func (*StreamExecuteMultiRequest) String

func (x *StreamExecuteMultiRequest) String() string

type StreamExecuteMultiRequest_builder

type StreamExecuteMultiRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// sql contains the set of queries to execute.
	Sql string
	// session carries the session state.
	Session *Session
	// contains filtered or unexported fields
}

func (StreamExecuteMultiRequest_builder) Build

type StreamExecuteMultiResponse

type StreamExecuteMultiResponse struct {

	// result contains the result set or an error if one occurred while executing the query.
	Result *dev.ResultWithError `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"`
	// more_results is set to true if there are more results to follow after this one has concluded.
	MoreResults bool `protobuf:"varint,2,opt,name=more_results,json=moreResults,proto3" json:"more_results,omitempty"`
	// new_result signifies a new result has started with this packet.
	NewResult bool `protobuf:"varint,3,opt,name=new_result,json=newResult,proto3" json:"new_result,omitempty"`
	// session is the updated session information.
	Session *Session `protobuf:"bytes,4,opt,name=session,proto3" json:"session,omitempty"`
	// contains filtered or unexported fields
}

StreamExecuteMultiResponse is the returned value from StreamExecuteMulti.

func (*StreamExecuteMultiResponse) ClearResult

func (x *StreamExecuteMultiResponse) ClearResult()

func (*StreamExecuteMultiResponse) ClearSession

func (x *StreamExecuteMultiResponse) ClearSession()

func (*StreamExecuteMultiResponse) GetMoreResults

func (x *StreamExecuteMultiResponse) GetMoreResults() bool

func (*StreamExecuteMultiResponse) GetNewResult

func (x *StreamExecuteMultiResponse) GetNewResult() bool

func (*StreamExecuteMultiResponse) GetResult

func (*StreamExecuteMultiResponse) GetSession

func (x *StreamExecuteMultiResponse) GetSession() *Session

func (*StreamExecuteMultiResponse) HasResult

func (x *StreamExecuteMultiResponse) HasResult() bool

func (*StreamExecuteMultiResponse) HasSession

func (x *StreamExecuteMultiResponse) HasSession() bool

func (*StreamExecuteMultiResponse) ProtoMessage

func (*StreamExecuteMultiResponse) ProtoMessage()

func (*StreamExecuteMultiResponse) ProtoReflect

func (*StreamExecuteMultiResponse) Reset

func (x *StreamExecuteMultiResponse) Reset()

func (*StreamExecuteMultiResponse) SetMoreResults

func (x *StreamExecuteMultiResponse) SetMoreResults(v bool)

func (*StreamExecuteMultiResponse) SetNewResult

func (x *StreamExecuteMultiResponse) SetNewResult(v bool)

func (*StreamExecuteMultiResponse) SetResult

func (*StreamExecuteMultiResponse) SetSession

func (x *StreamExecuteMultiResponse) SetSession(v *Session)

func (*StreamExecuteMultiResponse) String

func (x *StreamExecuteMultiResponse) String() string

type StreamExecuteMultiResponse_builder

type StreamExecuteMultiResponse_builder struct {

	// result contains the result set or an error if one occurred while executing the query.
	Result *dev.ResultWithError
	// more_results is set to true if there are more results to follow after this one has concluded.
	MoreResults bool
	// new_result signifies a new result has started with this packet.
	NewResult bool
	// session is the updated session information.
	Session *Session
	// contains filtered or unexported fields
}

func (StreamExecuteMultiResponse_builder) Build

type StreamExecuteRequest

type StreamExecuteRequest struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	// query is the query and bind variables to execute.
	Query *dev.BoundQuery `protobuf:"bytes,2,opt,name=query,proto3" json:"query,omitempty"`
	// session carries the session state.
	Session *Session `protobuf:"bytes,6,opt,name=session,proto3" json:"session,omitempty"`
	// contains filtered or unexported fields
}

StreamExecuteRequest is the payload to StreamExecute.

func (*StreamExecuteRequest) ClearCallerId

func (x *StreamExecuteRequest) ClearCallerId()

func (*StreamExecuteRequest) ClearQuery

func (x *StreamExecuteRequest) ClearQuery()

func (*StreamExecuteRequest) ClearSession

func (x *StreamExecuteRequest) ClearSession()

func (*StreamExecuteRequest) GetCallerId

func (x *StreamExecuteRequest) GetCallerId() *dev1.CallerID

func (*StreamExecuteRequest) GetQuery

func (x *StreamExecuteRequest) GetQuery() *dev.BoundQuery

func (*StreamExecuteRequest) GetSession

func (x *StreamExecuteRequest) GetSession() *Session

func (*StreamExecuteRequest) HasCallerId

func (x *StreamExecuteRequest) HasCallerId() bool

func (*StreamExecuteRequest) HasQuery

func (x *StreamExecuteRequest) HasQuery() bool

func (*StreamExecuteRequest) HasSession

func (x *StreamExecuteRequest) HasSession() bool

func (*StreamExecuteRequest) ProtoMessage

func (*StreamExecuteRequest) ProtoMessage()

func (*StreamExecuteRequest) ProtoReflect

func (x *StreamExecuteRequest) ProtoReflect() protoreflect.Message

func (*StreamExecuteRequest) Reset

func (x *StreamExecuteRequest) Reset()

func (*StreamExecuteRequest) SetCallerId

func (x *StreamExecuteRequest) SetCallerId(v *dev1.CallerID)

func (*StreamExecuteRequest) SetQuery

func (x *StreamExecuteRequest) SetQuery(v *dev.BoundQuery)

func (*StreamExecuteRequest) SetSession

func (x *StreamExecuteRequest) SetSession(v *Session)

func (*StreamExecuteRequest) String

func (x *StreamExecuteRequest) String() string

type StreamExecuteRequest_builder

type StreamExecuteRequest_builder struct {

	// caller_id identifies the caller. This is the effective caller ID,
	// set by the application to further identify the caller.
	CallerId *dev1.CallerID
	// query is the query and bind variables to execute.
	Query *dev.BoundQuery
	// session carries the session state.
	Session *Session
	// contains filtered or unexported fields
}

func (StreamExecuteRequest_builder) Build

type StreamExecuteResponse

type StreamExecuteResponse struct {

	// result contains the result data.
	// The first value contains only Fields information.
	// The next values contain the actual rows, a few values per result.
	Result *dev.QueryResult `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"`
	// session is the updated session information.
	Session *Session `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// contains filtered or unexported fields
}

StreamExecuteResponse is the returned value from StreamExecute. The session is currently not returned because StreamExecute is not expected to modify it.

func (*StreamExecuteResponse) ClearResult

func (x *StreamExecuteResponse) ClearResult()

func (*StreamExecuteResponse) ClearSession

func (x *StreamExecuteResponse) ClearSession()

func (*StreamExecuteResponse) GetResult

func (x *StreamExecuteResponse) GetResult() *dev.QueryResult

func (*StreamExecuteResponse) GetSession

func (x *StreamExecuteResponse) GetSession() *Session

func (*StreamExecuteResponse) HasResult

func (x *StreamExecuteResponse) HasResult() bool

func (*StreamExecuteResponse) HasSession

func (x *StreamExecuteResponse) HasSession() bool

func (*StreamExecuteResponse) ProtoMessage

func (*StreamExecuteResponse) ProtoMessage()

func (*StreamExecuteResponse) ProtoReflect

func (x *StreamExecuteResponse) ProtoReflect() protoreflect.Message

func (*StreamExecuteResponse) Reset

func (x *StreamExecuteResponse) Reset()

func (*StreamExecuteResponse) SetResult

func (x *StreamExecuteResponse) SetResult(v *dev.QueryResult)

func (*StreamExecuteResponse) SetSession

func (x *StreamExecuteResponse) SetSession(v *Session)

func (*StreamExecuteResponse) String

func (x *StreamExecuteResponse) String() string

type StreamExecuteResponse_builder

type StreamExecuteResponse_builder struct {

	// result contains the result data.
	// The first value contains only Fields information.
	// The next values contain the actual rows, a few values per result.
	Result *dev.QueryResult
	// session is the updated session information.
	Session *Session
	// contains filtered or unexported fields
}

func (StreamExecuteResponse_builder) Build

type TransactionMode

type TransactionMode int32

TransactionMode controls the execution of distributed transaction across multiple shards.

const (
	// UNSPECIFIED uses the transaction mode set by the VTGate flag 'transaction_mode'.
	TransactionMode_UNSPECIFIED TransactionMode = 0
	// SINGLE disallows distributed transactions.
	TransactionMode_SINGLE TransactionMode = 1
	// MULTI allows distributed transactions with best effort commit.
	TransactionMode_MULTI TransactionMode = 2
	// TWOPC is for distributed transactions with atomic commits.
	TransactionMode_TWOPC TransactionMode = 3
)

func (TransactionMode) Descriptor

func (TransactionMode) Enum

func (x TransactionMode) Enum() *TransactionMode

func (TransactionMode) Number

func (TransactionMode) String

func (x TransactionMode) String() string

func (TransactionMode) Type

type VStreamFlags

type VStreamFlags struct {

	// align streams
	MinimizeSkew bool `protobuf:"varint,1,opt,name=minimize_skew,json=minimizeSkew,proto3" json:"minimize_skew,omitempty"`
	// how often heartbeats must be sent when idle (seconds)
	HeartbeatInterval uint32 `protobuf:"varint,2,opt,name=heartbeat_interval,json=heartbeatInterval,proto3" json:"heartbeat_interval,omitempty"`
	// stop streams on a reshard (journal event)
	StopOnReshard bool `protobuf:"varint,3,opt,name=stop_on_reshard,json=stopOnReshard,proto3" json:"stop_on_reshard,omitempty"`
	// if specified, these cells (comma-separated) are used to pick source tablets from.
	// defaults to the cell of the vtgate serving the VStream API.
	Cells          string `protobuf:"bytes,4,opt,name=cells,proto3" json:"cells,omitempty"`
	CellPreference string `protobuf:"bytes,5,opt,name=cell_preference,json=cellPreference,proto3" json:"cell_preference,omitempty"`
	TabletOrder    string `protobuf:"bytes,6,opt,name=tablet_order,json=tabletOrder,proto3" json:"tablet_order,omitempty"`
	// When set, all new row events from the `heartbeat` table, for all shards, in the sidecardb will be streamed.
	StreamKeyspaceHeartbeats bool `` /* 136-byte string literal not displayed */
	// Include reshard journal events in the stream.
	IncludeReshardJournalEvents bool `` /* 147-byte string literal not displayed */
	// Copy only these tables, skip the rest in the filter.
	// If not provided, the default behaviour is to copy all tables.
	TablesToCopy []string `protobuf:"bytes,9,rep,name=tables_to_copy,json=tablesToCopy,proto3" json:"tables_to_copy,omitempty"`
	// Exclude the keyspace from the table name that is sent to the vstream client
	ExcludeKeyspaceFromTableName bool `` /* 153-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*VStreamFlags) GetCellPreference

func (x *VStreamFlags) GetCellPreference() string

func (*VStreamFlags) GetCells

func (x *VStreamFlags) GetCells() string

func (*VStreamFlags) GetExcludeKeyspaceFromTableName

func (x *VStreamFlags) GetExcludeKeyspaceFromTableName() bool

func (*VStreamFlags) GetHeartbeatInterval

func (x *VStreamFlags) GetHeartbeatInterval() uint32

func (*VStreamFlags) GetIncludeReshardJournalEvents

func (x *VStreamFlags) GetIncludeReshardJournalEvents() bool

func (*VStreamFlags) GetMinimizeSkew

func (x *VStreamFlags) GetMinimizeSkew() bool

func (*VStreamFlags) GetStopOnReshard

func (x *VStreamFlags) GetStopOnReshard() bool

func (*VStreamFlags) GetStreamKeyspaceHeartbeats

func (x *VStreamFlags) GetStreamKeyspaceHeartbeats() bool

func (*VStreamFlags) GetTablesToCopy

func (x *VStreamFlags) GetTablesToCopy() []string

func (*VStreamFlags) GetTabletOrder

func (x *VStreamFlags) GetTabletOrder() string

func (*VStreamFlags) ProtoMessage

func (*VStreamFlags) ProtoMessage()

func (*VStreamFlags) ProtoReflect

func (x *VStreamFlags) ProtoReflect() protoreflect.Message

func (*VStreamFlags) Reset

func (x *VStreamFlags) Reset()

func (*VStreamFlags) SetCellPreference

func (x *VStreamFlags) SetCellPreference(v string)

func (*VStreamFlags) SetCells

func (x *VStreamFlags) SetCells(v string)

func (*VStreamFlags) SetExcludeKeyspaceFromTableName

func (x *VStreamFlags) SetExcludeKeyspaceFromTableName(v bool)

func (*VStreamFlags) SetHeartbeatInterval

func (x *VStreamFlags) SetHeartbeatInterval(v uint32)

func (*VStreamFlags) SetIncludeReshardJournalEvents

func (x *VStreamFlags) SetIncludeReshardJournalEvents(v bool)

func (*VStreamFlags) SetMinimizeSkew

func (x *VStreamFlags) SetMinimizeSkew(v bool)

func (*VStreamFlags) SetStopOnReshard

func (x *VStreamFlags) SetStopOnReshard(v bool)

func (*VStreamFlags) SetStreamKeyspaceHeartbeats

func (x *VStreamFlags) SetStreamKeyspaceHeartbeats(v bool)

func (*VStreamFlags) SetTablesToCopy

func (x *VStreamFlags) SetTablesToCopy(v []string)

func (*VStreamFlags) SetTabletOrder

func (x *VStreamFlags) SetTabletOrder(v string)

func (*VStreamFlags) String

func (x *VStreamFlags) String() string

type VStreamFlags_builder

type VStreamFlags_builder struct {

	// align streams
	MinimizeSkew bool
	// how often heartbeats must be sent when idle (seconds)
	HeartbeatInterval uint32
	// stop streams on a reshard (journal event)
	StopOnReshard bool
	// if specified, these cells (comma-separated) are used to pick source tablets from.
	// defaults to the cell of the vtgate serving the VStream API.
	Cells          string
	CellPreference string
	TabletOrder    string
	// When set, all new row events from the `heartbeat` table, for all shards, in the sidecardb will be streamed.
	StreamKeyspaceHeartbeats bool
	// Include reshard journal events in the stream.
	IncludeReshardJournalEvents bool
	// Copy only these tables, skip the rest in the filter.
	// If not provided, the default behaviour is to copy all tables.
	TablesToCopy []string
	// Exclude the keyspace from the table name that is sent to the vstream client
	ExcludeKeyspaceFromTableName bool
	// contains filtered or unexported fields
}

func (VStreamFlags_builder) Build

func (b0 VStreamFlags_builder) Build() *VStreamFlags

type VStreamRequest

type VStreamRequest struct {
	CallerId   *dev1.CallerID  `protobuf:"bytes,1,opt,name=caller_id,json=callerId,proto3" json:"caller_id,omitempty"`
	TabletType dev2.TabletType `` /* 128-byte string literal not displayed */
	// position specifies the starting point of the bin log positions
	// as well as the keyspace-shards to pull events from.
	// position is of the form 'ks1:0@MySQL56/<mysql_pos>|ks2:-80@MySQL56/<mysql_pos>'.
	Vgtid  *dev3.VGtid   `protobuf:"bytes,3,opt,name=vgtid,proto3" json:"vgtid,omitempty"`
	Filter *dev3.Filter  `protobuf:"bytes,4,opt,name=filter,proto3" json:"filter,omitempty"`
	Flags  *VStreamFlags `protobuf:"bytes,5,opt,name=flags,proto3" json:"flags,omitempty"`
	// contains filtered or unexported fields
}

VStreamRequest is the payload for VStream.

func (*VStreamRequest) ClearCallerId

func (x *VStreamRequest) ClearCallerId()

func (*VStreamRequest) ClearFilter

func (x *VStreamRequest) ClearFilter()

func (*VStreamRequest) ClearFlags

func (x *VStreamRequest) ClearFlags()

func (*VStreamRequest) ClearVgtid

func (x *VStreamRequest) ClearVgtid()

func (*VStreamRequest) GetCallerId

func (x *VStreamRequest) GetCallerId() *dev1.CallerID

func (*VStreamRequest) GetFilter

func (x *VStreamRequest) GetFilter() *dev3.Filter

func (*VStreamRequest) GetFlags

func (x *VStreamRequest) GetFlags() *VStreamFlags

func (*VStreamRequest) GetTabletType

func (x *VStreamRequest) GetTabletType() dev2.TabletType

func (*VStreamRequest) GetVgtid

func (x *VStreamRequest) GetVgtid() *dev3.VGtid

func (*VStreamRequest) HasCallerId

func (x *VStreamRequest) HasCallerId() bool

func (*VStreamRequest) HasFilter

func (x *VStreamRequest) HasFilter() bool

func (*VStreamRequest) HasFlags

func (x *VStreamRequest) HasFlags() bool

func (*VStreamRequest) HasVgtid

func (x *VStreamRequest) HasVgtid() bool

func (*VStreamRequest) ProtoMessage

func (*VStreamRequest) ProtoMessage()

func (*VStreamRequest) ProtoReflect

func (x *VStreamRequest) ProtoReflect() protoreflect.Message

func (*VStreamRequest) Reset

func (x *VStreamRequest) Reset()

func (*VStreamRequest) SetCallerId

func (x *VStreamRequest) SetCallerId(v *dev1.CallerID)

func (*VStreamRequest) SetFilter

func (x *VStreamRequest) SetFilter(v *dev3.Filter)

func (*VStreamRequest) SetFlags

func (x *VStreamRequest) SetFlags(v *VStreamFlags)

func (*VStreamRequest) SetTabletType

func (x *VStreamRequest) SetTabletType(v dev2.TabletType)

func (*VStreamRequest) SetVgtid

func (x *VStreamRequest) SetVgtid(v *dev3.VGtid)

func (*VStreamRequest) String

func (x *VStreamRequest) String() string

type VStreamRequest_builder

type VStreamRequest_builder struct {
	CallerId   *dev1.CallerID
	TabletType dev2.TabletType
	// position specifies the starting point of the bin log positions
	// as well as the keyspace-shards to pull events from.
	// position is of the form 'ks1:0@MySQL56/<mysql_pos>|ks2:-80@MySQL56/<mysql_pos>'.
	Vgtid  *dev3.VGtid
	Filter *dev3.Filter
	Flags  *VStreamFlags
	// contains filtered or unexported fields
}

func (VStreamRequest_builder) Build

type VStreamResponse

type VStreamResponse struct {
	Events []*dev3.VEvent `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"`
	// contains filtered or unexported fields
}

VStreamResponse is streamed by VStream.

func (*VStreamResponse) GetEvents

func (x *VStreamResponse) GetEvents() []*dev3.VEvent

func (*VStreamResponse) ProtoMessage

func (*VStreamResponse) ProtoMessage()

func (*VStreamResponse) ProtoReflect

func (x *VStreamResponse) ProtoReflect() protoreflect.Message

func (*VStreamResponse) Reset

func (x *VStreamResponse) Reset()

func (*VStreamResponse) SetEvents

func (x *VStreamResponse) SetEvents(v []*dev3.VEvent)

func (*VStreamResponse) String

func (x *VStreamResponse) String() string

type VStreamResponse_builder

type VStreamResponse_builder struct {
	Events []*dev3.VEvent
	// contains filtered or unexported fields
}

func (VStreamResponse_builder) Build

Source Files

  • vtgate.pb.go

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL