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

lib: emit listening event once when call listen twice #52119

Merged
merged 1 commit into from
Mar 19, 2024

Conversation

theanarkh
Copy link
Contributor

Currently we can call listen twice with same server in cluster worker. It will make some issues.

  1. the server will emit listening event twice(See lib: make sure clear the old timer in http server #52118).
  2. resource leak if we do not clear the old resource correctly, such as the old handle.
  • 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
Copy link
Collaborator

Review requested:

  • @nodejs/net

@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. net Issues and PRs related to the net subsystem. labels Mar 16, 2024
Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@mcollina mcollina added the request-ci Add this label to start a Jenkins CI on a PR. label Mar 18, 2024
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Mar 18, 2024
@nodejs-github-bot
Copy link
Collaborator

@theanarkh theanarkh force-pushed the fix_call_net_listen_twice branch from ae3fc20 to dae3f7e Compare March 18, 2024 15:37
@theanarkh theanarkh force-pushed the fix_call_net_listen_twice branch from dae3f7e to db908c7 Compare March 18, 2024 16:46
@theanarkh theanarkh added the request-ci Add this label to start a Jenkins CI on a PR. label Mar 19, 2024
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Mar 19, 2024
@nodejs-github-bot
Copy link
Collaborator

@nodejs-github-bot
Copy link
Collaborator

@mcollina mcollina added commit-queue Add this label to land a pull request using GitHub Actions. author ready PRs that have at least one approval, no pending requests for changes, and a CI started. and removed needs-ci PRs that need a full CI run. labels Mar 19, 2024
@nodejs-github-bot nodejs-github-bot added commit-queue-failed An error occurred while landing this pull request using GitHub Actions. and removed commit-queue Add this label to land a pull request using GitHub Actions. labels Mar 19, 2024
@nodejs-github-bot
Copy link
Collaborator

Commit Queue failed
- Loading data for nodejs/node/pull/52119
✔  Done loading data for nodejs/node/pull/52119
----------------------------------- PR info ------------------------------------
Title      lib: emit listening event once when call listen twice (#52119)
Author     theanarkh  (@theanarkh)
Branch     theanarkh:fix_call_net_listen_twice -> nodejs:main
Labels     net, author ready
Commits    1
 - lib: emit listening event once when call listen twice
Committers 1
 - theanarkh 
PR-URL: https://github.com/nodejs/node/pull/52119
Reviewed-By: Paolo Insogna 
Reviewed-By: Matteo Collina 
------------------------------ Generated metadata ------------------------------
PR-URL: https://github.com/nodejs/node/pull/52119
Reviewed-By: Paolo Insogna 
Reviewed-By: Matteo Collina 
--------------------------------------------------------------------------------
   ⚠  Commits were pushed since the last approving review:
   ⚠  - lib: emit listening event once when call listen twice
   ℹ  This PR was created on Sat, 16 Mar 2024 18:40:00 GMT
   ✔  Approvals: 2
   ✔  - Paolo Insogna (@ShogunPanda) (TSC): https://github.com/nodejs/node/pull/52119#pullrequestreview-1942044076
   ✔  - Matteo Collina (@mcollina) (TSC): https://github.com/nodejs/node/pull/52119#pullrequestreview-1942412097
   ✔  Last GitHub CI successful
   ℹ  Last Full PR CI on 2024-03-19T11:23:20Z: https://ci.nodejs.org/job/node-test-pull-request/57835/
- Querying data for job/node-test-pull-request/57835/
   ✔  Last Jenkins CI successful
--------------------------------------------------------------------------------
   ✔  Aborted `git node land` session in /home/runner/work/node/node/.ncu
https://github.com/nodejs/node/actions/runs/8345768283

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@mcollina mcollina added commit-queue Add this label to land a pull request using GitHub Actions. and removed commit-queue-failed An error occurred while landing this pull request using GitHub Actions. labels Mar 19, 2024
@nodejs-github-bot nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Mar 19, 2024
@nodejs-github-bot nodejs-github-bot merged commit 14de082 into nodejs:main Mar 19, 2024
66 checks passed
@nodejs-github-bot
Copy link
Collaborator

Landed in 14de082

rdw-msft pushed a commit to rdw-msft/node that referenced this pull request Mar 26, 2024
PR-URL: nodejs#52119
Reviewed-By: Paolo Insogna <paolo@cowtech.it>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
marco-ippolito pushed a commit that referenced this pull request May 2, 2024
PR-URL: #52119
Reviewed-By: Paolo Insogna <paolo@cowtech.it>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
marco-ippolito pushed a commit that referenced this pull request May 3, 2024
PR-URL: #52119
Reviewed-By: Paolo Insogna <paolo@cowtech.it>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. net Issues and PRs related to the net subsystem.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants