commit | 1dd6b928d065b25b2c67f04cd04b69cd428f5bbd | [log] [tgz] |
---|---|---|
author | Kevin Moore <kevmoo@google.com> | Wed Aug 02 10:37:30 2017 -0700 |
committer | Kevin Moore <kevmoo@google.com> | Wed Aug 02 10:39:56 2017 -0700 |
tree | 209a833d50fbb2c2f5a04c490f78ebebd6df1d75 | |
parent | 8efe929fed3a39e45052caaa7f3cccf433ffa525 [diff] |
Add analysis_options
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); })); }