Documentation ¶
Index ¶
- func NewRegistry(ops ...register.Option) register.Register
- type EtcdV3
- func (p *EtcdV3) Build(target resolver.Target, cc resolver.ClientConn, opts resolver.BuildOption) (resolver.Resolver, error)
- func (p *EtcdV3) Close()
- func (p *EtcdV3) GetBuilder() resolver.Builder
- func (p *EtcdV3) GetResolver() resolver.Resolver
- func (p *EtcdV3) Register(n *register.Node) error
- func (p *EtcdV3) ResolveNow(rn resolver.ResolveNowOption)
- func (p *EtcdV3) Scheme() string
- func (p *EtcdV3) UnRegister(n *register.Node) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type EtcdV3 ¶
type EtcdV3 struct { Options *register.Options // 注册服务配置 // contains filtered or unexported fields }
EtcdV3 注册服务到etcd v3 api的服务注册中间件
func (*EtcdV3) Build ¶
func (p *EtcdV3) Build(target resolver.Target, cc resolver.ClientConn, opts resolver.BuildOption) (resolver.Resolver, error)
Build grpc resolver接口需要 - 创建一个服务注册中心中间件
func (*EtcdV3) GetBuilder ¶
GetBuilder 获取grpc服务注册Builder对象
func (*EtcdV3) GetResolver ¶
GetResolver 获取客户端发现 grpc Resolver对象
func (*EtcdV3) ResolveNow ¶
func (p *EtcdV3) ResolveNow(rn resolver.ResolveNowOption)
ResolveNow 什么也不做
Click to show internal directories.
Click to hide internal directories.