Codebase list golang-github-go-kit-kit / d3b34e8
httptransport: use ctxhttp to propagate context Simon Jefford 8 years ago
1 changed file(s) with 2 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
55 "net/url"
66
77 "golang.org/x/net/context"
8 "golang.org/x/net/context/ctxhttp"
89
910 "github.com/go-kit/kit/endpoint"
1011 )
7071 ctx = f(ctx, req)
7172 }
7273
73 resp, err := c.client.Do(req)
74 resp, err := ctxhttp.Do(ctx, c.client, req)
7475 if err != nil {
7576 return nil, fmt.Errorf("Do: %v", err)
7677 }