db

package
v0.0.0-...-8662ab9 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DB_HOST             = "localhost"
	DB_PORT             = 3322
	DB_USER             = "immudb"
	DB_PASSWORD         = "immudb"
	DATABASE            = "defaultdb"
	MAX_DB_CONN_RETRIES = 5
)

Variables

This section is empty.

Functions

func Close

func Close(db Database)

Types

type Database

type Database struct {
	Client immudb.ImmuClient
}

func GetDB

func GetDB() Database

func Initialize

func Initialize() (Database, error)

func (Database) AddLogLine

func (db Database) AddLogLine(logLine models.LogLine) error

func (Database) AddLogLines

func (db Database) AddLogLines(logLines models.LogLines) error

func (Database) GetLogs

func (db Database) GetLogs(opts map[string]interface{}) ([]models.LogLine, error)

func (Database) GetLogsCount

func (db Database) GetLogsCount() (int64, error)

Jump to

Keyboard shortcuts

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