FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

quic: another round of refactorings by jasnell · Pull Request #34247 · nodejs/node · GitHub

/ node Public

quic: another round of refactorings - #34247

Closed
jasnell wants to merge 16 commits into
nodejs:masterfrom
jasnell:quic-cleanups-4
Closed

quic: another round of refactorings#34247
jasnell wants to merge 16 commits into
nodejs:masterfrom
jasnell:quic-cleanups-4

Conversation

jasnell commented Jul 7, 2020
edited
Loading

Copy link
Copy Markdown
Member

This is a WIP, more will be added:

Commits:

  • quic: additional minor cleanups in node_quic_session.h

    Minor miscellaneous cleanups

  • quic: remove unnecessary bool conversion

    Self-explanatory

  • quic: handle errors thrown / rejections in the session event

  • quic: refactor/improve error handling for busy event

  • quic: add tests confirming error handling for QuicSocket close event

  • quic: refactor/improve QuicSocket ready event handling

  • quic: refactor/improve QuicSocket ready event handling

    Starting to improve/refactor/verify error handling on events

  • quic: use Number() instead of bigint for QuicSocket stats

  • quic: unref timers again

    Fix a bug

  • quic: use getter/setting for stateless reset toggle

    Improve API ergonomics

  • quic: cleanup QuicSocketFlags, used shared state struct

    Use AliasedStruct for QuicSocket shared state, cleanup no longer used state flags

  • quic: proper custom inspect for QuicEndpoint/QuicSocket/QuicSession/QuicStream

    Self explanatory

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines

nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. quic Issues and PRs related to the QUIC implementation / HTTP/3. labels Jul 7, 2020
jasnell added the experimental Issues and PRs related to experimental features. label Jul 7, 2020
Errors thrown within the session event handler will be handled
by destroying the session (allowing a proper connection close
to be sent to the client peer). They will not crash the parent
QuicSocket by default. Instead, a `'sessionError'` event will
be emitted, allowing the error to be logged or handled.
jasnell force-pushed the quic-cleanups-4 branch from af92b72 to ebc8f5e Compare July 7, 2020 20:21

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

0f97d60 accidentally removed this.

Refs: nodejs#34186

This comment has been minimized.

jasnell force-pushed the quic-cleanups-4 branch 2 times, most recently from c767d37 to f044069 Compare July 8, 2020 16:06
Some of the flags were no longer being used.

Switched to use an AliasedStruct for shared state to avoid
extraneous expensive JS=>C++ calls.

Removed unused QuicSocket option
jasnell force-pushed the quic-cleanups-4 branch 2 times, most recently from e5cea72 to 2a61277 Compare July 8, 2020 17:05
jasnell marked this pull request as ready for review July 8, 2020 17:07
jasnell requested a review from a team July 8, 2020 17:07

jasnell commented Jul 8, 2020

Copy link
Copy Markdown
Member Author

Ping @nodejs/quic... this is ready for review

jasnell commented Jul 8, 2020

Copy link
Copy Markdown
Member Author

Both CI's are good.

jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
The argument will always be a boolean already

PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
Errors thrown within the session event handler will be handled
by destroying the session (allowing a proper connection close
to be sent to the client peer). They will not crash the parent
QuicSocket by default. Instead, a `'sessionError'` event will
be emitted, allowing the error to be logged or handled.

PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
Also, change setServerBusy into a setter

PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell pushed a commit that referenced this pull request Jul 9, 2020
0f97d60 accidentally removed this.

Refs: #34186

PR-URL: #34247
Reviewed-By: James M Snell <jasnell@gmail.com>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
Some of the flags were no longer being used.

Switched to use an AliasedStruct for shared state to avoid
extraneous expensive JS=>C++ calls.

Removed unused QuicSocket option

PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>
jasnell added a commit that referenced this pull request Jul 9, 2020
PR-URL: #34247
Reviewed-By: Anna Henningsen <anna@addaleax.net>

jasnell commented Jul 9, 2020

Copy link
Copy Markdown
Member Author

Landed in e8f5745...26493c0

Copy link
Copy Markdown
Contributor

Marked as "backport-requested" because I do not believe quic is on 14.x yet. Should we change the label to "dont-land"?

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

c++ Issues and PRs that require attention from people who are familiar with C++. experimental Issues and PRs related to experimental features. quic Issues and PRs related to the QUIC implementation / HTTP/3.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants


Back | FazBrowse Home | New Git URL