config

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: May 25, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Server  Server    `json:"server"`
	MySQL   MySQL     `json:"mysql"`
	Mapping []Mapping `json:"mapping"`
}

func (*Config) EnsureDefault

func (c *Config) EnsureDefault()

type Mapping

type Mapping struct {
	Name        string `json:"name"`
	KeyColumn   string `json:"keyColumn"`
	ValueColumn string `json:"valueColumn"`
	Table       string `json:"table"`
}

func (*Mapping) EnsureDefault

func (c *Mapping) EnsureDefault()

type MySQL

type MySQL struct {
	Connection      string
	Password        string        `json:"password"`
	User            string        `json:"user"`
	Host            string        `json:"host"`
	Port            int           `json:"port"`
	Database        string        `json:"database"`
	ConnMaxLifetime time.Duration `json:"connMaxLifetime"`
	MaxOpenConns    int           `json:"maxOpenConns"`
	MaxIdleConns    int           `json:"maxIdleConns"`
}

type Server

type Server struct {
	Host string `json:"host"`
	Port int    `json:"port"`
}

Jump to

Keyboard shortcuts

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