src

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: May 26, 2020 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	INSERT eventType = 1
	UPDATE eventType = 2
	DELETE eventType = 3
	DDL    eventType = 4
)
View Source
const BIFROST_VERION = "v1.1.0"
View Source
const VERSION = "v1.1.0"

Variables

This section is empty.

Functions

func AddCount

func AddCount(dbname, schameName, tableName string, event eventType, rowsCount int, eventCount bool)

func ClearCountContent

func ClearCountContent(c *CountContent)

func GetDbList

func GetDbList() (data []string)

func GetSchameList

func GetSchameList(dbname string) (data []string)

func GetSchameTableList

func GetSchameTableList(dbname string, schema string) (data []string)

func TableCountFlow_Controller

func TableCountFlow_Controller(w http.ResponseWriter, req *http.Request)

func TableCountIndex_Controller

func TableCountIndex_Controller(w http.ResponseWriter, req *http.Request)

func TableCountSchameList_Controller

func TableCountSchameList_Controller(w http.ResponseWriter, req *http.Request)

func TableCountSchameTableList_Controller

func TableCountSchameTableList_Controller(w http.ResponseWriter, req *http.Request)

func TemplatePath

func TemplatePath(fileName string) string

Types

type Conn

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

func (*Conn) Close

func (This *Conn) Close() bool

func (*Conn) Commit

func (This *Conn) Commit() (*driver.PluginBinlog, error)

func (*Conn) Connect

func (This *Conn) Connect() bool

func (*Conn) Del

func (This *Conn) Del(data *driver.PluginDataType) (*driver.PluginBinlog, error)

func (*Conn) GetConnStatus

func (This *Conn) GetConnStatus() string

func (*Conn) GetParam

func (This *Conn) GetParam(p interface{}) (*PluginParam, error)

func (*Conn) HeartCheck

func (This *Conn) HeartCheck()

func (*Conn) Insert

func (This *Conn) Insert(data *driver.PluginDataType) (*driver.PluginBinlog, error)

func (*Conn) Query

func (This *Conn) Query(data *driver.PluginDataType) (*driver.PluginBinlog, error)

func (*Conn) ReConnect

func (This *Conn) ReConnect() bool

func (*Conn) SetConnStatus

func (This *Conn) SetConnStatus(status string)

func (*Conn) SetParam

func (This *Conn) SetParam(p interface{}) (interface{}, error)

func (*Conn) Update

func (This *Conn) Update(data *driver.PluginDataType) (*driver.PluginBinlog, error)

type CountContent

type CountContent struct {
	Time        int64
	InsertCount uint64
	UpdateCount uint64
	DeleteCount uint64
	InsertRows  uint64
	UpdateRows  uint64
	DeleteRows  uint64
	DDLCount    uint64
}

func GetFlow

func GetFlow(flowType string, dbname, schameName, tableName string) (data []CountContent, err error)

func GetFlowByDbName

func GetFlowByDbName(flowType string, dbname string) (data []CountContent, err error)

func GetFlowBySchema

func GetFlowBySchema(flowType string, dbname, schameName string) (data []CountContent, err error)

func NewCountContent

func NewCountContent() *CountContent

type CountContentArr

type CountContentArr struct {
	Count   uint8
	Data    []CountContent
	Content *CountContent
}

type CountFlow

type CountFlow struct {
	TenMinute *CountContentArr
	Hour      *CountContentArr
	EightHour *CountContentArr
	Day       *CountContentArr
	Content   *CountContent
}

func NewFlow

func NewFlow() *CountFlow

type DoSlice

type DoSlice struct {
	DoTenMinuteSlice bool
	DoHourSlice      bool
	DoEightHourSlice bool
	DoDaySlice       bool
	DoClear          bool
}

type MyConn

type MyConn struct{}

func (*MyConn) CheckUri

func (MyConn *MyConn) CheckUri(uri string) error

func (*MyConn) GetUriExample

func (MyConn *MyConn) GetUriExample() string

func (*MyConn) Open

func (MyConn *MyConn) Open(uri string) driver.ConnFun

type PluginParam

type PluginParam struct {
	DbName string
}

type TemplateHeader

type TemplateHeader struct {
	Title string
}

Jump to

Keyboard shortcuts

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