commit | df18e7a279a201269990b18e4c3807fe56db56b8 | [log] [tgz] |
---|---|---|
author | Kevin Moore <kevmoo@google.com> | Wed Aug 02 17:38:27 2017 |
committer | Kevin Moore <kevmoo@google.com> | Wed Aug 02 17:39:56 2017 |
tree | 7311125fc1ead75faa6a23182d240ff189ed33b0 | |
parent | 1dd6b928d065b25b2c67f04cd04b69cd428f5bbd [diff] |
Add travis support
http_throttle
is middleware for the http package that throttles the number of concurrent requests that an HTTP client can make.
// This client allows 32 concurrent requests. final client = new ThrottleClient(32); Future<List<String>> readAllUrls(Iterable<Uri> urls) { return Future.wait(urls.map((url) { // You can safely call as many client methods as you want concurrently, and // ThrottleClient will ensure that only 32 underlying HTTP requests will be // open at once. return client.read(url); })); }