@@ -3229,9 +3229,6 @@ Sharding Parameters
3229
3229
Maximum time that :binary:`~bin.mongos` goes without communication to a
3230
3230
host before :binary:`~bin.mongos` drops all connections to the host.
3231
3231
3232
- You can only set this parameter during start-up and cannot change
3233
- this setting using the :dbcommand:`setParameter` database command.
3234
-
3235
3232
If set, :parameter:`ShardingTaskExecutorPoolHostTimeoutMS` should be
3236
3233
greater than the sum of
3237
3234
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` and
@@ -3240,10 +3237,21 @@ Sharding Parameters
3240
3237
:parameter:`ShardingTaskExecutorPoolHostTimeoutMS` to be greater than the
3241
3238
sum.
3242
3239
3240
+ The following example sets
3241
+ :parameter:`ShardingTaskExecutorPoolHostTimeoutMS` to ``120000``
3242
+ during startup:
3243
+
3243
3244
.. code-block:: bash
3244
3245
3245
3246
mongos --setParameter ShardingTaskExecutorPoolHostTimeoutMS=120000
3246
3247
3248
+ During runtime, you can also set the parameter with the
3249
+ :dbcommand:`setParameter` command:
3250
+
3251
+ .. code-block:: javascript
3252
+
3253
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolHostTimeoutMS: 120000 } )
3254
+
3247
3255
.. parameter:: ShardingTaskExecutorPoolMaxConnecting
3248
3256
3249
3257
.. versionadded:: 3.6
@@ -3265,13 +3273,21 @@ Sharding Parameters
3265
3273
If it is greater, :binary:`~bin.mongos` ignores the
3266
3274
:parameter:`ShardingTaskExecutorPoolMaxConnecting` value.
3267
3275
3268
- You can only set this parameter during start-up and cannot change
3269
- this setting using the :dbcommand:`setParameter` database command.
3276
+ The following example sets
3277
+ :parameter:`ShardingTaskExecutorPoolMaxConnecting` to ``20``
3278
+ during startup:
3270
3279
3271
3280
.. code-block:: bash
3272
3281
3273
3282
mongos --setParameter ShardingTaskExecutorPoolMaxConnecting=20
3274
3283
3284
+ During runtime, you can also set the parameter with the
3285
+ :dbcommand:`setParameter` command:
3286
+
3287
+ .. code-block:: javascript
3288
+
3289
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMaxConnecting: 20 } )
3290
+
3275
3291
.. parameter:: ShardingTaskExecutorPoolMaxSize
3276
3292
3277
3293
Type: integer
@@ -3289,12 +3305,20 @@ Sharding Parameters
3289
3305
3290
3306
ShardingTaskExecutorPoolMaxSize * taskExecutorPoolSize
3291
3307
3292
- You can only set this parameter during start-up and cannot change
3293
- this setting using the :dbcommand:`setParameter` database command.
3308
+ The following example sets
3309
+ :parameter:`ShardingTaskExecutorPoolMaxSize` to ``20``
3310
+ during startup:
3294
3311
3295
3312
.. code-block:: bash
3296
3313
3297
- mongos --setParameter ShardingTaskExecutorPoolMaxSize=4
3314
+ mongos --setParameter ShardingTaskExecutorPoolMaxSize=20
3315
+
3316
+ During runtime, you can also set the parameter with the
3317
+ :dbcommand:`setParameter` command:
3318
+
3319
+ .. code-block:: javascript
3320
+
3321
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMaxSize: 20 } )
3298
3322
3299
3323
:binary:`~bin.mongos` can have up to ``n`` TaskExecutor connection
3300
3324
pools, where ``n`` is the number of cores. See
@@ -3334,13 +3358,21 @@ Sharding Parameters
3334
3358
:parameter:`warmMinConnectionsInShardingTaskExecutorPoolOnStartup`
3335
3359
parameter is enabled by default for the :binary:`~bin.mongos`.
3336
3360
3337
- You can only set this parameter during start-up and cannot change
3338
- this setting using the :dbcommand:`setParameter` database command.
3361
+ The following example sets
3362
+ :parameter:`ShardingTaskExecutorPoolMinSize` to ``2``
3363
+ during startup:
3339
3364
3340
3365
.. code-block:: bash
3341
3366
3342
3367
mongos --setParameter ShardingTaskExecutorPoolMinSize=2
3343
3368
3369
+ During runtime, you can also set the parameter with the
3370
+ :dbcommand:`setParameter` command:
3371
+
3372
+ .. code-block:: javascript
3373
+
3374
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMinSize: 2 } )
3375
+
3344
3376
:binary:`~bin.mongos` can have up to ``n`` TaskExecutor connection
3345
3377
pools, where ``n`` is the number of cores. See
3346
3378
:parameter:`taskExecutorPoolSize`.
@@ -3361,19 +3393,27 @@ Sharding Parameters
3361
3393
Maximum time the :binary:`~bin.mongos` waits before attempting to
3362
3394
heartbeat a resting connection in the pool.
3363
3395
3364
- You can only set this parameter during start-up and cannot change
3365
- this setting using the :dbcommand:`setParameter` database command.
3366
-
3367
3396
If set, :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` should be
3368
3397
greater than :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS`.
3369
3398
Otherwise, :binary:`~bin.mongos` adjusts the value of
3370
3399
:parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to be less than
3371
3400
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3372
3401
3402
+ The following example sets
3403
+ :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` to
3404
+ ``90000`` during startup:
3405
+
3373
3406
.. code-block:: bash
3374
3407
3375
3408
mongos --setParameter ShardingTaskExecutorPoolRefreshRequirementMS=90000
3376
3409
3410
+ During runtime, you can also set the parameter with the
3411
+ :dbcommand:`setParameter` command:
3412
+
3413
+ .. code-block:: javascript
3414
+
3415
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolRefreshRequirementMS: 90000 } )
3416
+
3377
3417
.. parameter:: ShardingTaskExecutorPoolRefreshTimeoutMS
3378
3418
3379
3419
Type: integer
@@ -3385,19 +3425,27 @@ Sharding Parameters
3385
3425
Maximum time the :binary:`~bin.mongos` waits for a heartbeat before
3386
3426
timing out the heartbeat.
3387
3427
3388
- You can only set this parameter during start-up and cannot change
3389
- this setting using the :dbcommand:`setParameter` database command.
3390
-
3391
3428
If set, :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` should be
3392
3429
less than :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3393
3430
Otherwise, :binary:`~bin.mongos` adjusts the value of
3394
3431
:parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to be less than
3395
3432
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3396
3433
3434
+ The following example sets
3435
+ :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to
3436
+ ``30000`` during startup:
3437
+
3397
3438
.. code-block:: bash
3398
3439
3399
3440
mongos --setParameter ShardingTaskExecutorPoolRefreshTimeoutMS=30000
3400
3441
3442
+ During runtime, you can also set the parameter with the
3443
+ :dbcommand:`setParameter` command:
3444
+
3445
+ .. code-block:: javascript
3446
+
3447
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolRefreshTimeoutMS: 30000 } )
3448
+
3401
3449
.. parameter:: ShardingTaskExecutorPoolReplicaSetMatching
3402
3450
3403
3451
.. versionadded:: 4.2
0 commit comments