<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 21:18:40 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[CDRIVER-3653] Connections should use server descriptions from handshake, not monitoring</title>
                <link>https://jira.mongodb.org/browse/CDRIVER-3653</link>
                <project id="10030" key="CDRIVER">C Driver</project>
                    <description>&lt;p&gt;When a stream is fetched for an operation, libmongoc fetches the server description from the topology description and uses that metadata for wire version checks, checking for supported compression.&lt;/p&gt;

&lt;p&gt;This is explicitly discouraged by SDAM&apos;s &lt;a href=&quot;https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#warning-about-the-maxwireversion-from-a-monitors-ismaster-response&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;Warning about the maxWireVersion from a monitor&apos;s ismaster response&lt;/a&gt; and may make the driver susceptible to racy comparisons. For example:&lt;/p&gt;

&lt;p&gt;1. Thread 1 runs an insert. This creates a stream, performs a handshake, creates a &lt;br/&gt;
 cluster node, and proceeds to insert.&lt;br/&gt;
2. Later, thread 1 begins another insert operation. It selects the primary, but just before it calls &lt;tt&gt;_mongoc_cluster_stream_for_server&lt;/tt&gt;...&lt;br/&gt;
3. Thread 2 runs an insert, gets a network error, and marks the server as Unknown.&lt;br/&gt;
4. Thread 1 continues, and creates a server stream with an Unknown server description. Any wire version checks it does will check with wire version 0.&lt;/p&gt;

&lt;p&gt;We&apos;ve seen bugs of this type before, example: &lt;a href=&quot;https://jira.mongodb.org/browse/CDRIVER-3404&quot; title=&quot;Assertion hit when handshake runs against unknown server type&quot; class=&quot;issue-link&quot; data-issue-key=&quot;CDRIVER-3404&quot;&gt;&lt;del&gt;CDRIVER-3404&lt;/del&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;It seems like there was at least some intention to fix this at some point. mongoc_cluster_node_t has its own copies of max_wire_version, min_wire_version, max_write_batch_size, max_bson_obj_size, and max_msg_size. But those fields are unused.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1341327">CDRIVER-3653</key>
            <summary>Connections should use server descriptions from handshake, not monitoring</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="13201">Fixed</resolution>
                                        <assignee username="kevin.albertson@mongodb.com">Kevin Albertson</assignee>
                                    <reporter username="kevin.albertson@mongodb.com">Kevin Albertson</reporter>
                        <labels>
                    </labels>
                <created>Wed, 6 May 2020 01:53:53 +0000</created>
                <updated>Sat, 28 Oct 2023 11:28:46 +0000</updated>
                            <resolved>Sun, 18 Jul 2021 23:45:28 +0000</resolved>
                                                    <fixVersion>1.19.0</fixVersion>
                                    <component>libmongoc</component>
                    <component>network</component>
                                        <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="3948678" author="xgen-internal-githook" created="Sun, 18 Jul 2021 23:44:46 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Kevin Albertson&apos;, &apos;email&apos;: &apos;kevin.albertson@mongodb.com&apos;, &apos;username&apos;: &apos;kevinAlbs&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/CDRIVER-3653&quot; title=&quot;Connections should use server descriptions from handshake, not monitoring&quot; class=&quot;issue-link&quot; data-issue-key=&quot;CDRIVER-3653&quot;&gt;&lt;del&gt;CDRIVER-3653&lt;/del&gt;&lt;/a&gt; use handshake metadata for connection checks (#822)&lt;/p&gt;

&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;Update change stream wire version check&lt;/li&gt;
	&lt;li&gt;Update transaction wire version check&lt;/li&gt;
	&lt;li&gt;Update auth commands to use handshake description to construct commands.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-c-driver/commit/0da8f1adb140857691edf2bcd9d4a6d5ca28f9f0&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-c-driver/commit/0da8f1adb140857691edf2bcd9d4a6d5ca28f9f0&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</comment>
                            <comment id="3932058" author="kevin.albertson" created="Wed, 14 Jul 2021 02:01:30 +0000"  >&lt;p&gt;PR: &lt;a href=&quot;https://github.com/mongodb/mongo-c-driver/pull/822&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-c-driver/pull/822&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                        <issuelink>
            <issuekey id="1886484">PHPC-1979</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1835898">PHPC-1926</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                                                <inwardlinks description="is duplicated by">
                                        <issuelink>
            <issuekey id="1079883">CDRIVER-3475</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="1816038">CDRIVER-4077</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1258785">CDRIVER-3563</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="2198868">NODE-4853</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10857" key="com.pyxis.greenhopper.jira:gh-epic-link">
                        <customfieldname>Epic Link</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>CDRIVER-3883</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_21553" key="com.atlassian.jira.plugin.system.customfieldtypes:labels">
                        <customfieldname>Quarter</customfieldname>
                        <customfieldvalues>
                                        <label>FY22Q2</label>
    
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hr6lc7:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>