Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

doc: replace alpn with protocol in quic.md #61352

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
kimtaejin3 wants to merge 1 commit into nodejs:main
base: main
Choose a base branch
Loading
from kimtaejin3:doc-quic-protocol

Conversation

@kimtaejin3
Copy link
Contributor

@kimtaejin3 kimtaejin3 commented Jan 12, 2026
edited
Loading

The code was refactored in commit 062ae6f to use 'protocol' instead of 'alpn'
for the ALPN protocol identifier option. However, the documentation was not updated
to reflect this change.

This commit updates the documentation to match the actual implementation:

  • Removes the non-functional 'alpn' option from SessionOptions
  • Adds the 'protocol' option with proper description
  • Updates example code to use 'protocol' instead of 'alpn'
  • Updates OnHandshakeCallback parameter from 'alpn' to 'protocol'

Why this change is necessary:

The destructuring assignment in processTlsOptions() expects a protocol property:
pt
const { protocol } = tls;

Therefore, using alpn will not work:

// This won't work
const alpn = 'h3';
connect(address, { alpn }); // protocol will be undefined

// This is correct
const protocol = 'h3';
connect(address, { protocol });

Refs: 062ae6f3cb5

The code was refactored in commit 062ae6f to use 'protocol'
instead of 'alpn' for the ALPN protocol identifier option.
However, the documentation was not updated to reflect this change.
This commit updates the documentation to match the actual
implementation:
- Removes the non-functional 'alpn' option from SessionOptions
- Adds the 'protocol' option with proper description
- Updates example code to use 'protocol' instead of 'alpn'
- Updates OnHandshakeCallback parameter from 'alpn' to 'protocol'
Refs: nodejs@062ae6f3cb5 
@nodejs-github-bot nodejs-github-bot added doc Issues and PRs related to the documentations. quic Issues and PRs related to the QUIC implementation / HTTP/3. labels Jan 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@avivkeller avivkeller avivkeller approved these changes

Assignees

No one assigned

Labels

doc Issues and PRs related to the documentations. quic Issues and PRs related to the QUIC implementation / HTTP/3.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /