m-lab / go

General purpose libraries / APIs for use in mlab code.
Apache License 2.0
5 stars 6 forks source link

Change httpProvider.Get to let the caller define a timeout #130

Open robertodauria opened 3 years ago

robertodauria commented 3 years ago

Currently there are several possible implementations of a content.Provider, depending on the scheme used in the URL passed to FromURL. These implementations differ in how they use the passed-in context.

httpProvider.Get(ctx) should use the passed-in context to allow the caller to define a timeout, rather than adding its own (unconfigurable) one.