Skip to content

Commit

Permalink
version bump, changelog and docs
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickkunka committed Jun 26, 2020
1 parent 838543f commit 9f65373
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# 1.1.1
- Fixes an issue where the throttle ended early with incomplete throughput, if the incoming data rate slows such that the outgoing data must wait.

# 1.1.0
- Fixes issues when passing requests through an unbounded throttle (`bytesPerSecond` = `Infinity`).
- Adds public `onThroughputMetrics` metrics callback to the `BandwidthThrottleGroup`.
Expand Down
6 changes: 4 additions & 2 deletions lib/BandwidthThrottle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,10 @@ class BandwidthThrottle extends BaseTransformStream {
}
}

// if data is still being written and processed, or there is no pending data but we are
// unthrottled, stop here
// Do not complete if:
// - additional data is available to be processed,
// - or, no additional data is available, but not all data has been written yet
// - or, we are unthrottled

if (
this.pendingBytesReadIndex < this.pendingBytesCount ||
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "bandwidth-throttle-stream",
"version": "1.1.0",
"version": "1.1.1",
"description": "A Node.js and Deno transform stream for throttling bandwidth",
"author": "KunkaLabs Limited",
"private": false,
Expand Down

0 comments on commit 9f65373

Please sign in to comment.