model

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2024 License: AGPL-3.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// EnvRelease 环境
	EnvRelease = "rls:"
	EnvDev     = "dev:"
	EnvTest    = "test:"
	// 配置文件
	GatewayConfKey = "gw_ck" // 网关在etcd中的key名称
)

Variables

This section is empty.

Functions

This section is empty.

Types

type EtcdConf

type EtcdConf struct {
	Nodes []string `json:"nodes" yaml:"nodes"` // nats的url
	User  string   `json:"user" yaml:"user"`   // nats用户名
	Pwd   string   `json:"pwd" yaml:"pwd"`     // nats的密码
}

type LogConf

type LogConf struct {
	ServiceName string `json:"service_name" yaml:"service_name"` // 服务名称
	StdoutType  int    `json:"stdout_type" yaml:"stdout_type"`   // 输出类型 0:终端 1:文件 2:ES
	Path        string `json:"path" yaml:"path"`                 // 日志路径
	Level       int    `json:"level" yaml:"level"`               // 日志级别
}

type MinioConf

type MinioConf struct {
	Endpoint        string `json:"endpoint" yaml:"endpoint"`                   // nats的url
	AccessKeyID     string `json:"access_key_id" yaml:"access_key_id"`         // nats用户名
	SecretAccessKey string `json:"secret_access_key" yaml:"secret_access_key"` // nats的密码
	UseSSL          bool   `json:"use_ssl" yaml:"use_ssl"`                     // 是否开启验证
}

type NatsConf

type NatsConf struct {
	Url  string `json:"url" yaml:"url"`   // nats的url
	User string `json:"user" yaml:"user"` // nats用户名
	Pwd  string `json:"pwd" yaml:"pwd"`   // nats的密码
}

type SQLConf

type SQLConf struct {
	Host   string `json:"host" yaml:"host"`       // sql型数据库ip
	Port   string `json:"port" yaml:"port"`       // sql型数据库port
	User   string `json:"user" yaml:"user"`       // sql型数据库用户
	Pwd    string `json:"pwd" yaml:"pwd"`         // sql型数据库密码
	DBName string `json:"db_name" yaml:"db_name"` // sql型数据库的名称
	Driver string `json:"driver" yaml:"driver"`   // 数据库类型
}

SQLConf DBType数据类型目前支持的有:mysql pgl dameng

Jump to

Keyboard shortcuts

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