Comparing version 8.1.0 to 8.1.1
@@ -76,6 +76,2 @@ /*eslint-env node */ | ||
coveralls: { | ||
command: 'cat coverage/lcov.info | coveralls' | ||
}, | ||
nw_build: { | ||
@@ -153,3 +149,2 @@ command: [ | ||
]); | ||
grunt.registerTask('coveralls', 'shell:coveralls'); | ||
grunt.registerTask('default', ['lint', 'test']); | ||
@@ -156,0 +151,0 @@ |
/** | ||
# bpmux [![Build Status](https://travis-ci.org/davedoesdev/bpmux.png)](https://travis-ci.org/davedoesdev/bpmux) [![Coverage Status](https://coveralls.io/repos/davedoesdev/bpmux/badge.png?branch=master&service=github)](https://coveralls.io/r/davedoesdev/bpmux?branch=master) [![NPM version](https://badge.fury.io/js/bpmux.png)](http://badge.fury.io/js/bpmux) | ||
# bpmux [![Build Status](https://github.com/davedoesdev/bpmux/workflows/ci/badge.svg)](https://github.com/davedoesdev/bpmux/actions) [![Coverage Status](https://coveralls.io/repos/davedoesdev/bpmux/badge.png?branch=master&service=github)](https://coveralls.io/r/davedoesdev/bpmux?branch=master) [![NPM version](https://badge.fury.io/js/bpmux.png)](http://badge.fury.io/js/bpmux) | ||
@@ -8,3 +8,3 @@ Node stream multiplexing with back-pressure on each stream. | ||
- Exerts back-pressure on each multiplexed stream and the underlying carrier stream. | ||
- Each multiplexed stream's back-pressure is handled separately while respecting the carrier's capacity. [This prevents a slow or paused stream affecting other streams](#comparison). | ||
- Each multiplexed stream's back-pressure is handled separately while respecting the carrier's capacity. [This prevents a slow or paused stream affecting other streams](#comparison). This does incur an overhead so if you don't care about this feature you might want to look elsewhere. | ||
- Unit tests with 100% coverage. | ||
@@ -16,3 +16,3 @@ - Tested with TCP streams. You'll get better performance if you [disable Nagle](https://nodejs.org/dist/latest-v10.x/docs/api/net.html#net_socket_setnodelay_nodelay). | ||
- Browser unit tests using [webpack](http://webpack.github.io/) and [nwjs](http://nwjs.io/). | ||
- **See the [errors](#errors) section for information on why multiplexed streams error when their carrier streams closes before they do.** | ||
- **See the [errors](#errors) section for information on why multiplexed streams error when their carrier stream closes before they do.** | ||
@@ -643,3 +643,3 @@ The API is described [here](#api). | ||
if ((EventEmitter.listenerCount(duplex, 'error') > 0) && | ||
!(duplex._finished && duplex._ended) && | ||
!(duplex._ended && duplex._finished) && | ||
!duplex.destroyed) | ||
@@ -646,0 +646,0 @@ { |
{ | ||
"name": "bpmux", | ||
"description": "Node stream multiplexing with back-pressure on each stream", | ||
"version": "8.1.0", | ||
"version": "8.1.1", | ||
"homepage": "https://github.com/davedoesdev/bpmux", | ||
@@ -22,5 +22,5 @@ "author": { | ||
"test": "grunt lint test-fast", | ||
"travis-test-coverage": "grunt lint coverage coveralls", | ||
"travis-test-browser": "grunt test-browser", | ||
"travis-test-inline": "grunt test-inline" | ||
"ci-coverage": "grunt lint coverage", | ||
"ci-browser": "grunt test-browser", | ||
"ci-inline": "grunt test-inline" | ||
}, | ||
@@ -49,25 +49,24 @@ "directories": { | ||
"devDependencies": { | ||
"async": "^3.1.0", | ||
"async": "^3.2.0", | ||
"chai": "^4.2.0", | ||
"coveralls": "^3.0.9", | ||
"eslint": "^6.8.0", | ||
"eslint": "^7.4.0", | ||
"finalhandler": "^1.1.2", | ||
"grunt": "^1.0.4", | ||
"grunt-apidox": "^2.0.7", | ||
"grunt": "^1.2.1", | ||
"grunt-apidox": "^2.0.8", | ||
"grunt-env": "^1.0.1", | ||
"grunt-eslint": "^22.0.0", | ||
"grunt-eslint": "^23.0.0", | ||
"grunt-mocha-test": "^0.13.3", | ||
"grunt-shell": "^3.0.1", | ||
"http2-duplex": "^4.4.4", | ||
"mocha": "^7.0.0", | ||
"mocha": "^8.0.1", | ||
"nw-builder": "^3.5.7", | ||
"nyc": "^15.0.0", | ||
"primus": "^7.3.4", | ||
"nyc": "^15.1.0", | ||
"primus": "^7.3.5", | ||
"primus-backpressure": "^2.0.0", | ||
"serve-static": "^1.14.1", | ||
"tmp": "^0.1.0", | ||
"webpack": "^4.41.5", | ||
"webpack-cli": "^3.3.10", | ||
"ws": "^7.2.1" | ||
"tmp": "^0.2.1", | ||
"webpack": "^4.43.0", | ||
"webpack-cli": "^3.3.12", | ||
"ws": "^7.3.1" | ||
} | ||
} |
@@ -1,2 +0,2 @@ | ||
# bpmux [![Build Status](https://travis-ci.org/davedoesdev/bpmux.png)](https://travis-ci.org/davedoesdev/bpmux) [![Coverage Status](https://coveralls.io/repos/davedoesdev/bpmux/badge.png?branch=master&service=github)](https://coveralls.io/r/davedoesdev/bpmux?branch=master) [![NPM version](https://badge.fury.io/js/bpmux.png)](http://badge.fury.io/js/bpmux) | ||
# bpmux [![Build Status](https://github.com/davedoesdev/bpmux/workflows/ci/badge.svg)](https://github.com/davedoesdev/bpmux/actions) [![Coverage Status](https://coveralls.io/repos/davedoesdev/bpmux/badge.png?branch=master&service=github)](https://coveralls.io/r/davedoesdev/bpmux?branch=master) [![NPM version](https://badge.fury.io/js/bpmux.png)](http://badge.fury.io/js/bpmux) | ||
@@ -7,3 +7,3 @@ Node stream multiplexing with back-pressure on each stream. | ||
- Exerts back-pressure on each multiplexed stream and the underlying carrier stream. | ||
- Each multiplexed stream's back-pressure is handled separately while respecting the carrier's capacity. [This prevents a slow or paused stream affecting other streams](#comparison). | ||
- Each multiplexed stream's back-pressure is handled separately while respecting the carrier's capacity. [This prevents a slow or paused stream affecting other streams](#comparison). This does incur an overhead so if you don't care about this feature you might want to look elsewhere. | ||
- Unit tests with 100% coverage. | ||
@@ -15,3 +15,3 @@ - Tested with TCP streams. You'll get better performance if you [disable Nagle](https://nodejs.org/dist/latest-v10.x/docs/api/net.html#net_socket_setnodelay_nodelay). | ||
- Browser unit tests using [webpack](http://webpack.github.io/) and [nwjs](http://nwjs.io/). | ||
- **See the [errors](#errors) section for information on why multiplexed streams error when their carrier streams closes before they do.** | ||
- **See the [errors](#errors) section for information on why multiplexed streams error when their carrier stream closes before they do.** | ||
@@ -18,0 +18,0 @@ The API is described [here](#api). |
@@ -113,4 +113,14 @@ /*eslint-env node */ | ||
{ | ||
conn.on('end', cb); | ||
conn.end(); | ||
var called = false; | ||
function cb2() | ||
{ | ||
if (!called) | ||
{ | ||
called = true; | ||
cb(); | ||
} | ||
} | ||
conn.on('end', cb2); | ||
conn.on('close', cb2); | ||
conn.close(); | ||
}, | ||
@@ -117,0 +127,0 @@ Buffer, |
@@ -18,6 +18,2 @@ /*eslint-env node */ | ||
this.left = left; | ||
this.on('finish', function () | ||
{ | ||
left.push(null); | ||
}); | ||
} | ||
@@ -27,2 +23,8 @@ | ||
RightDuplex.prototype._final = function (cb) | ||
{ | ||
this.left.push(null); | ||
cb(); | ||
}; | ||
RightDuplex.prototype._read = function () | ||
@@ -54,6 +56,2 @@ { | ||
this.right = new RightDuplex(this); | ||
this.on('finish', function () | ||
{ | ||
this.right.push(null); | ||
}.bind(this)); | ||
} | ||
@@ -63,2 +61,8 @@ | ||
LeftDuplex.prototype._final = function (cb) | ||
{ | ||
this.right.push(null); | ||
cb(); | ||
}; | ||
LeftDuplex.prototype._read = function () | ||
@@ -65,0 +69,0 @@ { |
@@ -53,3 +53,3 @@ /*eslint-env node, mocha */ | ||
{ | ||
conn.on('end', cb); | ||
conn.on('close', cb); | ||
conn.end(); | ||
@@ -56,0 +56,0 @@ }, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
539046
21
5171