Skip to content

http2: deprecate priority #58313

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
6 changes: 6 additions & 0 deletions doc/api/http2.md
Original file line number Diff line number Diff line change
Expand Up @@ -1457,6 +1457,7 @@ numeric stream identifier.

<!-- YAML
added: v8.4.0
deprecated: REPLACEME
-->

* `options` {Object}
Expand All @@ -1473,6 +1474,8 @@ added: v8.4.0
sending a `PRIORITY` frame to the connected peer.

Updates the priority for this `Http2Stream` instance.
The support for priority weights has been removed in [latest versions of nghttp2 (1.65.0)][nghttp2-priority],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should move this description to the YAML changes: as this will be out-of-date as soon as nghttp releases more versions.

and therefore this method is deprecated.

Comment on lines +1478 to 1479
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Worth noting imo that it's deprecated in the latest HTTP/2 RFCs themselves (RFC 9113, here: https://datatracker.ietf.org/doc/html/rfc9113#section-5.3.1) which is the relevant point for most users. It's not that nghttp2 has just unilaterally dropped support, the whole concept is going away everywhere.

#### `http2stream.rstCode`

Expand Down Expand Up @@ -1585,6 +1588,8 @@ Provides miscellaneous information about the current state of the
instances that depend on this `Http2Stream` as specified using
`PRIORITY` frames.
* `weight` {number} The priority weight of this `Http2Stream`.
The support for priority weights has been removed in [latest versions of nghttp2 (1.65.0)][nghttp2-priority],
and therefore this property is deprecated and it should be ignored.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This applies to sumDependencyWeight too.


A current state of this `Http2Stream`.

Expand Down Expand Up @@ -4929,3 +4934,4 @@ you need to implement any fall-back behavior yourself.
[`tls.createServer()`]: tls.md#tlscreateserveroptions-secureconnectionlistener
[`writable.writableFinished`]: stream.md#writablewritablefinished
[error code]: #error-codes-for-rst_stream-and-goaway
[nghttp2-priority]: https://github.com/nghttp2/nghttp2/releases/tag/v1.65.0
Loading