@@ -2837,9 +2837,6 @@ Sharding Parameters
2837
2837
Maximum time that :binary:`~bin.mongos` goes without communication to a
2838
2838
host before :binary:`~bin.mongos` drops all connections to the host.
2839
2839
2840
- You can only set this parameter during start-up and cannot change
2841
- this setting using the :dbcommand:`setParameter` database command.
2842
-
2843
2840
If set, :parameter:`ShardingTaskExecutorPoolHostTimeoutMS` should be
2844
2841
greater than the sum of
2845
2842
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` and
@@ -2848,10 +2845,21 @@ Sharding Parameters
2848
2845
:parameter:`ShardingTaskExecutorPoolHostTimeoutMS` to be greater than the
2849
2846
sum.
2850
2847
2848
+ The following example sets
2849
+ :parameter:`ShardingTaskExecutorPoolHostTimeoutMS` to ``120000``
2850
+ during startup:
2851
+
2851
2852
.. code-block:: bash
2852
2853
2853
2854
mongos --setParameter ShardingTaskExecutorPoolHostTimeoutMS=120000
2854
2855
2856
+ During runtime, you can also set the parameter with the
2857
+ :dbcommand:`setParameter` command:
2858
+
2859
+ .. code-block:: javascript
2860
+
2861
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolHostTimeoutMS: 120000 } )
2862
+
2855
2863
.. parameter:: ShardingTaskExecutorPoolMaxConnecting
2856
2864
2857
2865
.. versionadded:: 3.6
@@ -2873,13 +2881,21 @@ Sharding Parameters
2873
2881
If it is greater, :binary:`~bin.mongos` ignores the
2874
2882
:parameter:`ShardingTaskExecutorPoolMaxConnecting` value.
2875
2883
2876
- You can only set this parameter during start-up and cannot change
2877
- this setting using the :dbcommand:`setParameter` database command.
2884
+ The following example sets
2885
+ :parameter:`ShardingTaskExecutorPoolMaxConnecting` to ``20``
2886
+ during startup:
2878
2887
2879
2888
.. code-block:: bash
2880
2889
2881
2890
mongos --setParameter ShardingTaskExecutorPoolMaxConnecting=20
2882
2891
2892
+ During runtime, you can also set the parameter with the
2893
+ :dbcommand:`setParameter` command:
2894
+
2895
+ .. code-block:: javascript
2896
+
2897
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMaxConnecting: 20 } )
2898
+
2883
2899
.. parameter:: ShardingTaskExecutorPoolMaxSize
2884
2900
2885
2901
Type: integer
@@ -2897,12 +2913,20 @@ Sharding Parameters
2897
2913
2898
2914
ShardingTaskExecutorPoolMaxSize * taskExecutorPoolSize
2899
2915
2900
- You can only set this parameter during start-up and cannot change
2901
- this setting using the :dbcommand:`setParameter` database command.
2916
+ The following example sets
2917
+ :parameter:`ShardingTaskExecutorPoolMaxSize` to ``20``
2918
+ during startup:
2902
2919
2903
2920
.. code-block:: bash
2904
2921
2905
- mongos --setParameter ShardingTaskExecutorPoolMaxSize=4
2922
+ mongos --setParameter ShardingTaskExecutorPoolMaxSize=20
2923
+
2924
+ During runtime, you can also set the parameter with the
2925
+ :dbcommand:`setParameter` command:
2926
+
2927
+ .. code-block:: javascript
2928
+
2929
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMaxSize: 20 } )
2906
2930
2907
2931
:binary:`~bin.mongos` can have up to ``n`` TaskExecutor connection
2908
2932
pools, where ``n`` is the number of cores. See
@@ -2942,13 +2966,21 @@ Sharding Parameters
2942
2966
:parameter:`warmMinConnectionsInShardingTaskExecutorPoolOnStartup`
2943
2967
parameter is enabled by default for the :binary:`~bin.mongos`.
2944
2968
2945
- You can only set this parameter during start-up and cannot change
2946
- this setting using the :dbcommand:`setParameter` database command.
2969
+ The following example sets
2970
+ :parameter:`ShardingTaskExecutorPoolMinSize` to ``2``
2971
+ during startup:
2947
2972
2948
2973
.. code-block:: bash
2949
2974
2950
2975
mongos --setParameter ShardingTaskExecutorPoolMinSize=2
2951
2976
2977
+ During runtime, you can also set the parameter with the
2978
+ :dbcommand:`setParameter` command:
2979
+
2980
+ .. code-block:: javascript
2981
+
2982
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolMinSize: 2 } )
2983
+
2952
2984
:binary:`~bin.mongos` can have up to ``n`` TaskExecutor connection
2953
2985
pools, where ``n`` is the number of cores. See
2954
2986
:parameter:`taskExecutorPoolSize`.
@@ -2969,19 +3001,27 @@ Sharding Parameters
2969
3001
Maximum time the :binary:`~bin.mongos` waits before attempting to
2970
3002
heartbeat a resting connection in the pool.
2971
3003
2972
- You can only set this parameter during start-up and cannot change
2973
- this setting using the :dbcommand:`setParameter` database command.
2974
-
2975
3004
If set, :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` should be
2976
3005
greater than :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS`.
2977
3006
Otherwise, :binary:`~bin.mongos` adjusts the value of
2978
3007
:parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to be less than
2979
3008
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
2980
3009
3010
+ The following example sets
3011
+ :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS` to
3012
+ ``90000`` during startup:
3013
+
2981
3014
.. code-block:: bash
2982
3015
2983
3016
mongos --setParameter ShardingTaskExecutorPoolRefreshRequirementMS=90000
2984
3017
3018
+ During runtime, you can also set the parameter with the
3019
+ :dbcommand:`setParameter` command:
3020
+
3021
+ .. code-block:: javascript
3022
+
3023
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolRefreshRequirementMS: 90000 } )
3024
+
2985
3025
.. parameter:: ShardingTaskExecutorPoolRefreshTimeoutMS
2986
3026
2987
3027
Type: integer
@@ -2993,19 +3033,27 @@ Sharding Parameters
2993
3033
Maximum time the :binary:`~bin.mongos` waits for a heartbeat before
2994
3034
timing out the heartbeat.
2995
3035
2996
- You can only set this parameter during start-up and cannot change
2997
- this setting using the :dbcommand:`setParameter` database command.
2998
-
2999
3036
If set, :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` should be
3000
3037
less than :parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3001
3038
Otherwise, :binary:`~bin.mongos` adjusts the value of
3002
3039
:parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to be less than
3003
3040
:parameter:`ShardingTaskExecutorPoolRefreshRequirementMS`.
3004
3041
3042
+ The following example sets
3043
+ :parameter:`ShardingTaskExecutorPoolRefreshTimeoutMS` to
3044
+ ``30000`` during startup:
3045
+
3005
3046
.. code-block:: bash
3006
3047
3007
3048
mongos --setParameter ShardingTaskExecutorPoolRefreshTimeoutMS=30000
3008
3049
3050
+ During runtime, you can also set the parameter with the
3051
+ :dbcommand:`setParameter` command:
3052
+
3053
+ .. code-block:: javascript
3054
+
3055
+ db.adminCommand( { setParameter: 1, ShardingTaskExecutorPoolRefreshTimeoutMS: 30000 } )
3056
+
3009
3057
.. parameter:: ShardingTaskExecutorPoolReplicaSetMatching
3010
3058
3011
3059
.. versionadded:: 4.2
0 commit comments