webmetrics/browsermob-proxy — pull request #73 by lucabox (2012-10-29 18:21:40+00:00)
Title: Integrated the new BandwidthLimiter and relative APIs - fixes #72

from https://github.com/lucabox/Java-BandwidthLimiter

The new bandwidth limiter (its implementation is StreamManager) can throttle to the aggregate speed of all requests passing through the proxy.

Note
------

- fixed old behaviour that was applying the limit per socket rather per aggregate traffic passing though the proxy

- deprecated some setDownstreamKbps/setUpstreamKbps/setLatency form the ProxyServer, it makes more sense to get the stream manager and call those apis directly on that object. Left deprecated APIs in place but might be worth removing them in a couple of releases.

- bandwidth throttling is disabled by default, any call to setDownstreamKbps/setUpstreamKbps/setLatency will implicitly set enable the throttling. An user can explicitly enable/disable the stream manager via the "enable" request parameter if using the standalone proxy or call streamManager.enable() is embedding browsermob's code in own project.