mirror of
https://github.com/ruby/ruby.git
synced 2025-08-23 04:55:21 +02:00
Improve the conditions for clearing the Connection Attempt Delay upon connection failure (#12223)
* Improve the conditions for clearing the Connection Attempt Delay upon connection failure This change addresses a case that was overlooked in ruby/ruby#12087. In the previous change, the Connection Attempt Delay was cleared at the point of a connection failure only if both of the following conditions were met: - No other sockets were attempting a connection - There were addresses still available to start a new connection In this update, the second condition has been removed. As a result, if name resolution succeeds after a connection failure and new addresses are obtained, it will be able to immediately attempt a connection to one of them. If there are no sockets attempting a connection, no addresses available for connection, and name resolution has completed, an exception will still be raised as before. --- Additionally, the following minor fixes have been made: * Refactor: Remove unnecessary members
This commit is contained in:
parent
fdf60d735c
commit
3d07754ee2
Notes:
git
2024-11-30 09:52:19 +00:00
Merged-By: shioimm <shioi.mm@gmail.com>
2 changed files with 3 additions and 9 deletions
|
@ -440,9 +440,8 @@ struct fast_fallback_getaddrinfo_entry
|
|||
|
||||
struct fast_fallback_getaddrinfo_shared
|
||||
{
|
||||
int notify, refcount, connection_attempt_fds_size;
|
||||
int notify, refcount;
|
||||
int cancelled;
|
||||
int *connection_attempt_fds;
|
||||
char *node, *service;
|
||||
rb_nativethread_lock_t *lock;
|
||||
struct fast_fallback_getaddrinfo_entry getaddrinfo_entries[FLEX_ARY_LEN];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue