Commit Graph

22 Commits

Author SHA1 Message Date
Derrick J. Wippler
76b3cd49b6 Reverted change to associate Transport to httpGetter.
This change caused a data race during async calls to groupcache.Get().
Also discovered `DefaultTransport` has per address connection pooling
only when the request was a success, which is sufficient for most use
cases.
2019-06-04 14:53:24 -05:00
Derrick J. Wippler
2869a0ce28 HTTPPoolOptions.Transport is now used instead of DefaultTransport when provided 2019-06-04 10:02:19 -05:00
Derrick J. Wippler
8b0de5a71a Changed module paths to reflect breaking change v2 2019-06-03 11:08:54 -05:00
Derrick J. Wippler
054f2178b4 Client keep-alives and hotcache changes
* Now Associating the transport with peer `httpGetter` so we take advantage of
  connection reuse.  This lowers the impact on DNS and improves preformance for
  high request volume low latency applications.
* Now always populating the hotcache. A more complex algorithm is unnecessary
  when the LRU cache will ensure the most used values remain in the cache. The
  evict code ensures the hotcache does not over crowd the maincache.
2019-06-03 10:20:40 -05:00
Derrick J. Wippler
f352930de5 Now using context.Context instead of groupcache.Context 2019-05-30 17:03:06 -05:00
Derrick J. Wippler
a5eee224aa http requests now respect context.Context done 2019-05-30 16:47:38 -05:00
Derrick J. Wippler
2e501aa922 Remove() Now returns the body on non 200 response 2019-05-23 15:09:56 -05:00
Derrick J. Wippler
4f7e5ecf8c Added support for key removal within a group 2019-04-11 10:50:29 -05:00
Derrick J. Wippler
a4f69dc48c Changed import path to mailgun/groupcache 2019-04-10 15:09:20 -05:00
Derrick J. Wippler
ce8fe99325 Sinks can not accept an expire time 2019-04-09 17:36:03 -05:00
Steve Phillips
361310ca19 http.go: Added missing word from NewHTTPPool docs 2017-01-09 12:49:55 -08:00
Pierre Durand
8cc54b43f8 use passed options 2016-02-08 09:57:03 +01:00
Ryan Slade
505a8b21f5 Reduce allocations
Store temporary buffers in a sync.Pool.

Create one httpGetter per peer when Set() is called so we don't
allocate a new one on each call PickPeer().
2014-12-16 08:18:07 +00:00
Fumitoshi Ukai
5fb127ef79 goprotobuf has moved to GitHub
code.google.com/p/goprotobuf to github.com/golang/groupcache
2014-11-25 13:24:33 +09:00
awaw fumin
1568598a4f allow all options of HTTPPool to be specified by users 2014-10-20 14:40:48 +08:00
Dvir Volk
21fc61ac51 changed default number of replicas in http pool hash ring to 50, and fixed hash ring benchmark 2014-07-08 12:15:05 +03:00
Dvir Volk
976d66a1f1 removed extra unesacping in http pool that screwed up the keys we were using 2014-06-18 23:00:46 +03:00
Dan Pupius
bdcbf83d9e HTTPPool increments Group.Stats.ServerRequests 2013-10-16 10:57:19 -07:00
Dan Pupius
a06134f0da PeerPicker uses ring hash to pick peers 2013-10-01 19:10:50 -07:00
Fumitoshi Ukai
38eed8b4ba Close body even if it got error http status.
Otherwise, http connections keep open if server
returned error status (e.g. Get returned error).
2013-08-29 22:00:01 +09:00
Andrew Gerrand
3f89d3eb33 fix overflow in peer selection 2013-08-12 12:08:11 +10:00
Andrew Gerrand
0bfcb13dbb add HTTP pool implementation 2013-07-24 14:57:40 +10:00