@@ -3008,9 +3008,6 @@ Sharding Parameters
3008
3008
Maximum time that :binary:`~bin.mongos` goes without communication to a
3009
3009
host before :binary:`~bin.mongos` drops all connections to the host.
3010
3010
3011
- You can only set this parameter during start-up and cannot change
3012
- this setting using the :dbcommand:`setParameter` database command.
3013
-
3014
3011
If set, :parameter:`ShardingTaskExecutorPoolHostTimeoutMS` should be
3015
3012
greater than the sum of
3016
3013
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` and
@@ -3019,10 +3016,21 @@ Sharding Parameters
3019
3016
:parameter:`ShardingTaskExecutorPoolHostTimeoutMS` to be greater than the
3020
3017
sum.
3021
3018
3019
+ The following example sets
3020
+ :parameter:`ShardingTaskExecutorPoolHostTimeoutMS` to ``120000``
3021
+ during startup:
3022
+
3022
3023
.. code-block:: bash
3023
3024
3024
3025
mongos --setParameter ShardingTaskExecutorPoolHostTimeoutMS=120000
3025
3026
3027
+ During runtime, you can also set the parameter with the
3028
+ :dbcommand:`setParameter` command:
3029
+
3030
+ .. code-block:: javascript
3031
+
3032
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolHostTimeoutMS: 120000 } )
3033
+
3026
3034
.. parameter:: ShardingTaskExecutorPoolMaxConnecting
3027
3035
3028
3036
.. versionadded:: 3.6
@@ -3044,13 +3052,21 @@ Sharding Parameters
3044
3052
If it is greater, :binary:`~bin.mongos` ignores the
3045
3053
:parameter:`ShardingTaskExecutorPoolMaxConnecting` value.
3046
3054
3047
- You can only set this parameter during start-up and cannot change
3048
- this setting using the :dbcommand:`setParameter` database command.
3055
+ The following example sets
3056
+ :parameter:`ShardingTaskExecutorPoolMaxConnecting` to ``20``
3057
+ during startup:
3049
3058
3050
3059
.. code-block:: bash
3051
3060
3052
3061
mongos --setParameter ShardingTaskExecutorPoolMaxConnecting=20
3053
3062
3063
+ During runtime, you can also set the parameter with the
3064
+ :dbcommand:`setParameter` command:
3065
+
3066
+ .. code-block:: javascript
3067
+
3068
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMaxConnecting: 20 } )
3069
+
3054
3070
.. parameter:: ShardingTaskExecutorPoolMaxSize
3055
3071
3056
3072
Type: integer
@@ -3068,12 +3084,20 @@ Sharding Parameters
3068
3084
3069
3085
ShardingTaskExecutorPoolMaxSize * taskExecutorPoolSize
3070
3086
3071
- You can only set this parameter during start-up and cannot change
3072
- this setting using the :dbcommand:`setParameter` database command.
3087
+ The following example sets
3088
+ :parameter:`ShardingTaskExecutorPoolMaxSize` to ``20``
3089
+ during startup:
3073
3090
3074
3091
.. code-block:: bash
3075
3092
3076
- mongos --setParameter ShardingTaskExecutorPoolMaxSize=4
3093
+ mongos --setParameter ShardingTaskExecutorPoolMaxSize=20
3094
+
3095
+ During runtime, you can also set the parameter with the
3096
+ :dbcommand:`setParameter` command:
3097
+
3098
+ .. code-block:: javascript
3099
+
3100
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMaxSize: 20 } )
3077
3101
3078
3102
:binary:`~bin.mongos` can have up to ``n`` TaskExecutor connection
3079
3103
pools, where ``n`` is the number of cores. See
@@ -3113,13 +3137,21 @@ Sharding Parameters
3113
3137
:parameter:`warmMinConnectionsInShardingTaskExecutorPoolOnStartup`
3114
3138
parameter is enabled by default for the :binary:`~bin.mongos`.
3115
3139
3116
- You can only set this parameter during start-up and cannot change
3117
- this setting using the :dbcommand:`setParameter` database command.
3140
+ The following example sets
3141
+ :parameter:`ShardingTaskExecutorPoolMinSize` to ``2``
3142
+ during startup:
3118
3143
3119
3144
.. code-block:: bash
3120
3145
3121
3146
mongos --setParameter ShardingTaskExecutorPoolMinSize=2
3122
3147
3148
+ During runtime, you can also set the parameter with the
3149
+ :dbcommand:`setParameter` command:
3150
+
3151
+ .. code-block:: javascript
3152
+
3153
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMinSize: 2 } )
3154
+
3123
3155
:binary:`~bin.mongos` can have up to ``n`` TaskExecutor connection
3124
3156
pools, where ``n`` is the number of cores. See
3125
3157
:parameter:`taskExecutorPoolSize`.
@@ -3140,19 +3172,27 @@ Sharding Parameters
3140
3172
Maximum time the :binary:`~bin.mongos` waits before attempting to
3141
3173
heartbeat a resting connection in the pool.
3142
3174
3143
- You can only set this parameter during start-up and cannot change
3144
- this setting using the :dbcommand:`setParameter` database command.
3145
-
3146
3175
If set, :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` should be
3147
3176
greater than :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS`.
3148
3177
Otherwise, :binary:`~bin.mongos` adjusts the value of
3149
3178
:parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to be less than
3150
3179
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3151
3180
3181
+ The following example sets
3182
+ :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` to
3183
+ ``90000`` during startup:
3184
+
3152
3185
.. code-block:: bash
3153
3186
3154
3187
mongos --setParameter ShardingTaskExecutorPoolRefreshRequirementMS=90000
3155
3188
3189
+ During runtime, you can also set the parameter with the
3190
+ :dbcommand:`setParameter` command:
3191
+
3192
+ .. code-block:: javascript
3193
+
3194
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolRefreshRequirementMS: 90000 } )
3195
+
3156
3196
.. parameter:: ShardingTaskExecutorPoolRefreshTimeoutMS
3157
3197
3158
3198
Type: integer
@@ -3164,19 +3204,27 @@ Sharding Parameters
3164
3204
Maximum time the :binary:`~bin.mongos` waits for a heartbeat before
3165
3205
timing out the heartbeat.
3166
3206
3167
- You can only set this parameter during start-up and cannot change
3168
- this setting using the :dbcommand:`setParameter` database command.
3169
-
3170
3207
If set, :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` should be
3171
3208
less than :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3172
3209
Otherwise, :binary:`~bin.mongos` adjusts the value of
3173
3210
:parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to be less than
3174
3211
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3175
3212
3213
+ The following example sets
3214
+ :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to
3215
+ ``30000`` during startup:
3216
+
3176
3217
.. code-block:: bash
3177
3218
3178
3219
mongos --setParameter ShardingTaskExecutorPoolRefreshTimeoutMS=30000
3179
3220
3221
+ During runtime, you can also set the parameter with the
3222
+ :dbcommand:`setParameter` command:
3223
+
3224
+ .. code-block:: javascript
3225
+
3226
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolRefreshTimeoutMS: 30000 } )
3227
+
3180
3228
.. parameter:: ShardingTaskExecutorPoolReplicaSetMatching
3181
3229
3182
3230
.. versionadded:: 4.2
0 commit comments