Documentation ¶
Overview ¶
Package scheduled 定时服务包
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckService ¶
func CheckService(serviceID, serviceName, component string)
CheckService 检查可用负载服务列表
func ConsulEnroll ¶
ConsulEnroll 定时调用此方法检查注册 consul 是否失效
consulUrl:consul 注册地址,包括端口号(优先通过环境变量 CONSUL_URL 获取)
serviceID:注册到 consul 的服务 ID
serviceName:注册到 consul 的服务名称(优先通过环境变量 SERVICE_NAME 获取)
hostname:注册到 consul 的服务地址(如果为空,则尝试通过 /etc/hostname 获取)
port:注册到 consul 的服务端口(优先通过环境变量 PORT 获取)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.