Documentation
¶
Overview ¶
Package client provides context.Context-aware alternatives to the short-hand request functions http.Get, http.Head, http.Post, and http.PostForm. Using these functions allows for better control over the trace context propagation.
Index ¶
- func Get(ctx context.Context, url string) (resp *http.Response, err error)
- func Head(ctx context.Context, url string) (resp *http.Response, err error)
- func Post(ctx context.Context, url string, contentType string, body io.Reader) (resp *http.Response, err error)
- func PostForm(ctx context.Context, url string, data url.Values) (resp *http.Response, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Get ¶
Get is a context.Context aware version of http.Get.
func Head ¶
Head is a context.Context aware version of http.Head.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.