mysqlfe

package
v0.0.0-...-f111e62 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2017 License: MIT Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Default Max Allowed packets for connections
	MaxAllowedPacket = 4194304
)

Variables

This section is empty.

Functions

func LoadMySqlFunctions

func LoadMySqlFunctions()

func NewEmptyResultset

func NewEmptyResultset(pp *plan.Projection) *mysql.Resultset

func NewMySqlGlobalVars

func NewMySqlGlobalVars() *datasource.ContextSimple

func NewMySqlSessionVars

func NewMySqlSessionVars(db, user string, connId uint32) expr.ContextReadWriter

func TableCreate

func TableCreate(tbl *schema.Table) (string, error)

Take a table and make create statement

Types

type MySqlConnCreator

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

MySql connection handler, a single connection session

not threadsafe, not shared

func (*MySqlConnCreator) Close

func (m *MySqlConnCreator) Close() error

func (*MySqlConnCreator) Init

Init is part of frontend interface to accept config and global server context at start

func (*MySqlConnCreator) Open

func (m *MySqlConnCreator) Open(connI interface{}) models.StatementHandler

Open handler is a per-client/conn copy of handler - this occurs once when a new tcp-conn is established - it re-uses the HandlerShard with has schema, etc on it

func (*MySqlConnCreator) Run

func (m *MySqlConnCreator) Run(stop chan bool) error

func (*MySqlConnCreator) String

func (m *MySqlConnCreator) String() string

type MySqlExecResultWriter

type MySqlExecResultWriter struct {
	*exec.TaskBase

	Rs *mysql.Result
	// contains filtered or unexported fields
}

func NewMySqlExecResultWriter

func NewMySqlExecResultWriter(writer models.ResultWriter, ctx *plan.Context) *MySqlExecResultWriter

func (*MySqlExecResultWriter) Close

func (m *MySqlExecResultWriter) Close() error

func (*MySqlExecResultWriter) Finalize

func (m *MySqlExecResultWriter) Finalize() error

func (*MySqlExecResultWriter) ResultWriter

func (m *MySqlExecResultWriter) ResultWriter() exec.MessageHandler

type MySqlJob

type MySqlJob struct {
	*planner.ExecutorGrid
}

MySqlJob job that wraps the dataux distributed planner with a dialect specific one

func BuildMySqlJob

func BuildMySqlJob(svr *models.ServerCtx, ctx *plan.Context) (*MySqlJob, error)

BuildMySqlJob Create a MySql job that wraps underlying distributed planner, and qlbridge generic implementation

allowing per-method (VisitShow etc) to be replaced by a dialect specific handler.

- mysql `SHOW CREATE TABLE name` for example is dialect specific so needs to be replaced - also wraps a distributed planner from dataux

type MySqlResultWriter

type MySqlResultWriter struct {
	*exec.TaskBase

	Rs *mysql.Resultset
	// contains filtered or unexported fields
}

func NewMySqlResultWriter

func NewMySqlResultWriter(writer models.ResultWriter, ctx *plan.Context) *MySqlResultWriter

func NewMySqlSchemaWriter

func NewMySqlSchemaWriter(writer models.ResultWriter, ctx *plan.Context) *MySqlResultWriter

func (*MySqlResultWriter) Close

func (m *MySqlResultWriter) Close() error

func (*MySqlResultWriter) Finalize

func (m *MySqlResultWriter) Finalize() error

func (*MySqlResultWriter) Run

func (m *MySqlResultWriter) Run() error

func (*MySqlResultWriter) WriteHeaders

func (m *MySqlResultWriter) WriteHeaders() error

type MysqlTypeWriter

type MysqlTypeWriter struct{}

MysqlTypeWriter Convert a qlbridge value type to a mysql type

func (*MysqlTypeWriter) Eval

func (m *MysqlTypeWriter) Eval(ctx expr.EvalContext, args []value.Value) (value.Value, bool)

func (*MysqlTypeWriter) Type

func (m *MysqlTypeWriter) Type() value.ValueType

func (*MysqlTypeWriter) Validate

func (m *MysqlTypeWriter) Validate(n *expr.FuncNode) (expr.EvaluatorFunc, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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