Documentation ¶
Index ¶
- Variables
- func Inject(container *dig.Container)
- type BootConfig
- func (*BootConfig) Descriptor() ([]byte, []int)deprecated
- func (x *BootConfig) GetDatabase() *Database
- func (x *BootConfig) GetEnvironment() string
- func (x *BootConfig) GetEtcd() *Etcd
- func (x *BootConfig) GetLogger() *Logger
- func (x *BootConfig) GetRedis() *Redis
- func (x *BootConfig) GetServer() *Server
- func (x *BootConfig) GetService() *Service
- func (x *BootConfig) GetTrace() *Trace
- func (*BootConfig) ProtoMessage()
- func (x *BootConfig) ProtoReflect() protoreflect.Message
- func (x *BootConfig) Reset()
- func (x *BootConfig) String() string
- type Database
- type Etcd
- type Logger
- type Redis
- func (*Redis) Descriptor() ([]byte, []int)deprecated
- func (x *Redis) GetAddr() string
- func (x *Redis) GetNetwork() string
- func (x *Redis) GetReadTimeout() *durationpb.Duration
- func (x *Redis) GetWriteTimeout() *durationpb.Duration
- func (*Redis) ProtoMessage()
- func (x *Redis) ProtoReflect() protoreflect.Message
- func (x *Redis) Reset()
- func (x *Redis) String() string
- type Server
- type Server_GRPC
- func (*Server_GRPC) Descriptor() ([]byte, []int)deprecated
- func (x *Server_GRPC) GetAddr() string
- func (x *Server_GRPC) GetNetwork() string
- func (x *Server_GRPC) GetTimeout() *durationpb.Duration
- func (*Server_GRPC) ProtoMessage()
- func (x *Server_GRPC) ProtoReflect() protoreflect.Message
- func (x *Server_GRPC) Reset()
- func (x *Server_GRPC) String() string
- type Server_HTTP
- func (*Server_HTTP) Descriptor() ([]byte, []int)deprecated
- func (x *Server_HTTP) GetAddr() string
- func (x *Server_HTTP) GetNetwork() string
- func (x *Server_HTTP) GetTimeout() *durationpb.Duration
- func (*Server_HTTP) ProtoMessage()
- func (x *Server_HTTP) ProtoReflect() protoreflect.Message
- func (x *Server_HTTP) Reset()
- func (x *Server_HTTP) String() string
- type Service
- func (*Service) Descriptor() ([]byte, []int)deprecated
- func (x *Service) GetId() string
- func (x *Service) GetName() string
- func (x *Service) GetVersion() string
- func (*Service) ProtoMessage()
- func (x *Service) ProtoReflect() protoreflect.Message
- func (x *Service) Reset()
- func (x *Service) String() string
- type Trace
Constants ¶
This section is empty.
Variables ¶
View Source
var File_config_conf_proto protoreflect.FileDescriptor
Functions ¶
Types ¶
type BootConfig ¶
type BootConfig struct { Environment string `protobuf:"bytes,1,opt,name=environment,proto3" json:"environment,omitempty"` //建议配置成:dev、product、local Service *Service `protobuf:"bytes,2,opt,name=service,proto3" json:"service,omitempty"` Server *Server `protobuf:"bytes,3,opt,name=server,proto3" json:"server,omitempty"` Database *Database `protobuf:"bytes,4,opt,name=database,proto3" json:"database,omitempty"` Redis *Redis `protobuf:"bytes,5,opt,name=redis,proto3" json:"redis,omitempty"` Etcd *Etcd `protobuf:"bytes,6,opt,name=etcd,proto3" json:"etcd,omitempty"` Trace *Trace `protobuf:"bytes,7,opt,name=trace,proto3" json:"trace,omitempty"` Logger *Logger `protobuf:"bytes,8,opt,name=logger,proto3" json:"logger,omitempty"` // contains filtered or unexported fields }
func (*BootConfig) Descriptor
deprecated
func (*BootConfig) Descriptor() ([]byte, []int)
Deprecated: Use BootConfig.ProtoReflect.Descriptor instead.
func (*BootConfig) GetDatabase ¶
func (x *BootConfig) GetDatabase() *Database
func (*BootConfig) GetEnvironment ¶
func (x *BootConfig) GetEnvironment() string
func (*BootConfig) GetEtcd ¶
func (x *BootConfig) GetEtcd() *Etcd
func (*BootConfig) GetLogger ¶
func (x *BootConfig) GetLogger() *Logger
func (*BootConfig) GetRedis ¶
func (x *BootConfig) GetRedis() *Redis
func (*BootConfig) GetServer ¶
func (x *BootConfig) GetServer() *Server
func (*BootConfig) GetService ¶
func (x *BootConfig) GetService() *Service
func (*BootConfig) GetTrace ¶
func (x *BootConfig) GetTrace() *Trace
func (*BootConfig) ProtoMessage ¶
func (*BootConfig) ProtoMessage()
func (*BootConfig) ProtoReflect ¶
func (x *BootConfig) ProtoReflect() protoreflect.Message
func (*BootConfig) Reset ¶
func (x *BootConfig) Reset()
func (*BootConfig) String ¶
func (x *BootConfig) String() string
type Database ¶
type Database struct { Dsn string `protobuf:"bytes,1,opt,name=dsn,proto3" json:"dsn,omitempty"` // contains filtered or unexported fields }
func (*Database) Descriptor
deprecated
func (*Database) ProtoMessage ¶
func (*Database) ProtoMessage()
func (*Database) ProtoReflect ¶
func (x *Database) ProtoReflect() protoreflect.Message
type Etcd ¶
type Etcd struct { Endpoints []string `protobuf:"bytes,1,rep,name=endpoints,proto3" json:"endpoints,omitempty"` // contains filtered or unexported fields }
func (*Etcd) Descriptor
deprecated
func (*Etcd) GetEndpoints ¶
func (*Etcd) ProtoMessage ¶
func (*Etcd) ProtoMessage()
func (*Etcd) ProtoReflect ¶
func (x *Etcd) ProtoReflect() protoreflect.Message
type Logger ¶
type Logger struct { Platform string `protobuf:"bytes,1,opt,name=platform,proto3" json:"platform,omitempty"` Setting string `protobuf:"bytes,2,opt,name=setting,proto3" json:"setting,omitempty"` // contains filtered or unexported fields }
func (*Logger) Descriptor
deprecated
func (*Logger) GetPlatform ¶
func (*Logger) GetSetting ¶
func (*Logger) ProtoMessage ¶
func (*Logger) ProtoMessage()
func (*Logger) ProtoReflect ¶
func (x *Logger) ProtoReflect() protoreflect.Message
type Redis ¶
type Redis struct { Network string `protobuf:"bytes,1,opt,name=network,proto3" json:"network,omitempty"` Addr string `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"` ReadTimeout *durationpb.Duration `protobuf:"bytes,3,opt,name=read_timeout,json=readTimeout,proto3" json:"read_timeout,omitempty"` WriteTimeout *durationpb.Duration `protobuf:"bytes,4,opt,name=write_timeout,json=writeTimeout,proto3" json:"write_timeout,omitempty"` // contains filtered or unexported fields }
func (*Redis) Descriptor
deprecated
func (*Redis) GetNetwork ¶
func (*Redis) GetReadTimeout ¶
func (x *Redis) GetReadTimeout() *durationpb.Duration
func (*Redis) GetWriteTimeout ¶
func (x *Redis) GetWriteTimeout() *durationpb.Duration
func (*Redis) ProtoMessage ¶
func (*Redis) ProtoMessage()
func (*Redis) ProtoReflect ¶
func (x *Redis) ProtoReflect() protoreflect.Message
type Server ¶
type Server struct { Http *Server_HTTP `protobuf:"bytes,1,opt,name=http,proto3" json:"http,omitempty"` Grpc *Server_GRPC `protobuf:"bytes,2,opt,name=grpc,proto3" json:"grpc,omitempty"` // contains filtered or unexported fields }
func (*Server) Descriptor
deprecated
func (*Server) GetGrpc ¶
func (x *Server) GetGrpc() *Server_GRPC
func (*Server) GetHttp ¶
func (x *Server) GetHttp() *Server_HTTP
func (*Server) ProtoMessage ¶
func (*Server) ProtoMessage()
func (*Server) ProtoReflect ¶
func (x *Server) ProtoReflect() protoreflect.Message
type Server_GRPC ¶
type Server_GRPC struct { Network string `protobuf:"bytes,1,opt,name=network,proto3" json:"network,omitempty"` Addr string `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"` Timeout *durationpb.Duration `protobuf:"bytes,3,opt,name=timeout,proto3" json:"timeout,omitempty"` // contains filtered or unexported fields }
func (*Server_GRPC) Descriptor
deprecated
func (*Server_GRPC) Descriptor() ([]byte, []int)
Deprecated: Use Server_GRPC.ProtoReflect.Descriptor instead.
func (*Server_GRPC) GetAddr ¶
func (x *Server_GRPC) GetAddr() string
func (*Server_GRPC) GetNetwork ¶
func (x *Server_GRPC) GetNetwork() string
func (*Server_GRPC) GetTimeout ¶
func (x *Server_GRPC) GetTimeout() *durationpb.Duration
func (*Server_GRPC) ProtoMessage ¶
func (*Server_GRPC) ProtoMessage()
func (*Server_GRPC) ProtoReflect ¶
func (x *Server_GRPC) ProtoReflect() protoreflect.Message
func (*Server_GRPC) Reset ¶
func (x *Server_GRPC) Reset()
func (*Server_GRPC) String ¶
func (x *Server_GRPC) String() string
type Server_HTTP ¶
type Server_HTTP struct { Network string `protobuf:"bytes,1,opt,name=network,proto3" json:"network,omitempty"` Addr string `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"` Timeout *durationpb.Duration `protobuf:"bytes,3,opt,name=timeout,proto3" json:"timeout,omitempty"` // contains filtered or unexported fields }
func (*Server_HTTP) Descriptor
deprecated
func (*Server_HTTP) Descriptor() ([]byte, []int)
Deprecated: Use Server_HTTP.ProtoReflect.Descriptor instead.
func (*Server_HTTP) GetAddr ¶
func (x *Server_HTTP) GetAddr() string
func (*Server_HTTP) GetNetwork ¶
func (x *Server_HTTP) GetNetwork() string
func (*Server_HTTP) GetTimeout ¶
func (x *Server_HTTP) GetTimeout() *durationpb.Duration
func (*Server_HTTP) ProtoMessage ¶
func (*Server_HTTP) ProtoMessage()
func (*Server_HTTP) ProtoReflect ¶
func (x *Server_HTTP) ProtoReflect() protoreflect.Message
func (*Server_HTTP) Reset ¶
func (x *Server_HTTP) Reset()
func (*Server_HTTP) String ¶
func (x *Server_HTTP) String() string
type Service ¶
type Service struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"` Id string `protobuf:"bytes,3,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*Service) Descriptor
deprecated
func (*Service) GetVersion ¶
func (*Service) ProtoMessage ¶
func (*Service) ProtoMessage()
func (*Service) ProtoReflect ¶
func (x *Service) ProtoReflect() protoreflect.Message
type Trace ¶
type Trace struct { Endpoint string `protobuf:"bytes,1,opt,name=endpoint,proto3" json:"endpoint,omitempty"` // contains filtered or unexported fields }
func (*Trace) Descriptor
deprecated
func (*Trace) GetEndpoint ¶
func (*Trace) ProtoMessage ¶
func (*Trace) ProtoMessage()
func (*Trace) ProtoReflect ¶
func (x *Trace) ProtoReflect() protoreflect.Message
Click to show internal directories.
Click to hide internal directories.