* [ruby-core:120133] [Ruby master Feature#20935] API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class
@ 2024-12-08 9:01 shioimm (Misaki Shioi) via ruby-core
2024-12-12 10:49 ` [ruby-core:120209] " mame (Yusuke Endoh) via ruby-core
2024-12-14 6:52 ` [ruby-core:120238] " shioimm (Misaki Shioi) via ruby-core
0 siblings, 2 replies; 3+ messages in thread
From: shioimm (Misaki Shioi) via ruby-core @ 2024-12-08 9:01 UTC (permalink / raw)
To: ruby-core; +Cc: shioimm (Misaki Shioi)
Issue #20935 has been reported by shioimm (Misaki Shioi).
----------------------------------------
Feature #20935: API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class
https://bugs.ruby-lang.org/issues/20935
* Author: shioimm (Misaki Shioi)
* Status: Open
----------------------------------------
When introducing Happy Eyeballs Version 2 to `Socket.tcp` (https://bugs.ruby-lang.org/issues/20108), it was pointed out that there should be a way to disable this feature (https://bugs.ruby-lang.org/issues/20108#note-7).
To address this, I added `fast_fallback: true or false` keyword argument to both `Socket.tcp` and `TCPSocket.new`.
Additionally, I introduced two singleton methods to the `Socket` class: `tcp_fast_fallback=` and `tcp_fast_fallback`.
These can be used as follows:
```ruby
Socket.tcp(host, port, fast_fallback: true)
TCPSocket.new(host, port, fast_fallback: true)
# Globally controlling HEv2
Socket.tcp_fast_fallback = true # => true
Socket.tcp_fast_fallback # => true
```
I apologize for this after the implementation, but I would like to discuss whether adding these APIs is appropriate.
--
https://bugs.ruby-lang.org/
______________________________________________
ruby-core mailing list -- ruby-core@ml.ruby-lang.org
To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
* [ruby-core:120209] [Ruby master Feature#20935] API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class
2024-12-08 9:01 [ruby-core:120133] [Ruby master Feature#20935] API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class shioimm (Misaki Shioi) via ruby-core
@ 2024-12-12 10:49 ` mame (Yusuke Endoh) via ruby-core
2024-12-14 6:52 ` [ruby-core:120238] " shioimm (Misaki Shioi) via ruby-core
1 sibling, 0 replies; 3+ messages in thread
From: mame (Yusuke Endoh) via ruby-core @ 2024-12-12 10:49 UTC (permalink / raw)
To: ruby-core; +Cc: mame (Yusuke Endoh)
Issue #20935 has been updated by mame (Yusuke Endoh).
@matz approved the new API, and also wanted a configuration to stop happy eyeballs by an environment variable: `RUBY_TCP_NO_FAST_FALLBACK=1`.
----------------------------------------
Feature #20935: API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class
https://bugs.ruby-lang.org/issues/20935#change-110972
* Author: shioimm (Misaki Shioi)
* Status: Open
----------------------------------------
When introducing Happy Eyeballs Version 2 to `Socket.tcp` (https://bugs.ruby-lang.org/issues/20108), it was pointed out that there should be a way to disable this feature (https://bugs.ruby-lang.org/issues/20108#note-7).
To address this, I added `fast_fallback: true or false` keyword argument to both `Socket.tcp` and `TCPSocket.new`.
Additionally, I introduced two singleton methods to the `Socket` class: `tcp_fast_fallback=` and `tcp_fast_fallback`.
These can be used as follows:
```ruby
Socket.tcp(host, port, fast_fallback: true)
TCPSocket.new(host, port, fast_fallback: true)
# Globally controlling HEv2
Socket.tcp_fast_fallback = true # => true
Socket.tcp_fast_fallback # => true
```
I apologize for this after the implementation, but I would like to discuss whether adding these APIs is appropriate.
--
https://bugs.ruby-lang.org/
______________________________________________
ruby-core mailing list -- ruby-core@ml.ruby-lang.org
To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
* [ruby-core:120238] [Ruby master Feature#20935] API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class
2024-12-08 9:01 [ruby-core:120133] [Ruby master Feature#20935] API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class shioimm (Misaki Shioi) via ruby-core
2024-12-12 10:49 ` [ruby-core:120209] " mame (Yusuke Endoh) via ruby-core
@ 2024-12-14 6:52 ` shioimm (Misaki Shioi) via ruby-core
1 sibling, 0 replies; 3+ messages in thread
From: shioimm (Misaki Shioi) via ruby-core @ 2024-12-14 6:52 UTC (permalink / raw)
To: ruby-core; +Cc: shioimm (Misaki Shioi)
Issue #20935 has been updated by shioimm (Misaki Shioi).
Status changed from Open to Closed
New environment variables added in this PR https://github.com/ruby/ruby/pull/12257 .
----------------------------------------
Feature #20935: API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class
https://bugs.ruby-lang.org/issues/20935#change-111006
* Author: shioimm (Misaki Shioi)
* Status: Closed
----------------------------------------
When introducing Happy Eyeballs Version 2 to `Socket.tcp` (https://bugs.ruby-lang.org/issues/20108), it was pointed out that there should be a way to disable this feature (https://bugs.ruby-lang.org/issues/20108#note-7).
To address this, I added `fast_fallback: true or false` keyword argument to both `Socket.tcp` and `TCPSocket.new`.
Additionally, I introduced two singleton methods to the `Socket` class: `tcp_fast_fallback=` and `tcp_fast_fallback`.
These can be used as follows:
```ruby
Socket.tcp(host, port, fast_fallback: true)
TCPSocket.new(host, port, fast_fallback: true)
# Globally controlling HEv2
Socket.tcp_fast_fallback = true # => true
Socket.tcp_fast_fallback # => true
```
I apologize for this after the implementation, but I would like to discuss whether adding these APIs is appropriate.
--
https://bugs.ruby-lang.org/
______________________________________________
ruby-core mailing list -- ruby-core@ml.ruby-lang.org
To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org
ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-12-14 6:52 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-12-08 9:01 [ruby-core:120133] [Ruby master Feature#20935] API for Globally Enabling/Disabling Happy Eyeballs Version 2 in the Socket Class shioimm (Misaki Shioi) via ruby-core
2024-12-12 10:49 ` [ruby-core:120209] " mame (Yusuke Endoh) via ruby-core
2024-12-14 6:52 ` [ruby-core:120238] " shioimm (Misaki Shioi) via ruby-core
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).