Documentation
¶
Index ¶
- Variables
- type Broker
- func (*Broker) Descriptor() ([]byte, []int)deprecated
- func (x *Broker) GetAddrs() []string
- func (x *Broker) GetDisable() bool
- func (x *Broker) GetName() string
- func (x *Broker) GetPublish() *Publish
- func (x *Broker) GetSubscribe() *Subscribe
- func (*Broker) ProtoMessage()
- func (x *Broker) ProtoReflect() protoreflect.Message
- func (x *Broker) Reset()
- func (x *Broker) String() string
- type GRPCClient
- func (*GRPCClient) Descriptor() ([]byte, []int)deprecated
- func (x *GRPCClient) GetEndpoint() string
- func (x *GRPCClient) GetMiddlewares() []*Middleware
- func (x *GRPCClient) GetTimeout() *durationpb.Duration
- func (*GRPCClient) ProtoMessage()
- func (x *GRPCClient) ProtoReflect() protoreflect.Message
- func (x *GRPCClient) Reset()
- func (x *GRPCClient) String() string
- type GRPCServer
- func (*GRPCServer) Descriptor() ([]byte, []int)deprecated
- func (x *GRPCServer) GetAddr() string
- func (x *GRPCServer) GetMiddlewares() []*Middleware
- func (x *GRPCServer) GetNetwork() string
- func (x *GRPCServer) GetTimeout() *durationpb.Duration
- func (*GRPCServer) ProtoMessage()
- func (x *GRPCServer) ProtoReflect() protoreflect.Message
- func (x *GRPCServer) Reset()
- func (x *GRPCServer) String() string
- type HTTPClient
- func (*HTTPClient) Descriptor() ([]byte, []int)deprecated
- func (x *HTTPClient) GetEndpoint() string
- func (x *HTTPClient) GetMiddlewares() []*Middleware
- func (x *HTTPClient) GetTimeout() *durationpb.Duration
- func (*HTTPClient) ProtoMessage()
- func (x *HTTPClient) ProtoReflect() protoreflect.Message
- func (x *HTTPClient) Reset()
- func (x *HTTPClient) String() string
- type HTTPServer
- func (*HTTPServer) Descriptor() ([]byte, []int)deprecated
- func (x *HTTPServer) GetAddr() string
- func (x *HTTPServer) GetMiddlewares() []*Middleware
- func (x *HTTPServer) GetNetwork() string
- func (x *HTTPServer) GetTimeout() *durationpb.Duration
- func (*HTTPServer) ProtoMessage()
- func (x *HTTPServer) ProtoReflect() protoreflect.Message
- func (x *HTTPServer) Reset()
- func (x *HTTPServer) String() string
- type Logger
- func (*Logger) Descriptor() ([]byte, []int)deprecated
- func (x *Logger) GetConsole() bool
- func (x *Logger) GetFile() bool
- func (x *Logger) GetLevel() string
- func (x *Logger) GetMetadata() map[string]string
- func (x *Logger) GetPath() string
- func (*Logger) ProtoMessage()
- func (x *Logger) ProtoReflect() protoreflect.Message
- func (x *Logger) Reset()
- func (x *Logger) String() string
- type Middleware
- type Nacos
- func (*Nacos) Descriptor() ([]byte, []int)deprecated
- func (x *Nacos) GetAddress() []string
- func (x *Nacos) GetCacheDir() string
- func (x *Nacos) GetContextPath() string
- func (x *Nacos) GetDataId() string
- func (x *Nacos) GetFormat() string
- func (x *Nacos) GetGroup() string
- func (x *Nacos) GetLogDir() string
- func (x *Nacos) GetLogLevel() string
- func (x *Nacos) GetNamespace() string
- func (x *Nacos) GetPassword() string
- func (x *Nacos) GetTimeout() *durationpb.Duration
- func (x *Nacos) GetUsername() string
- func (*Nacos) ProtoMessage()
- func (x *Nacos) ProtoReflect() protoreflect.Message
- func (x *Nacos) Reset()
- func (x *Nacos) String() string
- type Next
- func (*Next) Descriptor() ([]byte, []int)deprecated
- func (x *Next) GetBroker() *Broker
- func (x *Next) GetId() string
- func (x *Next) GetLogger() *Logger
- func (x *Next) GetMetadata() map[string]string
- func (x *Next) GetNacos() *Nacos
- func (x *Next) GetName() string
- func (x *Next) GetRegistry() *Registry
- func (x *Next) GetServer() *Server
- func (x *Next) GetTelemetry() *Telemetry
- func (x *Next) GetVersion() string
- func (*Next) ProtoMessage()
- func (x *Next) ProtoReflect() protoreflect.Message
- func (x *Next) Reset()
- func (x *Next) String() string
- type Publish
- type Registry
- func (*Registry) Descriptor() ([]byte, []int)deprecated
- func (x *Registry) GetAddrs() string
- func (x *Registry) GetName() string
- func (x *Registry) GetTimeout() *durationpb.Duration
- func (*Registry) ProtoMessage()
- func (x *Registry) ProtoReflect() protoreflect.Message
- func (x *Registry) Reset()
- func (x *Registry) String() string
- type Server
- type Subscribe
- type Telemetry
- func (*Telemetry) Descriptor() ([]byte, []int)deprecated
- func (x *Telemetry) GetDisable() bool
- func (x *Telemetry) GetEndpoint() string
- func (x *Telemetry) GetExporter() string
- func (x *Telemetry) GetHeaders() map[string]string
- func (x *Telemetry) GetHttpPath() string
- func (x *Telemetry) GetSampler() float64
- func (*Telemetry) ProtoMessage()
- func (x *Telemetry) ProtoReflect() protoreflect.Message
- func (x *Telemetry) Reset()
- func (x *Telemetry) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var File_config_v1_config_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Broker ¶
type Broker struct {
Disable bool `protobuf:"varint,1,opt,name=disable,proto3" json:"disable,omitempty"` // disable tracing
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // broker name, eg: kafka, nsq
Addrs []string `protobuf:"bytes,3,rep,name=addrs,proto3" json:"addrs,omitempty"` // broker address
Publish *Publish `protobuf:"bytes,4,opt,name=publish,proto3" json:"publish,omitempty"` // broker publish config
Subscribe *Subscribe `protobuf:"bytes,5,opt,name=subscribe,proto3" json:"subscribe,omitempty"` // broker subscribe config
// contains filtered or unexported fields
}
Broker config
func (*Broker) Descriptor
deprecated
func (*Broker) GetDisable ¶ added in v1.0.10
func (*Broker) GetPublish ¶
func (*Broker) GetSubscribe ¶
func (*Broker) ProtoMessage ¶
func (*Broker) ProtoMessage()
func (*Broker) ProtoReflect ¶
func (x *Broker) ProtoReflect() protoreflect.Message
type GRPCClient ¶
type GRPCClient struct {
Endpoint string `protobuf:"bytes,1,opt,name=endpoint,proto3" json:"endpoint,omitempty"` // http client endpoint
Timeout *durationpb.Duration `protobuf:"bytes,3,opt,name=timeout,proto3" json:"timeout,omitempty"`
Middlewares []*Middleware `protobuf:"bytes,4,rep,name=middlewares,proto3" json:"middlewares,omitempty"`
// contains filtered or unexported fields
}
grpc client config
func (*GRPCClient) Descriptor
deprecated
func (*GRPCClient) Descriptor() ([]byte, []int)
Deprecated: Use GRPCClient.ProtoReflect.Descriptor instead.
func (*GRPCClient) GetEndpoint ¶
func (x *GRPCClient) GetEndpoint() string
func (*GRPCClient) GetMiddlewares ¶
func (x *GRPCClient) GetMiddlewares() []*Middleware
func (*GRPCClient) GetTimeout ¶
func (x *GRPCClient) GetTimeout() *durationpb.Duration
func (*GRPCClient) ProtoMessage ¶
func (*GRPCClient) ProtoMessage()
func (*GRPCClient) ProtoReflect ¶
func (x *GRPCClient) ProtoReflect() protoreflect.Message
func (*GRPCClient) Reset ¶
func (x *GRPCClient) Reset()
func (*GRPCClient) String ¶
func (x *GRPCClient) String() string
type GRPCServer ¶
type GRPCServer 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"`
Middlewares []*Middleware `protobuf:"bytes,4,rep,name=middlewares,proto3" json:"middlewares,omitempty"`
// contains filtered or unexported fields
}
grpc server config
func (*GRPCServer) Descriptor
deprecated
func (*GRPCServer) Descriptor() ([]byte, []int)
Deprecated: Use GRPCServer.ProtoReflect.Descriptor instead.
func (*GRPCServer) GetAddr ¶
func (x *GRPCServer) GetAddr() string
func (*GRPCServer) GetMiddlewares ¶
func (x *GRPCServer) GetMiddlewares() []*Middleware
func (*GRPCServer) GetNetwork ¶
func (x *GRPCServer) GetNetwork() string
func (*GRPCServer) GetTimeout ¶
func (x *GRPCServer) GetTimeout() *durationpb.Duration
func (*GRPCServer) ProtoMessage ¶
func (*GRPCServer) ProtoMessage()
func (*GRPCServer) ProtoReflect ¶
func (x *GRPCServer) ProtoReflect() protoreflect.Message
func (*GRPCServer) Reset ¶
func (x *GRPCServer) Reset()
func (*GRPCServer) String ¶
func (x *GRPCServer) String() string
type HTTPClient ¶
type HTTPClient struct {
Endpoint string `protobuf:"bytes,1,opt,name=endpoint,proto3" json:"endpoint,omitempty"` // http client endpoint
Timeout *durationpb.Duration `protobuf:"bytes,3,opt,name=timeout,proto3" json:"timeout,omitempty"`
Middlewares []*Middleware `protobuf:"bytes,4,rep,name=middlewares,proto3" json:"middlewares,omitempty"`
// contains filtered or unexported fields
}
http client config
func (*HTTPClient) Descriptor
deprecated
func (*HTTPClient) Descriptor() ([]byte, []int)
Deprecated: Use HTTPClient.ProtoReflect.Descriptor instead.
func (*HTTPClient) GetEndpoint ¶
func (x *HTTPClient) GetEndpoint() string
func (*HTTPClient) GetMiddlewares ¶
func (x *HTTPClient) GetMiddlewares() []*Middleware
func (*HTTPClient) GetTimeout ¶
func (x *HTTPClient) GetTimeout() *durationpb.Duration
func (*HTTPClient) ProtoMessage ¶
func (*HTTPClient) ProtoMessage()
func (*HTTPClient) ProtoReflect ¶
func (x *HTTPClient) ProtoReflect() protoreflect.Message
func (*HTTPClient) Reset ¶
func (x *HTTPClient) Reset()
func (*HTTPClient) String ¶
func (x *HTTPClient) String() string
type HTTPServer ¶
type HTTPServer 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"`
Middlewares []*Middleware `protobuf:"bytes,4,rep,name=middlewares,proto3" json:"middlewares,omitempty"`
// contains filtered or unexported fields
}
http server config
func (*HTTPServer) Descriptor
deprecated
func (*HTTPServer) Descriptor() ([]byte, []int)
Deprecated: Use HTTPServer.ProtoReflect.Descriptor instead.
func (*HTTPServer) GetAddr ¶
func (x *HTTPServer) GetAddr() string
func (*HTTPServer) GetMiddlewares ¶
func (x *HTTPServer) GetMiddlewares() []*Middleware
func (*HTTPServer) GetNetwork ¶
func (x *HTTPServer) GetNetwork() string
func (*HTTPServer) GetTimeout ¶
func (x *HTTPServer) GetTimeout() *durationpb.Duration
func (*HTTPServer) ProtoMessage ¶
func (*HTTPServer) ProtoMessage()
func (*HTTPServer) ProtoReflect ¶
func (x *HTTPServer) ProtoReflect() protoreflect.Message
func (*HTTPServer) Reset ¶
func (x *HTTPServer) Reset()
func (*HTTPServer) String ¶
func (x *HTTPServer) String() string
type Logger ¶
type Logger struct {
Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
Level string `protobuf:"bytes,2,opt,name=level,proto3" json:"level,omitempty"`
Console bool `protobuf:"varint,3,opt,name=console,proto3" json:"console,omitempty"`
File bool `protobuf:"varint,4,opt,name=file,proto3" json:"file,omitempty"`
Metadata map[string]string `` /* 157-byte string literal not displayed */
// contains filtered or unexported fields
}
logger config
func (*Logger) Descriptor
deprecated
func (*Logger) GetConsole ¶
func (*Logger) GetMetadata ¶
func (*Logger) ProtoMessage ¶
func (*Logger) ProtoMessage()
func (*Logger) ProtoReflect ¶
func (x *Logger) ProtoReflect() protoreflect.Message
type Middleware ¶
type Middleware struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Options *anypb.Any `protobuf:"bytes,2,opt,name=options,proto3" json:"options,omitempty"`
// contains filtered or unexported fields
}
middleware config
func (*Middleware) Descriptor
deprecated
func (*Middleware) Descriptor() ([]byte, []int)
Deprecated: Use Middleware.ProtoReflect.Descriptor instead.
func (*Middleware) GetName ¶
func (x *Middleware) GetName() string
func (*Middleware) GetOptions ¶
func (x *Middleware) GetOptions() *anypb.Any
func (*Middleware) ProtoMessage ¶
func (*Middleware) ProtoMessage()
func (*Middleware) ProtoReflect ¶
func (x *Middleware) ProtoReflect() protoreflect.Message
func (*Middleware) Reset ¶
func (x *Middleware) Reset()
func (*Middleware) String ¶
func (x *Middleware) String() string
type Nacos ¶
type Nacos struct {
// nacos server address
Address []string `protobuf:"bytes,1,rep,name=address,proto3" json:"address,omitempty"`
// nacos config data id
DataId string `protobuf:"bytes,2,opt,name=data_id,json=dataId,proto3" json:"data_id,omitempty"`
// nacos config group
Group string `protobuf:"bytes,3,opt,name=group,proto3" json:"group,omitempty"`
// nacos config namespace
Namespace string `protobuf:"bytes,4,opt,name=namespace,proto3" json:"namespace,omitempty"`
// nacos config username
Username string `protobuf:"bytes,5,opt,name=username,proto3" json:"username,omitempty"`
// nacos config password
Password string `protobuf:"bytes,6,opt,name=password,proto3" json:"password,omitempty"`
// the nacos server contextpath,default=/nacos,this is not required in 2.0
ContextPath string `protobuf:"bytes,7,opt,name=context_path,json=contextPath,proto3" json:"context_path,omitempty"`
// nacos config log dir
LogDir string `protobuf:"bytes,8,opt,name=log_dir,json=logDir,proto3" json:"log_dir,omitempty"`
// nacos config cache dir
CacheDir string `protobuf:"bytes,9,opt,name=cache_dir,json=cacheDir,proto3" json:"cache_dir,omitempty"`
// nacos timeout(ms). default 5000
Timeout *durationpb.Duration `protobuf:"bytes,10,opt,name=timeout,proto3" json:"timeout,omitempty"`
// nacos logger level. default info
LogLevel string `protobuf:"bytes,11,opt,name=log_level,json=logLevel,proto3" json:"log_level,omitempty"`
// nacos format, default=yaml
Format string `protobuf:"bytes,12,opt,name=format,proto3" json:"format,omitempty"`
// contains filtered or unexported fields
}
nacos config
func (*Nacos) Descriptor
deprecated
func (*Nacos) GetAddress ¶
func (*Nacos) GetCacheDir ¶
func (*Nacos) GetContextPath ¶ added in v1.0.15
func (*Nacos) GetLogLevel ¶
func (*Nacos) GetNamespace ¶ added in v1.0.16
func (*Nacos) GetPassword ¶
func (*Nacos) GetTimeout ¶
func (x *Nacos) GetTimeout() *durationpb.Duration
func (*Nacos) GetUsername ¶
func (*Nacos) ProtoMessage ¶
func (*Nacos) ProtoMessage()
func (*Nacos) ProtoReflect ¶
func (x *Nacos) ProtoReflect() protoreflect.Message
type Next ¶
type Next struct {
// service id
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
// service name
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
// service version
Version string `protobuf:"bytes,3,opt,name=version,proto3" json:"version,omitempty"`
// service metadata
Metadata map[string]string `` /* 157-byte string literal not displayed */
// registry config
Registry *Registry `protobuf:"bytes,5,opt,name=registry,proto3" json:"registry,omitempty"`
// server config
Server *Server `protobuf:"bytes,6,opt,name=server,proto3" json:"server,omitempty"`
// logger config
Logger *Logger `protobuf:"bytes,10,opt,name=logger,proto3" json:"logger,omitempty"`
// telemetry config
Telemetry *Telemetry `protobuf:"bytes,11,opt,name=telemetry,proto3" json:"telemetry,omitempty"`
// nacos config
Nacos *Nacos `protobuf:"bytes,12,opt,name=nacos,proto3" json:"nacos,omitempty"`
// broker config
Broker *Broker `protobuf:"bytes,13,opt,name=broker,proto3" json:"broker,omitempty"`
// contains filtered or unexported fields
}
next micro global config
func (*Next) Descriptor
deprecated
func (*Next) GetMetadata ¶
func (*Next) GetRegistry ¶
func (*Next) GetTelemetry ¶ added in v1.0.5
func (*Next) GetVersion ¶
func (*Next) ProtoMessage ¶
func (*Next) ProtoMessage()
func (*Next) ProtoReflect ¶
func (x *Next) ProtoReflect() protoreflect.Message
type Publish ¶
type Publish struct {
// contains filtered or unexported fields
}
broker publish config
func (*Publish) Descriptor
deprecated
func (*Publish) ProtoMessage ¶
func (*Publish) ProtoMessage()
func (*Publish) ProtoReflect ¶
func (x *Publish) ProtoReflect() protoreflect.Message
type Registry ¶
type Registry struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // registry name, eg: nacos, etcd, consul
Addrs string `protobuf:"bytes,2,opt,name=addrs,proto3" json:"addrs,omitempty"` // registry address
Timeout *durationpb.Duration `protobuf:"bytes,3,opt,name=timeout,proto3" json:"timeout,omitempty"` // registry timeout
// contains filtered or unexported fields
}
Registry config
func (*Registry) Descriptor
deprecated
func (*Registry) GetTimeout ¶
func (x *Registry) GetTimeout() *durationpb.Duration
func (*Registry) ProtoMessage ¶
func (*Registry) ProtoMessage()
func (*Registry) ProtoReflect ¶
func (x *Registry) ProtoReflect() protoreflect.Message
type Server ¶
type Server struct {
Http *HTTPServer `protobuf:"bytes,1,opt,name=http,proto3" json:"http,omitempty"`
Grpc *GRPCServer `protobuf:"bytes,2,opt,name=grpc,proto3" json:"grpc,omitempty"`
// contains filtered or unexported fields
}
server config
func (*Server) Descriptor
deprecated
func (*Server) GetGrpc ¶
func (x *Server) GetGrpc() *GRPCServer
func (*Server) GetHttp ¶
func (x *Server) GetHttp() *HTTPServer
func (*Server) ProtoMessage ¶
func (*Server) ProtoMessage()
func (*Server) ProtoReflect ¶
func (x *Server) ProtoReflect() protoreflect.Message
type Subscribe ¶
type Subscribe struct {
Queue string `protobuf:"bytes,1,opt,name=queue,proto3" json:"queue,omitempty"` // queue name
AutoAck bool `protobuf:"varint,2,opt,name=auto_ack,json=autoAck,proto3" json:"auto_ack,omitempty"` // auto ack
// contains filtered or unexported fields
}
broker subscribe config
func (*Subscribe) Descriptor
deprecated
func (*Subscribe) GetAutoAck ¶
func (*Subscribe) ProtoMessage ¶
func (*Subscribe) ProtoMessage()
func (*Subscribe) ProtoReflect ¶
func (x *Subscribe) ProtoReflect() protoreflect.Message
type Telemetry ¶ added in v1.0.5
type Telemetry struct {
Disable bool `protobuf:"varint,1,opt,name=disable,proto3" json:"disable,omitempty"` // disable tracing
Exporter string `protobuf:"bytes,2,opt,name=exporter,proto3" json:"exporter,omitempty"` // tracing exporter, eg: otlphttp, otlpgrpc, stdout, zipkin, file, noop
Endpoint string `protobuf:"bytes,3,opt,name=endpoint,proto3" json:"endpoint,omitempty"` // tracing endpoint
Sampler float64 `protobuf:"fixed64,4,opt,name=sampler,proto3" json:"sampler,omitempty"` // tracing sampler: 0-1, 1 means full sampling, 0 means no sampling
Headers map[string]string `` // otlp headers
/* 155-byte string literal not displayed */
HttpPath string `protobuf:"bytes,6,opt,name=http_path,json=httpPath,proto3" json:"http_path,omitempty"` // otlp http path
// contains filtered or unexported fields
}
Telemetry config
func (*Telemetry) Descriptor
deprecated
added in
v1.0.5
func (*Telemetry) GetDisable ¶ added in v1.0.5
func (*Telemetry) GetEndpoint ¶ added in v1.0.5
func (*Telemetry) GetExporter ¶ added in v1.0.5
func (*Telemetry) GetHeaders ¶ added in v1.0.10
func (*Telemetry) GetHttpPath ¶ added in v1.0.10
func (*Telemetry) GetSampler ¶ added in v1.0.5
func (*Telemetry) ProtoMessage ¶ added in v1.0.5
func (*Telemetry) ProtoMessage()
func (*Telemetry) ProtoReflect ¶ added in v1.0.5
func (x *Telemetry) ProtoReflect() protoreflect.Message
Click to show internal directories.
Click to hide internal directories.