mirror of
https://github.com/go-micro/go-micro.git
synced 2025-05-31 21:59:42 +02:00
fix bugs
This commit is contained in:
parent
3676232df1
commit
db0fa9fe1f
@ -34,7 +34,6 @@ type Options struct {
|
|||||||
Config *config.Config
|
Config *config.Config
|
||||||
Client *client.Client
|
Client *client.Client
|
||||||
Server *server.Server
|
Server *server.Server
|
||||||
Runtime *runtime.Runtime
|
|
||||||
Caches map[string]func(...cache.Option) cache.Cache
|
Caches map[string]func(...cache.Option) cache.Cache
|
||||||
Tracer *trace.Tracer
|
Tracer *trace.Tracer
|
||||||
Profiles map[string]func(...profile.Option) profile.Profile
|
Profiles map[string]func(...profile.Option) profile.Profile
|
||||||
@ -49,7 +48,6 @@ type Options struct {
|
|||||||
Selectors map[string]func(...selector.Option) selector.Selector
|
Selectors map[string]func(...selector.Option) selector.Selector
|
||||||
Servers map[string]func(...server.Option) server.Server
|
Servers map[string]func(...server.Option) server.Server
|
||||||
Transports map[string]func(...transport.Option) transport.Transport
|
Transports map[string]func(...transport.Option) transport.Transport
|
||||||
Runtimes map[string]func(...runtime.Option) runtime.Runtime
|
|
||||||
Stores map[string]func(...store.Option) store.Store
|
Stores map[string]func(...store.Option) store.Store
|
||||||
Tracers map[string]func(...trace.Option) trace.Tracer
|
Tracers map[string]func(...trace.Option) trace.Tracer
|
||||||
Version string
|
Version string
|
||||||
@ -110,12 +108,6 @@ func Registry(r *registry.Registry) Option {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func Runtime(r *runtime.Runtime) Option {
|
|
||||||
return func(o *Options) {
|
|
||||||
o.Runtime = r
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func Transport(t *transport.Transport) Option {
|
func Transport(t *transport.Transport) Option {
|
||||||
return func(o *Options) {
|
return func(o *Options) {
|
||||||
o.Transport = t
|
o.Transport = t
|
||||||
@ -207,13 +199,6 @@ func NewTransport(name string, t func(...transport.Option) transport.Transport)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// New runtime func.
|
|
||||||
func NewRuntime(name string, r func(...runtime.Option) runtime.Runtime) Option {
|
|
||||||
return func(o *Options) {
|
|
||||||
o.Runtimes[name] = r
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// New tracer func.
|
// New tracer func.
|
||||||
func NewTracer(name string, t func(...trace.Option) trace.Tracer) Option {
|
func NewTracer(name string, t func(...trace.Option) trace.Tracer) Option {
|
||||||
return func(o *Options) {
|
return func(o *Options) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user