Skip to content

Commit d537a49

Browse files
committed
JS feedback
1 parent e4c7705 commit d537a49

File tree

2 files changed

+17
-16
lines changed

2 files changed

+17
-16
lines changed

source/connect/connection-options/server-selection.txt

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
.. _csharp-server-selection:
2+
13
==========================
24
Customize Server Selection
35
==========================
@@ -24,7 +26,7 @@ customize this algorithm to choose the server that works best for your applicati
2426

2527
.. important::
2628

27-
Customizing the server-selection algorithm can have unintended consequences,
29+
Customizing the server selection algorithm might have unintended consequences,
2830
such as degraded read or write performance.
2931

3032
Default Algorithm
@@ -33,46 +35,45 @@ Default Algorithm
3335
When the {+driver-short+} executes a read operation, it performs the following steps,
3436
in order, to select a MongoDB deployment:
3537

36-
1. From the list of known servers, the {+driver-short+} selects all servers
37-
that match the active read preference.
38+
1. Selects all servers that match the active read preference from the list of known servers.
3839

39-
#. If at least one readable server exists, the {+driver-short+} calls the user-defined
40+
#. If at least one readable server exists, the driver calls the user-defined
4041
server-selector function and passes in the list from the previous step.
4142

42-
#. The {+driver-short+} applies the ``LocalThreshold`` connection setting to the list of
43+
#. Applies the ``LocalThreshold`` connection setting to the list of
4344
servers returned from the function.
4445

45-
#. The {+driver-short+} selects a server at random from the servers still on the list and
46+
#. Selects a server at random from the servers still on the list and
4647
executes the operation against this server.
4748

4849
When the {+driver-short+} executes a write operation, it begins by selecting all writeable
4950
servers, not just those that match the active read preference. The remaining steps are
5051
identical.
5152

52-
To learn more about the default server-selection algorithm, which the driver follows
53-
when you don't specify any custom server-selection logic, see
53+
To learn more about the default server selection algorithm, which the driver follows
54+
when you don't specify any custom server selection logic, see
5455
:manual:`Server Selection Algorithm </core/read-preference-mechanics/>` in the
55-
MongoDB Server manual.
56+
{+mdb-server+} manual.
5657

5758
.. _csharp-server-selection-algorithm:
5859

5960
Specifying Other Server Selection Algorithms
6061
--------------------------------------------
6162

62-
You can specify different server-selection logic by passing an instance of a server selector
63+
You can specify different server selection logic by passing an instance of a server selector
6364
class to the ``PreServerSelector`` or ``PostServerSelector`` property of the ``ClusterConfigurator``. The
6465
``PreServerSelector`` property specifies a server selector that runs before the
6566
standard server selection logic runs, while the ``PostServerSelector`` property
6667
specifies a server selector that runs after standard server selection logic runs. You can
6768
then pass your ``ClusterConfigurator`` instance to the ``MongoClientSettings`` object when you create a
68-
``MongoClient`` instance to apply your custom server-selection logic.
69+
``MongoClient`` instance to apply your custom server selection logic.
6970

7071
The following table lists the different types of server selectors you can pass to the
7172
``ClusterConfigurator`` property:
7273

7374
.. list-table::
7475
:header-rows: 1
75-
:widths: 30 70
76+
:widths: 40 60
7677

7778
* - Server Selector
7879
- Description
@@ -113,7 +114,7 @@ To learn more about the different server selector classes, see the
113114
Implementing Custom Server Selection Logic
114115
------------------------------------------
115116

116-
You can also implement your own custom server-selection logic by creating a class that
117+
You can implement your own custom server selection logic by creating a class that
117118
inherits from the ``IServerSelector`` interface and overrides the
118119
``SelectServers()`` method. The following example shows a simple custom server
119120
selection class that selects servers with a ``ServerType`` of
@@ -153,7 +154,7 @@ in your connection URI:
153154

154155
* - ``ReadPreference``
155156
- | The client's default read-preference settings. ``MaxStaleness`` represents the
156-
| longest replication lag (in wall-clock time) that a secondary can experience and
157+
| longest replication lag (in real time) that a secondary can experience and
157158
| still be eligible for server selection. Specifying ``-1`` means no maximum.
158159
| See :ref:`read preference <read-preference>` for more information.
159160
|

source/includes/troubleshooting/server-selection-timeout.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ The error message consists of multiple parts:
4747
The following heartbeat exceptions are common:
4848

4949
* ``No connection could be made because the target machine actively
50-
refused it``: The driver cannot see this cluster node. This can be
50+
refused it``: The driver cannot see this cluster node. This might be
5151
because the cluster node has crashed, a firewall is preventing
5252
network traffic from reaching the cluster node or port, or some other
5353
network error is preventing traffic from being successfully routed to
@@ -57,7 +57,7 @@ The error message consists of multiple parts:
5757
network error, misconfigured firewall, or other network issue. To
5858
address this exception, ensure that all cluster nodes are reachable.
5959
This error commonly occurs when the client machine’s IP address is
60-
not configured in the Atlas IPs Access List, which can be found under
60+
not configured in the Atlas IPs Access List, which you can find under
6161
the :guilabel:`Network Access` tab for your Atlas Project.
6262
* ``The remote certificate is invalid according to the validation
6363
procedure``: This error typically indicates a TLS/SSL-related problem

0 commit comments

Comments
 (0)