Documentation ¶
Overview ¶
Package http provides a http client
Index ¶
- Variables
- func AuthTLS(t *tls.Config) client.Option
- func ErrorMap(m map[string]interface{}) client.CallOption
- func HTTPClient(c *http.Client) client.Option
- func HTTPDialer(d *net.Dialer) client.Option
- func MaxRecvMsgSize(s int) client.Option
- func MaxSendMsgSize(s int) client.Option
- func Method(m string) client.CallOption
- func NewClient(opts ...client.Option) client.Client
- func Path(p string) client.CallOption
- func PoolMaxIdle(d int) client.Option
- func PoolMaxStreams(n int) client.Option
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // DefaultPoolMaxStreams maximum streams on a connectioin // (20) DefaultPoolMaxStreams = 20 // DefaultPoolMaxIdle maximum idle conns of a pool // (50) DefaultPoolMaxIdle = 50 // DefaultMaxRecvMsgSize maximum message that client can receive // (4 MB). DefaultMaxRecvMsgSize = 1024 * 1024 * 4 // DefaultMaxSendMsgSize maximum message that client can send // (4 MB). DefaultMaxSendMsgSize = 1024 * 1024 * 4 )
Functions ¶
func ErrorMap ¶
func ErrorMap(m map[string]interface{}) client.CallOption
func MaxRecvMsgSize ¶
MaxRecvMsgSize set the maximum size of message that client can receive.
func MaxSendMsgSize ¶
MaxSendMsgSize set the maximum size of message that client can send.
func Method ¶
func Method(m string) client.CallOption
func Path ¶
func Path(p string) client.CallOption
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.