Documentation ¶
Index ¶
- func ForeachSQLQuery(loader IteratorLoader, f func(Query) error) error
- func GetKeyspaces(vschemaFile, vtexplainVschemaFile, keyspaceName string, sharded bool) (keyspaces []*cluster.Keyspace, vschema *vindexes.VSchema, err error)
- type CSVConfig
- type CSVLogLoader
- type CmdType
- type FileType
- type IteratorLoader
- type Loader
- type MySQLLogLoader
- type Query
- type RawKeyspaceVindex
- type SlowQueryLogLoader
- type VtGateLogLoader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ForeachSQLQuery ¶
func ForeachSQLQuery(loader IteratorLoader, f func(Query) error) error
ForeachSQLQuery reads a query log file and calls the provided function for each normal SQL query in the log. If the query log contains directives, they will be read and queries will be skipped as necessary.
Types ¶
type CSVLogLoader ¶
type CSVLogLoader struct {
Config CSVConfig
}
func (CSVLogLoader) Load ¶
func (c CSVLogLoader) Load(fileName string) IteratorLoader
type FileType ¶
type FileType int
func GetFileType ¶
GetFileType reads the first key-value pair from a JSON file and returns the type of the file Note:
type IteratorLoader ¶
type Loader ¶
type Loader interface {
Load(filename string) IteratorLoader
}
type MySQLLogLoader ¶
type MySQLLogLoader struct{}
func (MySQLLogLoader) Load ¶
func (MySQLLogLoader) Load(fileName string) IteratorLoader
type RawKeyspaceVindex ¶
type RawKeyspaceVindex struct {
Keyspaces map[string]interface{} `json:"keyspaces"`
}
func ReadVschema ¶
type SlowQueryLogLoader ¶
type SlowQueryLogLoader struct{}
func (SlowQueryLogLoader) Load ¶
func (SlowQueryLogLoader) Load(filename string) IteratorLoader
type VtGateLogLoader ¶
type VtGateLogLoader struct {
NeedsBindVars bool
}
func (VtGateLogLoader) Load ¶
func (vll VtGateLogLoader) Load(fileName string) IteratorLoader
Click to show internal directories.
Click to hide internal directories.