2020-02-21 00:33:48 +01:00
|
|
|
// Copyright (c) 2020 Shivaram Lingamneni
|
|
|
|
// released under the MIT license
|
|
|
|
|
|
|
|
package mysql
|
|
|
|
|
|
|
|
import (
|
|
|
|
"time"
|
|
|
|
)
|
|
|
|
|
|
|
|
type Config struct {
|
|
|
|
// these are intended to be written directly into the config file:
|
|
|
|
Enabled bool
|
|
|
|
Host string
|
|
|
|
Port int
|
2020-05-17 07:00:04 +02:00
|
|
|
SocketPath string `yaml:"socket-path"`
|
2020-02-21 00:33:48 +01:00
|
|
|
User string
|
|
|
|
Password string
|
|
|
|
HistoryDatabase string `yaml:"history-database"`
|
|
|
|
Timeout time.Duration
|
2021-04-23 19:54:44 +02:00
|
|
|
MaxConns int `yaml:"max-conns"`
|
|
|
|
ConnMaxLifetime time.Duration `yaml:"conn-max-lifetime"`
|
2020-02-21 00:33:48 +01:00
|
|
|
|
|
|
|
// XXX these are copied from elsewhere in the config:
|
2020-05-12 18:05:40 +02:00
|
|
|
ExpireTime time.Duration
|
|
|
|
TrackAccountMessages bool
|
2020-02-21 00:33:48 +01:00
|
|
|
}
|