Documentation ¶
Index ¶
- type DataProvider
- type SqliteProvide
- func (sp *SqliteProvide) Close() error
- func (sp *SqliteProvide) GetCommandStats(serverId, fromDate, toDate, groupBy string) ([]map[string]interface{}, error)
- func (sp *SqliteProvide) GetInfo(serverId string) (map[string]interface{}, error)
- func (sp *SqliteProvide) GetMemoryInfo(serverId, fromDate, toDate string) ([]map[string]interface{}, error)
- func (sp *SqliteProvide) GetTopCommandsStats(serverId, fromDate, toDate string) ([]map[string]interface{}, error)
- func (sp *SqliteProvide) GetTopKeysStats(serverId, fromDate, toDate string) ([]map[string]interface{}, error)
- func (sp *SqliteProvide) SaveInfoCommand(server string, info map[string]string) int64
- func (sp *SqliteProvide) SaveMemoryInfo(server string, used int, peak int) int64
- func (sp *SqliteProvide) SaveMonitorCommand(server, command, keyname, argument, timestamp string) int64
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataProvider ¶
type DataProvider interface { SaveMemoryInfo(server string, used int, peak int) int64 SaveInfoCommand(server string, info map[string]string) int64 SaveMonitorCommand(server, command, argument, keyname, timestamp string) int64 Close() error GetInfo(serverId string) (map[string]interface{}, error) GetMemoryInfo(serverId, fromDate, toDate string) ([]map[string]interface{}, error) GetCommandStats(serverId, fromDate, toDate, groupBy string) ([]map[string]interface{}, error) GetTopCommandsStats(serverId, fromDate, toDate string) ([]map[string]interface{}, error) GetTopKeysStats(serverId, fromDate, toDate string) ([]map[string]interface{}, error) }
func NewProvider ¶
func NewProvider(config *conf.Config) (DataProvider, error)
type SqliteProvide ¶
type SqliteProvide struct {
// contains filtered or unexported fields
}
func NewSqliteProvide ¶
func NewSqliteProvide(dbPath string) (*SqliteProvide, error)
func (*SqliteProvide) Close ¶
func (sp *SqliteProvide) Close() error
func (*SqliteProvide) GetCommandStats ¶
func (sp *SqliteProvide) GetCommandStats(serverId, fromDate, toDate, groupBy string) ([]map[string]interface{}, error)
func (*SqliteProvide) GetInfo ¶
func (sp *SqliteProvide) GetInfo(serverId string) (map[string]interface{}, error)
func (*SqliteProvide) GetMemoryInfo ¶
func (sp *SqliteProvide) GetMemoryInfo(serverId, fromDate, toDate string) ([]map[string]interface{}, error)
func (*SqliteProvide) GetTopCommandsStats ¶
func (sp *SqliteProvide) GetTopCommandsStats(serverId, fromDate, toDate string) ([]map[string]interface{}, error)
func (*SqliteProvide) GetTopKeysStats ¶
func (sp *SqliteProvide) GetTopKeysStats(serverId, fromDate, toDate string) ([]map[string]interface{}, error)
func (*SqliteProvide) SaveInfoCommand ¶
func (sp *SqliteProvide) SaveInfoCommand(server string, info map[string]string) int64
func (*SqliteProvide) SaveMemoryInfo ¶
func (sp *SqliteProvide) SaveMemoryInfo(server string, used int, peak int) int64
func (*SqliteProvide) SaveMonitorCommand ¶
func (sp *SqliteProvide) SaveMonitorCommand(server, command, keyname, argument, timestamp string) int64
Click to show internal directories.
Click to hide internal directories.