Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add descriptions of state properties #18044

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 34 additions & 15 deletions doc/api/http2.md
Original file line number Diff line number Diff line change
Expand Up @@ -540,16 +540,28 @@ All other interactions will be routed directly to the socket.
added: v8.4.0
-->

Provides miscellaneous information about the current state of the
`Http2Session`.

* Value: {Object}
* `effectiveLocalWindowSize` {number}
* `effectiveRecvDataLength` {number}
* `nextStreamID` {number}
* `localWindowSize` {number}
* `lastProcStreamID` {number}
* `remoteWindowSize` {number}
* `outboundQueueSize` {number}
* `deflateDynamicTableSize` {number}
* `inflateDynamicTableSize` {number}
* `effectiveLocalWindowSize` {number} The current local (receive)
flow control window size for the `Http2Session`.
* `effectiveRecvDataLength` {number} The current number of bytes
that have been received since the last flow control `WINDOW_UPDATE`.
* `nextStreamID` {number} The numeric identifier to be used the
next time a new `Http2Stream` is created by this `Http2Session`.
* `localWindowSize` {number} The number of bytes that the remote peer can
send without receiving a `WINDOW_UPDATE`.
* `lastProcStreamID` {number} The numeric id of the `Http2Stream`
for which a `HEADERS` or `DATA` frame was most recently received.
* `remoteWindowSize` {number} The number of bytes that this `Http2Session`
may send without receiving a `WINDOW_UPDATE`.
* `outboundQueueSize` {number} The number of frames currently within the
outbound queue for this `Http2Session`.
* `deflateDynamicTableSize` {number} The current size in bytes of the
outbound header compression state table.
* `inflateDynamicTableSize` {number} The current size in bytes of the
inbound header compression state table.

An object describing the current status of this `Http2Session`.

Expand Down Expand Up @@ -1010,14 +1022,21 @@ req.setTimeout(5000, () => req.rstStream(NGHTTP2_CANCEL));
<!-- YAML
added: v8.4.0
-->
Provides miscellaneous information about the current state of the
`Http2Stream`.

* Value: {Object}
* `localWindowSize` {number}
* `state` {number}
* `localClose` {number}
* `remoteClose` {number}
* `sumDependencyWeight` {number}
* `weight` {number}
* `localWindowSize` {number} The number of bytes the connected peer may send
for this `Http2Stream` without receiving a `WINDOW_UPDATE`.
* `state` {number} A flag indicating the low-level current state of the
`Http2Stream` as determined by nghttp2.
* `localClose` {number} `true` if this `Http2Stream` has been closed locally.
* `remoteClose` {number} `true` if this `Http2Stream` has been closed
remotely.
* `sumDependencyWeight` {number} The sum weight of all `Http2Stream`
instances that depend on this `Http2Stream` as specified using
`PRIORITY` frames.
* `weight` {number} The priority weight of this `Http2Stream`.

A current state of this `Http2Stream`.

Expand Down