You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(#2159)
* use ubuntu1604 for ruby 2.3 testing
* JRuby 9.2.14.0 added TCP_KEEPINTVL etc. but they are not working
* document jruby keepalive limitation
Co-authored-by: Oleg Pudeyev <[email protected]>
Copy file name to clipboardExpand all lines: source/tutorials/ruby-driver-create-client.txt
+15-4Lines changed: 15 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -1253,16 +1253,27 @@ The driver does not currently implement the Happy Eyeballs algorithm.
1253
1253
TCP Keepalive Configuration
1254
1254
===========================
1255
1255
1256
-
The driver sets TCP keepalive by default. The following default values are also set if the system
1257
-
value can be determined and if the driver default value is less than the system value.
1256
+
Where allowed by system configuration and the Ruby language runtime,
1257
+
the driver enables TCP keepalive and, for each of the keepalive parameters
1258
+
listed below, sets the value of the respective parameter to the specified
1259
+
value if the system value can be determined and is higher than the
1260
+
listed driver value:
1258
1261
1259
1262
- ``tcp_keepalive_time``: 120 seconds
1260
1263
- ``tcp_keepalive_intvl``: 10 seconds
1261
1264
- ``tcp_keepalive_cnt``: 9 probes
1262
1265
1266
+
.. note::
1267
+
1268
+
As of JRuby 9.2.14.0, JRuby does not implement the APIs required to
1269
+
set the keepalive parameters. When using JRuby, the driver will not be
1270
+
able to set the keepalive parameters and the system configuration will
1271
+
be in effect.
1263
1272
1264
-
Please see the `MongoDB Diagnostics FAQ keepalive section <https://github.com/mongodb/specifications/blob/master/source/server-selection/server-selection.rst#serverselectiontimeoutms>`_
1265
-
for instructions on setting these values at the system level.
1273
+
To use lower values, or to change the parameters in environments like JRuby
1274
+
that do not expose the required APIs, please adjust the parameters at the
1275
+
system level as described in the `MongoDB Diagnostics FAQ keepalive section
0 commit comments