Brian Waldon
bac1d2f420
client: unexport httpClient interface
2015-02-28 10:22:51 -08:00
Brian Waldon
52288fa748
client: remove CancelableTransport arg from httpClientFactory
2015-02-28 10:22:51 -08:00
Brian Waldon
2aecbaf165
client: unexport httpAction
2015-02-28 10:22:51 -08:00
Brian Waldon
3f5e827e3c
client: httpClient -> simpleHTTPClient
2015-02-28 10:22:51 -08:00
Brian Waldon
62054dfb5e
client: don't cache httpClients in httpClusterClient
2015-02-28 10:22:50 -08:00
Jonathan Boulle
f1ed69e883
*: switch to line comments for copyright
...
Build tags are not compatible with block comments.
Also adds copyright header to a few places it was missing.
2015-01-26 09:53:30 -08:00
Brian Waldon
9a728a127a
dep: bump golang.org/x/net/context
...
Move from code.google.com/p/go.net/context to
golang.org/x/net/context before bumping to latest.
2014-11-20 10:19:12 -08:00
Brian Waldon
4b555dba99
client: add SyncableHTTPClient.Endpoints
2014-11-06 10:54:56 -08:00
Jonathan Boulle
45b7c9a4ac
client: return ErrNoEndpoint when none available
...
In certain cases (for example, if a cluster peer is accessible but it
has no members listed), the httpClusterClient could have an empty set of
endpoints as a result of the Sync. This means that its Do function could
potentially return a nil response and nil error, with catastrophic
consequences for callers.
To be safe (particularly about this latter behaviour), this change
errors in both Sync and Do if no endpoints are available.
2014-11-04 12:51:43 -08:00
Brian Waldon
6dd4944e62
client: follow redirects
2014-11-03 12:15:16 -08:00
Brian Waldon
da6827f09e
client: use all endpoints
2014-10-31 20:51:47 -07:00
Brian Waldon
824049897d
client: export necessary interfaces/methods
2014-10-31 17:25:05 -07:00
Brian Waldon
d52d836761
client: return full http.Response in httpActionDo
2014-10-31 17:25:04 -07:00
Jonathan Boulle
97c23c4333
client: pass around statuscode instead of Response
...
There's no real need for do and doWithTimeout to return Responses when
the only field of interest is the status code.
This also removes the superfluous httpMembersAPIResponse struct.
2014-10-29 15:47:55 -07:00
Brian Waldon
ce4df96e69
client: break apart KeysAPI from httpClient
2014-10-24 13:27:59 -07:00
Brian Waldon
992e7c76e0
client: copy v2KeysPrefix to httpClient
...
It's poor form to muck with a global variable. Make a copy when the
httpClient object is instantiated to make httpClient.SetPrefix safe.
2014-10-23 16:31:45 -07:00
Brian Waldon
a85a47c8f9
client: s/v2URL/v2KeysURL/
2014-10-23 16:31:42 -07:00
Jonathan Boulle
b3d5333cb3
*: fix various formatting issues
2014-10-20 17:55:18 -07:00
Jonathan Boulle
7a4d42166b
*: add license header to all source files
2014-10-17 15:41:22 -07:00
Jonathan Boulle
4183b69e12
*: move from third_party to Godep
2014-10-14 00:37:52 -07:00
Brian Waldon
49cc76d33b
client: min client for discovery
2014-09-21 10:29:52 -07:00