| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
There is no official way to figure out if the socket that you have on hand is still connecting to the remote host. Introduce `Socket#connecting`, which is essentially an unprefixed `_connecting` property that we already had.
|
cc @nodejs/collaborators @bnoordhuis |
Sorry, something went wrong.
| }); | ||
|
|
||
| console.log('_connecting = ' + socket._connecting); | ||
| console.log('_connecting = ' + socket.connecting); |
There was a problem hiding this comment.
Should the text also be changed to 'connecting = '?
Sorry, something went wrong.
There was a problem hiding this comment.
Doesn't really matter, IMO
Sorry, something went wrong.
There was a problem hiding this comment.
Changing the text might save someone a cycle or two if the test fails and they start poking around trying to figure out why... probably slightly more time than it took me to write this (almost none, but non-zero).
Sorry, something went wrong.
There was a problem hiding this comment.
@rmg I disagree, but will change it. Ack.
Sorry, something went wrong.
|
LGTM with a question |
Sorry, something went wrong.
| three properties, e.g. | ||
| `{ port: 12346, family: 'IPv4', address: '127.0.0.1' }` | ||
|
|
||
| ### socket.connecting |
There was a problem hiding this comment.
Should be below socket.bufferSize to keep them in alphabetical order.
Sorry, something went wrong.
There was a problem hiding this comment.
Ack.
Sorry, something went wrong.
| server.close(); | ||
| }).listen(common.PORT, () => { | ||
| const client = net.connect(common.PORT, () => { | ||
| assert.equal(client.connecting, false); |
There was a problem hiding this comment.
strictEqual would be better I guess.
Sorry, something went wrong.
There was a problem hiding this comment.
Ack.
Sorry, something went wrong.
|
All fixed. Thanks! |
Sorry, something went wrong.
|
LGTM |
Sorry, something went wrong.
There is no official way to figure out if the socket that you have on hand is still connecting to the remote host. Introduce `Socket#connecting`, which is essentially an unprefixed `_connecting` property that we already had. PR-URL: #6404 Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
|
We're going to need to keep _connecting anyways... |
Sorry, something went wrong.
There is no official way to figure out if the socket that you have on hand is still connecting to the remote host. Introduce `Socket#connecting`, which is essentially an unprefixed `_connecting` property that we already had. PR-URL: #6404 Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
* assert: `deep{Strict}Equal()` now works correctly with circular
references. (Rich Trott) #6432
* debugger: Arrays are now formatted correctly in the debugger repl.
(cjihrig) #6448
* deps: Upgrade OpenSSL sources to 1.0.2h (Shigeki Ohtsu)
#6550
* net: Introduced a `Socket#connecting` property. (Fedor Indutny)
#6404
- Previously this information was only available as the undocumented,
internal `_connecting` property.
* process: Introduced `process.cpuUsage()`. (Patrick Mueller)
#6157
* stream: `Writable#setDefaultEncoding()` now returns `this`.
(Alexander Makarenko) #5040
* util: Two new additions to `util.inspect()`:
- Added a `maxArrayLength` option to truncate the formatting of
Arrays. (James M Snell) #6334
- This is set to `100` by default.
- Added a `showProxy` option for formatting proxy intercepting
handlers. (James M Snell) #6465
- Inspecting proxies is non-trivial and as such this is off by
default.
PR-URL: #6557
* assert: `deep{Strict}Equal()` now works correctly with circular
references. (Rich Trott) #6432
* debugger: Arrays are now formatted correctly in the debugger repl.
(cjihrig) #6448
* deps: Upgrade OpenSSL sources to 1.0.2h (Shigeki Ohtsu)
#6550
- Please see our blog post for more info on the security contents of this release:
- https://nodejs.org/en/blog/vulnerability/openssl-may-2016/
* net: Introduced a `Socket#connecting` property. (Fedor Indutny)
#6404
- Previously this information was only available as the undocumented,
internal `_connecting` property.
* process: Introduced `process.cpuUsage()`. (Patrick Mueller)
#6157
* stream: `Writable#setDefaultEncoding()` now returns `this`.
(Alexander Makarenko) #5040
* util: Two new additions to `util.inspect()`:
- Added a `maxArrayLength` option to truncate the formatting of
Arrays. (James M Snell) #6334
- This is set to `100` by default.
- Added a `showProxy` option for formatting proxy intercepting
handlers. (James M Snell) #6465
- Inspecting proxies is non-trivial and as such this is off by
default.
PR-URL: #6557
* assert: `deep{Strict}Equal()` now works correctly with circular
references. (Rich Trott) #6432
* debugger: Arrays are now formatted correctly in the debugger repl.
(cjihrig) #6448
* deps: Upgrade OpenSSL sources to 1.0.2h (Shigeki Ohtsu)
#6550
- Please see our blog post for more info on the security contents of
this release:
- https://nodejs.org/en/blog/vulnerability/openssl-may-2016/
* net: Introduced a `Socket#connecting` property. (Fedor Indutny)
#6404
- Previously this information was only available as the undocumented,
internal `_connecting` property.
* process: Introduced `process.cpuUsage()`. (Patrick Mueller)
#6157
* stream: `Writable#setDefaultEncoding()` now returns `this`.
(Alexander Makarenko) #5040
* util: Two new additions to `util.inspect()`:
- Added a `maxArrayLength` option to truncate the formatting of
Arrays. (James M Snell) #6334
- This is set to `100` by default.
- Added a `showProxy` option for formatting proxy intercepting
handlers. (James M Snell) #6465
- Inspecting proxies is non-trivial and as such this is off by
default.
PR-URL: #6557
|
@nodejs/lts @nodejs/ctc do we want to backport this in v4.5.0? |
Sorry, something went wrong.
|
👍 from me. |
Sorry, something went wrong.
There is no official way to figure out if the socket that you have on hand is still connecting to the remote host. Introduce `Socket#connecting`, which is essentially an unprefixed `_connecting` property that we already had. PR-URL: #6404 Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
|
I've gone ahead and landed this on v4.x-staging. it required some manual work so any eyes on it would be nice 0eef098. If anyone has any trepidation regarding this change please let me know and it can be backed out. |
Sorry, something went wrong.
There is no official way to figure out if the socket that you have on hand is still connecting to the remote host. Introduce `Socket#connecting`, which is essentially an unprefixed `_connecting` property that we already had. PR-URL: #6404 Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
|
I'm not so keen on this in LTS, it's not a vital and _connecting if anyone thinks it is. It's hard to justify a semver-minor bump for something like this in LTS that's not critical in any way. This is how we currently have it framed in the LTS plan:
Not that I really want to have to get the CTC involved in something like this but the spirit of the LTS plan is that semver-minor changes would be minimal and should therefore be restricted to stability and security things or changes that have a very clear reason for needing to be across as many active versions of Node as possible (likley already covered by "stability and security" things). I don't see this being in that category. |
Sorry, something went wrong.
|
@rvagg that is reasonable. I've gone ahead and backed it out. I'm going to open an issue that will outline all semver-minor commits are currently in staging so we can audit them. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Checklist
Affected core subsystem(s)
net
Description of change
There is no official way to figure out if the socket that you have on
hand is still connecting to the remote host. Introduce
Socket#connecting, which is essentially an unprefixed _connecting
property that we already had.