// NewLBRegistry creates a new LBRegistry from the provided etcd Client. func NewLBRegistry(key string, ttl uint64) (*LBRegistry, error) { client := vulcan.NewClient(key) return &LBRegistry{ Key: key, TTL: ttl, client: client, }, nil }
// NewLeaderRegistry creates a new LeaderRegistry from the provided etcd Client. func NewLeaderRegistry(key string, group string, ttl uint64) *LeaderRegistry { client := vulcan.NewClient(key) return &LeaderRegistry{ Key: key, Group: group, TTL: ttl, client: client, IsMaster: false, } }