Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Currently, the socket connection timeout is depending on Linux kernel system setting tcp_syn_retries. The timeout value is 2 ^ (tcp_sync_retries + 1) - 1 seconds. For the reasons below, we want to control the client-side socket timeout directly using configuration files. 

  1. The default value of Linux  of tcp_syn_retries is 6 may be large, such as 6 for Linux. It means the default timeout value is 127 seconds and too long in some scenarios. 
  2. Currently, the leastLoadedNode() provides a cached node with the criteria below. 

    1. Provide the connected node with least number of inflight requests
    2. If no connected node exists, provide the connecting node with the largest index in the cached list of nodes.
    3. If no connected or connecting node exists, provide the disconnected node which respects the reconnect backoff with the largest index in the cached list of nodes.

...