Documentation ¶
Index ¶
- Variables
- func Schema(table string) (o sql.Schema)
- type Auth
- func (a Auth) AuthMethod(user, addr string) (string, error)
- func (a Auth) Negotiate(c *mysql.Conn, user string, remoteAddr net.Addr) (mysql.Getter, error)
- func (a Auth) Salt() ([]byte, error)
- func (a Auth) ValidateHash(salt []byte, user string, authResponse []byte, remoteAddr net.Addr) (mysql.Getter, error)
- type DB
- type Engine
- type Handler
- func (h *Handler) ComInitDB(c *mysql.Conn, schemaName string) error
- func (h *Handler) ComMultiQuery(c *mysql.Conn, query string, callback func(*sqltypes.Result, bool) error) (string, error)
- func (h *Handler) ComPrepare(c *mysql.Conn, query string) ([]*query.Field, error)
- func (h *Handler) ComQuery(c *mysql.Conn, query string, callback func(*sqltypes.Result, bool) error) error
- func (h *Handler) ComResetConnection(c *mysql.Conn)
- func (h *Handler) ComStmtExecute(c *mysql.Conn, prepare *mysql.PrepareData, ...) error
- func (h *Handler) ConnectionClosed(c *mysql.Conn)
- func (h *Handler) NewConnection(c *mysql.Conn)
- func (h *Handler) ParserOptionsForConnection(c *mysql.Conn) (sqlparser.ParserOptions, error)
- func (h *Handler) WarningCount(c *mysql.Conn) uint16
- type Partition
- type Provider
- type Server
- type StaticUserData
- type Table
- func (t *Table) Collation() sql.CollationID
- func (t *Table) Name() string
- func (t *Table) PartitionRows(*sql.Context, sql.Partition) (sql.RowIter, error)
- func (t *Table) Partitions(*sql.Context) (sql.PartitionIter, error)
- func (t *Table) Projections() []string
- func (t *Table) Schema() sql.Schema
- func (t *Table) String() string
- func (t *Table) WithProjections(colNames []string) sql.Table
Constants ¶
This section is empty.
Variables ¶
var ( // QueryCounter describes a metric that accumulates number of queries monotonically. QueryCounter = discard.NewCounter() // QueryErrorCounter describes a metric that accumulates number of failed queries monotonically. QueryErrorCounter = discard.NewCounter() // QueryHistogram describes a queries latency. QueryHistogram = discard.NewHistogram() )
Functions ¶
Types ¶
type DB ¶ added in v0.0.28
type DB struct {
// contains filtered or unexported fields
}
func (*DB) GetTableInsensitive ¶ added in v0.0.28
func (*DB) GetTableNames ¶ added in v0.0.28
func (DB) IsReadOnly ¶ added in v0.0.28
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler is a connection handler for a SQLe engine, implementing the Vitess mysql.Handler interface.
func (*Handler) ComMultiQuery ¶
func (*Handler) ComPrepare ¶
ComPrepare parses, partially analyzes, and caches a prepared statement's plan with the given [c.ConnectionID].
func (*Handler) ComQuery ¶
func (h *Handler) ComQuery( c *mysql.Conn, query string, callback func(*sqltypes.Result, bool) error, ) error
ComQuery executes a SQL query on the SQLe engine.
func (*Handler) ComResetConnection ¶
func (*Handler) ComStmtExecute ¶
func (*Handler) ConnectionClosed ¶
ConnectionClosed reports that a connection has been closed.
func (*Handler) NewConnection ¶
NewConnection reports that a new connection has been established.
func (*Handler) ParserOptionsForConnection ¶
func (*Handler) WarningCount ¶
WarningCount is called at the end of each query to obtain the value to be returned to the client in the EOF packet. Note that this will be called either in the context of the ComQuery callback if the result does not contain any fields, or after the last ComQuery call completes.
type Partition ¶ added in v0.0.28
type Partition struct {
// contains filtered or unexported fields
}
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
type StaticUserData ¶
type StaticUserData string
func (StaticUserData) Get ¶
func (sud StaticUserData) Get() *querypb.VTGateCallerID
Get returns the wrapped username and groups
type Table ¶
type Table struct {
// contains filtered or unexported fields
}
func (*Table) Collation ¶ added in v0.0.28
func (t *Table) Collation() sql.CollationID