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

test: fix flaky test-net-socket-timeout by Trott · Pull Request #10172 · nodejs/node · GitHub

/ node Public

test: fix flaky test-net-socket-timeout - #10172

Closed
Trott wants to merge 1 commit into
nodejs:masterfrom
Trott:socket-timeout
Closed

test: fix flaky test-net-socket-timeout#10172
Trott wants to merge 1 commit into
nodejs:masterfrom
Trott:socket-timeout

Conversation

Trott commented Dec 7, 2016

Copy link
Copy Markdown
Member
Checklist
  • make -j8 test (UNIX), or vcbuild test nosign (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

test net

Description of change

The setTimeout() call is unneeded. If the socket never times out, then
the test will never finish. Because timers can be unreliable on machines
under load, using setTimeout() here effectively creates a race
condition.

The setTimeout() call is unneeded. If the socket never times out, then
the test will never finish. Because timers can be unreliable on machines
under load, using setTimeout() here effectively creates a race
condition.
Trott added net Issues and PRs related to the net subsystem. smartos Issues and PRs related to the SmartOS platform. test Issues and PRs related to the tests. labels Dec 7, 2016

Trott commented Dec 7, 2016

Copy link
Copy Markdown
Member Author

Sample failure on CI:

https://ci.nodejs.org/job/node-test-commit-smartos/5645/nodes=smartos15-64/console

not ok 725 parallel/test-net-socket-timeout
  ---
  duration_ms: 1.36
  severity: fail
  stack: |-

Trott commented Dec 7, 2016

Copy link
Copy Markdown
Member Author

Command to replicate failure on master:

tools/test.py -j32 test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js test/parallel/test-net-socket-timeout.js 

May need to increase 32 and the number of times the test appears in the command line depending on how well-provisioned a machine is.

This same command succeeds with the changes in this PR even if I double it to 64.

Trott commented Dec 7, 2016

Copy link
Copy Markdown
Member Author

@nodejs/testing

mhdawson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM if CI is green.

Trott commented Dec 7, 2016

Copy link
Copy Markdown
Member Author

cjihrig mentioned this pull request Dec 8, 2016
3 tasks

cjihrig commented Dec 8, 2016

Copy link
Copy Markdown
Contributor

CI is good. Let's fast track this.

Trott added a commit to Trott/io.js that referenced this pull request Dec 8, 2016
The setTimeout() call is unneeded. If the socket never times out, then
the test will never finish. Because timers can be unreliable on machines
under load, using setTimeout() here effectively creates a race
condition.

PR-URL: nodejs#10172
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>

Trott commented Dec 8, 2016

Copy link
Copy Markdown
Member Author

Agree with @cjihrig on fast-tracking...landing...

Trott commented Dec 8, 2016

Copy link
Copy Markdown
Member Author

Landed in 6dd0754

Trott closed this Dec 8, 2016
Fishrock123 pushed a commit that referenced this pull request Dec 13, 2016
The setTimeout() call is unneeded. If the socket never times out, then
the test will never finish. Because timers can be unreliable on machines
under load, using setTimeout() here effectively creates a race
condition.

PR-URL: #10172
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
italoacasas mentioned this pull request Dec 15, 2016
MylesBorins pushed a commit that referenced this pull request Jan 16, 2017
The setTimeout() call is unneeded. If the socket never times out, then
the test will never finish. Because timers can be unreliable on machines
under load, using setTimeout() here effectively creates a race
condition.

PR-URL: #10172
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
MylesBorins pushed a commit that referenced this pull request Jan 24, 2017
The setTimeout() call is unneeded. If the socket never times out, then
the test will never finish. Because timers can be unreliable on machines
under load, using setTimeout() here effectively creates a race
condition.

PR-URL: #10172
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
MylesBorins mentioned this pull request Jan 24, 2017
MylesBorins pushed a commit that referenced this pull request Jan 31, 2017
The setTimeout() call is unneeded. If the socket never times out, then
the test will never finish. Because timers can be unreliable on machines
under load, using setTimeout() here effectively creates a race
condition.

PR-URL: #10172
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
Trott deleted the socket-timeout branch January 13, 2022 22:44
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

net Issues and PRs related to the net subsystem. smartos Issues and PRs related to the SmartOS platform. test Issues and PRs related to the tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants


Back | FazBrowse Home | New Git URL