Documentation ¶
Index ¶
- Constants
- Variables
- func New(c *Conf) (kreg.Registrar, kreg.Discovery)
- type Conf
- func (*Conf) Descriptor() ([]byte, []int)deprecated
- func (x *Conf) GetConsul() *Consul
- func (x *Conf) GetEtcd() *Etcd
- func (x *Conf) GetKube() *Kube
- func (*Conf) ProtoMessage()
- func (x *Conf) ProtoReflect() protoreflect.Message
- func (x *Conf) Reset()
- func (x *Conf) String() string
- func (m *Conf) Validate() error
- type ConfValidationError
- type Consul
- func (*Consul) Descriptor() ([]byte, []int)deprecated
- func (x *Consul) GetAddress() string
- func (x *Consul) GetDialTimeout() *durationpb.Duration
- func (x *Consul) GetEnable() bool
- func (*Consul) ProtoMessage()
- func (x *Consul) ProtoReflect() protoreflect.Message
- func (x *Consul) Reset()
- func (x *Consul) String() string
- func (m *Consul) Validate() error
- type ConsulValidationError
- type Etcd
- func (*Etcd) Descriptor() ([]byte, []int)deprecated
- func (x *Etcd) GetDialTimeout() *durationpb.Duration
- func (x *Etcd) GetEnable() bool
- func (x *Etcd) GetEndpoints() []string
- func (*Etcd) ProtoMessage()
- func (x *Etcd) ProtoReflect() protoreflect.Message
- func (x *Etcd) Reset()
- func (x *Etcd) String() string
- func (m *Etcd) Validate() error
- type EtcdValidationError
- type Kube
- type KubeValidationError
Constants ¶
const ( // MetaWeight meta region MetaRegion = "region" // MetaZone meta region MetaZone = "zone" // MetaHostname meta hostname MetaHostname = "hostname" // MetaWeight meta weight MetaWeight = "weight" // MetaOffline meta offline MetaOffline = "offline" // MetaAddrs meta public ip addrs MetaAddrs = "addrs" // MetaIPCount meta ip count MetaIPCount = "ip_count" // MetaConnCount meta conn count MetaConnCount = "conn_count" // PlatformWeb platform web PlatformWeb = "web" )
Variables ¶
var File_registry_conf_proto protoreflect.FileDescriptor
Functions ¶
Types ¶
type Conf ¶
type Conf struct { Etcd *Etcd `protobuf:"bytes,1,opt,name=etcd,proto3" json:"etcd,omitempty"` Consul *Consul `protobuf:"bytes,2,opt,name=consul,proto3" json:"consul,omitempty"` Kube *Kube `protobuf:"bytes,3,opt,name=kube,proto3" json:"kube,omitempty"` // contains filtered or unexported fields }
func (*Conf) Descriptor
deprecated
func (*Conf) ProtoMessage ¶
func (*Conf) ProtoMessage()
func (*Conf) ProtoReflect ¶
func (x *Conf) ProtoReflect() protoreflect.Message
type ConfValidationError ¶
type ConfValidationError struct {
// contains filtered or unexported fields
}
ConfValidationError is the validation error returned by Conf.Validate if the designated constraints aren't met.
func (ConfValidationError) Cause ¶
func (e ConfValidationError) Cause() error
Cause function returns cause value.
func (ConfValidationError) Error ¶
func (e ConfValidationError) Error() string
Error satisfies the builtin error interface
func (ConfValidationError) ErrorName ¶
func (e ConfValidationError) ErrorName() string
ErrorName returns error name.
func (ConfValidationError) Field ¶
func (e ConfValidationError) Field() string
Field function returns field value.
func (ConfValidationError) Key ¶
func (e ConfValidationError) Key() bool
Key function returns key value.
func (ConfValidationError) Reason ¶
func (e ConfValidationError) Reason() string
Reason function returns reason value.
type Consul ¶
type Consul struct { Enable bool `protobuf:"varint,1,opt,name=enable,proto3" json:"enable,omitempty"` Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` DialTimeout *durationpb.Duration `protobuf:"bytes,3,opt,name=dialTimeout,proto3" json:"dialTimeout,omitempty"` // contains filtered or unexported fields }
func (*Consul) Descriptor
deprecated
func (*Consul) GetAddress ¶
func (*Consul) GetDialTimeout ¶
func (x *Consul) GetDialTimeout() *durationpb.Duration
func (*Consul) ProtoMessage ¶
func (*Consul) ProtoMessage()
func (*Consul) ProtoReflect ¶
func (x *Consul) ProtoReflect() protoreflect.Message
type ConsulValidationError ¶
type ConsulValidationError struct {
// contains filtered or unexported fields
}
ConsulValidationError is the validation error returned by Consul.Validate if the designated constraints aren't met.
func (ConsulValidationError) Cause ¶
func (e ConsulValidationError) Cause() error
Cause function returns cause value.
func (ConsulValidationError) Error ¶
func (e ConsulValidationError) Error() string
Error satisfies the builtin error interface
func (ConsulValidationError) ErrorName ¶
func (e ConsulValidationError) ErrorName() string
ErrorName returns error name.
func (ConsulValidationError) Field ¶
func (e ConsulValidationError) Field() string
Field function returns field value.
func (ConsulValidationError) Key ¶
func (e ConsulValidationError) Key() bool
Key function returns key value.
func (ConsulValidationError) Reason ¶
func (e ConsulValidationError) Reason() string
Reason function returns reason value.
type Etcd ¶
type Etcd struct { Enable bool `protobuf:"varint,1,opt,name=enable,proto3" json:"enable,omitempty"` Endpoints []string `protobuf:"bytes,2,rep,name=endpoints,proto3" json:"endpoints,omitempty"` DialTimeout *durationpb.Duration `protobuf:"bytes,3,opt,name=dialTimeout,proto3" json:"dialTimeout,omitempty"` // contains filtered or unexported fields }
func (*Etcd) Descriptor
deprecated
func (*Etcd) GetDialTimeout ¶
func (x *Etcd) GetDialTimeout() *durationpb.Duration
func (*Etcd) GetEndpoints ¶
func (*Etcd) ProtoMessage ¶
func (*Etcd) ProtoMessage()
func (*Etcd) ProtoReflect ¶
func (x *Etcd) ProtoReflect() protoreflect.Message
type EtcdValidationError ¶
type EtcdValidationError struct {
// contains filtered or unexported fields
}
EtcdValidationError is the validation error returned by Etcd.Validate if the designated constraints aren't met.
func (EtcdValidationError) Cause ¶
func (e EtcdValidationError) Cause() error
Cause function returns cause value.
func (EtcdValidationError) Error ¶
func (e EtcdValidationError) Error() string
Error satisfies the builtin error interface
func (EtcdValidationError) ErrorName ¶
func (e EtcdValidationError) ErrorName() string
ErrorName returns error name.
func (EtcdValidationError) Field ¶
func (e EtcdValidationError) Field() string
Field function returns field value.
func (EtcdValidationError) Key ¶
func (e EtcdValidationError) Key() bool
Key function returns key value.
func (EtcdValidationError) Reason ¶
func (e EtcdValidationError) Reason() string
Reason function returns reason value.
type Kube ¶ added in v0.0.2
type Kube struct { Enable bool `protobuf:"varint,1,opt,name=enable,proto3" json:"enable,omitempty"` // contains filtered or unexported fields }
func (*Kube) Descriptor
deprecated
added in
v0.0.2
func (*Kube) ProtoMessage ¶ added in v0.0.2
func (*Kube) ProtoMessage()
func (*Kube) ProtoReflect ¶ added in v0.0.2
func (x *Kube) ProtoReflect() protoreflect.Message
type KubeValidationError ¶ added in v0.0.2
type KubeValidationError struct {
// contains filtered or unexported fields
}
KubeValidationError is the validation error returned by Kube.Validate if the designated constraints aren't met.
func (KubeValidationError) Cause ¶ added in v0.0.2
func (e KubeValidationError) Cause() error
Cause function returns cause value.
func (KubeValidationError) Error ¶ added in v0.0.2
func (e KubeValidationError) Error() string
Error satisfies the builtin error interface
func (KubeValidationError) ErrorName ¶ added in v0.0.2
func (e KubeValidationError) ErrorName() string
ErrorName returns error name.
func (KubeValidationError) Field ¶ added in v0.0.2
func (e KubeValidationError) Field() string
Field function returns field value.
func (KubeValidationError) Key ¶ added in v0.0.2
func (e KubeValidationError) Key() bool
Key function returns key value.
func (KubeValidationError) Reason ¶ added in v0.0.2
func (e KubeValidationError) Reason() string
Reason function returns reason value.