Skip to content

Commit

Permalink
Deprecate passing WriteConcern and ReadPreference directly to execute…
Browse files Browse the repository at this point in the history
  • Loading branch information
jmikola committed Feb 27, 2025
1 parent d7be221 commit 51ea49d
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<modifier>final</modifier> <modifier>public</modifier> <type>MongoDB\Driver\WriteResult</type><methodname>MongoDB\Driver\Manager::executeBulkWrite</methodname>
<methodparam><type>string</type><parameter>namespace</parameter></methodparam>
<methodparam><type>MongoDB\Driver\BulkWrite</type><parameter>bulk</parameter></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>MongoDB\Driver\WriteConcern</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
</methodsynopsis>
<para>
Executes one or more write operations on the primary server.
Expand Down Expand Up @@ -92,6 +92,13 @@
</row>
</thead>
<tbody>
<row>
<entry>PECL mongodb 1.21.0</entry>
<entry>
Passing a <classname>MongoDB\Driver\WriteConcern</classname> object as
<parameter>options</parameter> is deprecated and will be removed in 2.0.
</entry>
</row>
<row>
<entry>PECL mongodb 1.4.4</entry>
<entry>
Expand Down
9 changes: 8 additions & 1 deletion reference/mongodb/mongodb/driver/manager/executecommand.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<modifier>final</modifier> <modifier>public</modifier> <type>MongoDB\Driver\Cursor</type><methodname>MongoDB\Driver\Manager::executeCommand</methodname>
<methodparam><type>string</type><parameter>db</parameter></methodparam>
<methodparam><type>MongoDB\Driver\Command</type><parameter>command</parameter></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>MongoDB\Driver\ReadPreference</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
</methodsynopsis>
<para>
Selects a server according to the <literal>"readPreference"</literal> option
Expand Down Expand Up @@ -96,6 +96,13 @@
</row>
</thead>
<tbody>
<row>
<entry>PECL mongodb 1.21.0</entry>
<entry>
Passing a <classname>MongoDB\Driver\ReadPreference</classname> object as
<parameter>options</parameter> is deprecated and will be removed in 2.0.
</entry>
</row>
<row>
<entry>PECL mongodb 1.4.4</entry>
<entry>
Expand Down
9 changes: 8 additions & 1 deletion reference/mongodb/mongodb/driver/manager/executequery.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<modifier>final</modifier> <modifier>public</modifier> <type>MongoDB\Driver\Cursor</type><methodname>MongoDB\Driver\Manager::executeQuery</methodname>
<methodparam><type>string</type><parameter>namespace</parameter></methodparam>
<methodparam><type>MongoDB\Driver\Query</type><parameter>query</parameter></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>MongoDB\Driver\ReadPreference</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
</methodsynopsis>
<para>
Selects a server according to the <literal>"readPreference"</literal> option
Expand Down Expand Up @@ -83,6 +83,13 @@
</row>
</thead>
<tbody>
<row>
<entry>PECL mongodb 1.21.0</entry>
<entry>
Passing a <classname>MongoDB\Driver\ReadPreference</classname> object as
<parameter>options</parameter> is deprecated and will be removed in 2.0.
</entry>
</row>
<row>
<entry>PECL mongodb 1.4.0</entry>
<entry>
Expand Down
9 changes: 8 additions & 1 deletion reference/mongodb/mongodb/driver/server/executebulkwrite.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<modifier>final</modifier> <modifier>public</modifier> <type>MongoDB\Driver\WriteResult</type><methodname>MongoDB\Driver\Server::executeBulkWrite</methodname>
<methodparam><type>string</type><parameter>namespace</parameter></methodparam>
<methodparam><type>MongoDB\Driver\BulkWrite</type><parameter>bulk</parameter></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>MongoDB\Driver\WriteConcern</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
</methodsynopsis>
<para>
Executes one or more write operations on this server.
Expand Down Expand Up @@ -92,6 +92,13 @@
</row>
</thead>
<tbody>
<row>
<entry>PECL mongodb 1.21.0</entry>
<entry>
Passing a <classname>MongoDB\Driver\WriteConcern</classname> object as
<parameter>options</parameter> is deprecated and will be removed in 2.0.
</entry>
</row>
<row>
<entry>PECL mongodb 1.4.4</entry>
<entry>
Expand Down
9 changes: 8 additions & 1 deletion reference/mongodb/mongodb/driver/server/executecommand.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<modifier>final</modifier> <modifier>public</modifier> <type>MongoDB\Driver\Cursor</type><methodname>MongoDB\Driver\Server::executeCommand</methodname>
<methodparam><type>string</type><parameter>db</parameter></methodparam>
<methodparam><type>MongoDB\Driver\Command</type><parameter>command</parameter></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>MongoDB\Driver\ReadPreference</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
</methodsynopsis>
<para>
Executes the command on this server.
Expand Down Expand Up @@ -96,6 +96,13 @@
</row>
</thead>
<tbody>
<row>
<entry>PECL mongodb 1.21.0</entry>
<entry>
Passing a <classname>MongoDB\Driver\ReadPreference</classname> object as
<parameter>options</parameter> is deprecated and will be removed in 2.0.
</entry>
</row>
<row>
<entry>PECL mongodb 1.4.4</entry>
<entry>
Expand Down
9 changes: 8 additions & 1 deletion reference/mongodb/mongodb/driver/server/executequery.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<modifier>final</modifier> <modifier>public</modifier> <type>MongoDB\Driver\Cursor</type><methodname>MongoDB\Driver\Server::executeQuery</methodname>
<methodparam><type>string</type><parameter>namespace</parameter></methodparam>
<methodparam><type>MongoDB\Driver\Query</type><parameter>query</parameter></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>MongoDB\Driver\ReadPreference</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
<methodparam choice="opt"><type class="union"><type>array</type><type>null</type></type><parameter>options</parameter><initializer>&null;</initializer></methodparam>
</methodsynopsis>
<para>
Executes the query on this server.
Expand Down Expand Up @@ -83,6 +83,13 @@
</row>
</thead>
<tbody>
<row>
<entry>PECL mongodb 1.21.0</entry>
<entry>
Passing a <classname>MongoDB\Driver\ReadPreference</classname> object as
<parameter>options</parameter> is deprecated and will be removed in 2.0.
</entry>
</row>
<row>
<entry>PECL mongodb 1.4.0</entry>
<entry>
Expand Down

0 comments on commit 51ea49d

Please sign in to comment.