★ wanayoo — archive 1999 https://github.com/nodejs/node/commit/fcca2f7e49Nouvelle recherche | Portail wanayoo
Skip to content
Permalink
Browse files

http2: remove `streamError` from docs

`streamError` was removed quite some time ago but the docs and
code comments weren't updated. Fix that.

Fixes: #20211

PR-URL: #22246
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jon Moss <me@jonathanmoss.me>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
  • Loading branch information...
jasnell authored and rvagg committed Aug 10, 2018
1 parent 1be6fb9 commit fcca2f7e49061c978354a4bb966126334f841f1f
Showing with 2 additions and 17 deletions.
  1. +0 −12 doc/api/http2.md
  2. +1 −3 lib/internal/http2/compat.js
  3. +1 −2 test/parallel/test-http2-compat-serverresponse-destroy.js
@@ -1510,10 +1510,6 @@ added: v8.4.0

* Extends: {net.Server}

In `Http2Server`, there are no `'clientError'` events as there are in
HTTP1. However, there are `'sessionError'`, and `'streamError'` events for
errors emitted on the socket, or from `Http2Session` or `Http2Stream` instances.

#### Event: 'checkContinue'
<!-- YAML
added: v8.5.0
@@ -1563,14 +1559,6 @@ added: v8.4.0
The `'sessionError'` event is emitted when an `'error'` event is emitted by
an `Http2Session` object associated with the `Http2Server`.

#### Event: 'streamError'
<!-- YAML
added: v8.5.0
-->

If a `ServerHttp2Stream` emits an `'error'` event, it will be forwarded here.
The stream will already be destroyed when this event is triggered.

#### Event: 'stream'
<!-- YAML
added: v8.4.0
@@ -115,9 +115,7 @@ function onStreamError(error) {
//
// errors in compatibility mode are
// not forwarded to the request
// and response objects. However,
// they are forwarded to 'streamError'
// on the server by Http2Stream
// and response objects.
}

function onRequestPause() {
@@ -7,8 +7,7 @@ const http2 = require('http2');
const Countdown = require('../common/countdown');

// Check that destroying the Http2ServerResponse stream produces
// the expected result, including the ability to throw an error
// which is emitted on server.streamError
// the expected result.

const errors = [
'test-error',

0 comments on commit fcca2f7

Please sign in to comment.
You can’t perform that action at this time.