Documentation
¶
Index ¶
- type App
- type Authentication
- type Backend
- type Captcha
- type Client
- type Config
- type Cors
- type DBConfig
- type DBConnect
- type DBErrorFormat
- type DBInitializer
- type DBTransformError
- type Database
- type Email
- type EmailTemplate
- type GrpcService
- type Http
- type HttpService
- type JWT
- type Logger
- type LoggerFile
- type Logging
- type Marshal
- type Pool
- type Pprof
- type Prometheus
- type Redis
- type ServerConfig
- type Signature
- type Tls
- type Tracing
- type Value
- type WatchHandleFunc
- type Watcher
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct { ID string Name string Version string Env string Server *ServerConfig Signature *Signature Log *Logger Pool *Pool Email *Email JWT *JWT Http *Http Logging *Logging Authentication *Authentication Tracing *Tracing Client []*Client Database map[string]*Database Redis map[string]*Redis Loader map[string]string Captcha map[string]*Captcha RateLimit bool Metrics bool Prometheus []*Prometheus }
type Authentication ¶
type Config ¶
type Config interface { SetAppInfo(id, name, version string) Load() error Scan(v any) error Value(key string) Value Watch(key string, o WatchHandleFunc) ScanWatch(key string, o WatchHandleFunc) Close() error App() *App IsInit() bool }
func New ¶
func New(source kratosConfig.Source) Config
type DBErrorFormat ¶
type DBInitializer ¶
type DBTransformError ¶
type DBTransformError struct { Enable bool Format *DBErrorFormat }
type EmailTemplate ¶
type GrpcService ¶
type HttpService ¶
type LoggerFile ¶
type Prometheus ¶
type ServerConfig ¶
type ServerConfig struct { Count int Registry *string Http *HttpService Grpc *GrpcService Tls *Tls }
type Value ¶
type Value interface { kratosConfig.Value }
type WatchHandleFunc ¶
type WatchHandleFunc func(Value)
type Watcher ¶
type Watcher func(key string, o WatchHandleFunc)
Click to show internal directories.
Click to hide internal directories.