[prev in list] [next in list] [prev in thread] [next in thread]
List: php-doc-cvs
Subject: [DOC-CVS] [doc-en] master: executeCommand() does not inherit readPreference from URI
From: Jeremy Mikola <noreply () php ! net>
Date: 2023-09-28 17:53:55
Message-ID: ITSLjklAFhgDH5LxNkEWPu2yNbXbyvY4PgazjLFpkc () main ! php ! net
[Download RAW message or body]
Author: Jeremy Mikola (jmikola)
Date: 2023-09-28T13:56:03-04:00
Commit: https://github.com/php/doc-en/commit/43e3a6ce9d6a407540652fa4f0d04f5c53f1a3ff
Raw diff: https://github.com/php/doc-en/commit/43e3a6ce9d6a407540652fa4f0d04f5c53f1a3ff.diff
executeCommand() does not inherit readPreference from URI
https://jira.mongodb.org/browse/PHPC-2303
Changed paths:
M reference/mongodb/mongodb/driver/manager/executecommand.xml
Diff:
diff --git a/reference/mongodb/mongodb/driver/manager/executecommand.xml \
b/reference/mongodb/mongodb/driver/manager/executecommand.xml index \
2682dca79dd..975e1fb9759 100644
--- a/reference/mongodb/mongodb/driver/manager/executecommand.xml
+++ b/reference/mongodb/mongodb/driver/manager/executecommand.xml
@@ -17,9 +17,8 @@
</methodsynopsis>
<para>
Selects a server according to the <literal>"readPreference"</literal> option
- and executes the command on that server. By default, the read preference from
- the <link linkend="mongodb-driver-manager.construct-uri">MongoDB Connection
- URI</link> will be used.
+ and executes the command on that server. By default, the primary server will
+ be selected.
</para>
<para>
This method applies no special logic to the command. Although this method
@@ -254,6 +253,14 @@ var_dump($cursor->toArray()[0]);
is done by the driver.
</simpara>
</note>
+ <note>
+ <simpara>
+ This method does not default to using the read preference from the
+ <link linkend="mongodb-driver-manager.construct-uri">MongoDB Connection
+ URI</link>. Applications in need of that behavior should consider using
+ <function>MongoDB\Driver\Manager::executeReadCommand</function>.
+ </simpara>
+ </note>
</refsect1>
<refsect1 role="seealso">
--
PHP Documentation Commits Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic