Documentation
¶
Index ¶
Constants ¶
View Source
const Type = "http"
Variables ¶
This section is empty.
Functions ¶
func BuildClientConfigIndex ¶
func BuildClientConfigIndex(dataCfg *conf.Data) map[string]*conf.Data_Client_HTTP
BuildClientConfigIndex 预构建 HTTP 客户端配置索引,避免热路径重复遍历配置列表。
Types ¶
type Connection ¶
type Connection struct {
// contains filtered or unexported fields
}
Connection HTTP 连接封装,实现 runtime.Connection。
func NewConnection ¶
func NewConnection(cli *stdhttp.Client, endpoint string) *Connection
func (*Connection) Close ¶
func (h *Connection) Close() error
func (*Connection) Endpoint ¶
func (h *Connection) Endpoint() string
Endpoint 返回 HTTP 连接基础地址,便于上层拼接路径。
func (*Connection) IsHealthy ¶
func (h *Connection) IsHealthy() bool
func (*Connection) Value ¶
func (h *Connection) Value() any
Click to show internal directories.
Click to hide internal directories.