agent.getName([options])
获取一组请求选项的唯一名称,以确定是否可以重用连接。
对于 HTTP 代理,则这将返回 host:port:localAddress
或 host:port:localAddress:family
。
对于 HTTPS 代理,则名称包括 CA、证书、密码和其他确定套接字可重用性的 HTTPS/TLS 特定选项。
Get a unique name for a set of request options, to determine whether a
connection can be reused. For an HTTP agent, this returns
host:port:localAddress
or host:port:localAddress:family
. For an HTTPS agent,
the name includes the CA, cert, ciphers, and other HTTPS/TLS-specific options
that determine socket reusability.