Documentation
¶
Index ¶
- Constants
- type DBLogger
- func (d *DBLogger) AddLog(time string, host string, path string, method string, status_code int, ...)
- func (d *DBLogger) AddSystemMetrics(time string, cpu float64, memory float64)
- func (d *DBLogger) Close()
- func (d *DBLogger) Conn()
- func (d *DBLogger) ExecQuery(query string, args ...interface{}) (pgx.Rows, error)
- func (d *DBLogger) InitDatabase()
Constants ¶
View Source
const INIT_DB = `` /* 1067-byte string literal not displayed */
View Source
const INSERT_LOG = `
INSERT INTO log_data (time, host, path, method, status_code, latency) VALUES ($1, $2, $3, $4, $5, $6);
`
View Source
const INSERT_SYSTEM_METRICS = `
INSERT INTO system_metrics (time, cpu, memory) VALUES ($1, $2, $3);
`
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.