setting

package
v0.0.0-...-5952180 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppSetting

type AppSetting struct {
	DefaultPageSize      int
	MaxPageSize          int
	LogSavePath          string
	LogFileName          string
	LogFileExt           string
	UploadSavePath       string
	UploadSaveUrl        string
	UploadImageMaxSize   int
	UploadImageAllowExts []string
}

type DatabaseSetting

type DatabaseSetting struct {
	DbType       string
	UserName     string
	Password     string
	Host         string
	DBName       string
	TablePrefix  string
	Charset      string
	ParseTime    bool
	MaxIdleConns int
	MaxOpenConns int
}

type JWTSetting

type JWTSetting struct {
	Secret string
	Issuer string
	Expire time.Duration
}

type JaegerSetting

type JaegerSetting struct {
	HostPort string
}

type ServerSetting

type ServerSetting struct {
	ServiceName  string
	RunMode      string
	HttpPort     string
	ReadTimeout  time.Duration
	WriteTimeout time.Duration
}

type Setting

type Setting struct {
	// contains filtered or unexported fields
}

func NewSetting

func NewSetting(configPaths ...string) (*Setting, error)

func (*Setting) ReadSection

func (s *Setting) ReadSection(k string, v interface{}) error

func (*Setting) ReloadAllSection

func (s *Setting) ReloadAllSection() error

func (*Setting) WatchSettingChange

func (s *Setting) WatchSettingChange()

Jump to

Keyboard shortcuts

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