Documentation ¶
Overview ¶
*
- by huqiuyun
- 启动一个服务时,注册到consul中心,从而可以收到配置信息的变化通知
Index ¶
- func NewClientWithPoints(eps config.EndPoints) (*consul.Client, error)
- func NewConsulClient(conf config.Config, endPoints config.EndPoints, resol resolver.Resolver) (service.Client, error)
- func NewService(cfg config.Config, points config.EndPoints, registry registry.Registry) (service.Service, error)
- type Base
- type Watcher
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewClientWithPoints ¶ added in v1.1.9
func NewConsulClient ¶
Types ¶
type Base ¶
type Base struct {
// contains filtered or unexported fields
}
func (*Base) AttachWatcher ¶ added in v0.4.6
type Watcher ¶ added in v0.4.6
type Watcher struct {
// contains filtered or unexported fields
}
func NewWatcher ¶ added in v0.4.6
func (*Watcher) Changed ¶ added in v0.4.6
func (watcher *Watcher) Changed(cmd discoveryWatch.Changed)
func (*Watcher) Watch ¶ added in v0.4.6
func (watcher *Watcher) Watch(key discoveryWatch.Key) (discoveryWatch.Chan, error)
Click to show internal directories.
Click to hide internal directories.