Documentation ¶
Index ¶
- Constants
- func DestroyService(serviceName, HostName string) error
- func GetModVal(modVal uint64) uint64
- func GetServerWithName(serviceName string) string
- func InitEtcd(rootPrefix string, endpoints, key, cert, ca string, events ...WatchEvent)
- func KvGet(key string) string
- func KvPut(key string, val string) error
- func NewEtcdClient() *etcdClient
- func RegisterServerName(serviceName, HostName string, serviceAddr string) error
- type WatchEvent
Constants ¶
View Source
const (
CONFIG_PREFIX = "config"
)
View Source
const (
SERVICE_PREFIX = "naming"
)
Variables ¶
This section is empty.
Functions ¶
func DestroyService ¶
func GetServerWithName ¶
func InitEtcd ¶
func InitEtcd(rootPrefix string, endpoints, key, cert, ca string, events ...WatchEvent)
func NewEtcdClient ¶
func NewEtcdClient() *etcdClient
func RegisterServerName ¶
Types ¶
type WatchEvent ¶
type WatchEvent func(rootPrefix string, event mvccpb.Event_EventType, key, val string)
func ConfigEvent ¶
func ConfigEvent() WatchEvent
func ServiceEvent ¶
func ServiceEvent() WatchEvent
Click to show internal directories.
Click to hide internal directories.