naming

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 18, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config added in v0.0.6

type Config struct {
	Environment string
	Scheme      string //那种驱动类型,redis,etcd

	Org  string
	Host string //连接地址
	Auth string //认证
	Num  int    //库的数字
	Ttl  int64  //过期时间
}

type Registry

type Registry interface {
	Scheme() string

	Register(service Service) error
	Deregister(service Service) error
	//返回服务
	List(name string) []Service
}

type Resolver

type Resolver interface {
	resolver.Builder
}

type Service added in v0.0.6

type Service struct {
	Org     string `json:"org"`
	Name    string `json:"name"`
	Addr    string `json:"addr"`    // 服务地址
	Version string `json:"version"` // 服务版本
	Weight  int64  `json:"weight"`  // 服务权重
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL