Documentation ¶
Overview ¶
package naming is interface for both registry register/unregister and grpc builder/resolver
Index ¶
Constants ¶
View Source
const ( // PREFIX uses here to differentiate between denny etcd prefix and other service prefix // in etcd directory/files Prefix = "_DENNY_" )
Variables ¶
This section is empty.
Functions ¶
func DefaultBalancePolicy ¶ added in v1.0.2
func DefaultBalancePolicy() grpc.DialOption
DefaultBalancePolicy returns default grpc service config which required by new grpc API so client does not have to supply json config everytime
Types ¶
type Registry ¶
type Registry interface { Register(addr string, ttl int) error UnRegister(addr string) error Build(target resolver.Target, cc resolver.ClientConn, opts resolver.BuildOptions) (resolver.Resolver, error) Scheme() string SvcName() string }
Registry is based interface, which is composed of grpc resolver.Builder, resolver.Resolver and also contains method to register and unregister from naming storage
Click to show internal directories.
Click to hide internal directories.