<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 08:24:22 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>[DRIVERS-1954] SDAM should give priority to electionId over setVersion when updating topology</title>
                <link>https://jira.mongodb.org/browse/DRIVERS-1954</link>
                <project id="10980" key="DRIVERS">Drivers</project>
                    <description>&lt;div class=&quot;panel&quot; style=&quot;background-color: #fafbfc;border-width: 1px;&quot;&gt;&lt;div class=&quot;panelContent&quot; style=&quot;background-color: #fafbfc;&quot;&gt;
&lt;h3&gt;&lt;a name=&quot;inprogress...&quot;&gt;&lt;/a&gt;&lt;b&gt;in progress...&lt;/b&gt;&lt;/h3&gt;
&lt;h3&gt;&lt;a name=&quot;Summary&quot;&gt;&lt;/a&gt;&lt;b&gt;Summary&lt;/b&gt;&lt;/h3&gt;

&lt;p&gt;SDAM spec specifies that RSM is using the { setVersion, electionId } in that order to detect stale primaries. The motivation for this is that if the protocol version changes (like it happened in 3.2.0) the&#160;electionId might not be directly comparable but the setVersion is guaranteed to increment. Details: &lt;a href=&quot;https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#using-setversion-and-electionid-to-detect-stale-primaries&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#using-setversion-and-electionid-to-detect-stale-primaries&lt;/a&gt;&#160;&lt;/p&gt;

&lt;p&gt;The problem with that if the failover happens before the former primary was able to get the consensus on setVersion increment the new primary will communicate a decremented setVersion while electionId incremented. The existing SDAM treats this as stale primary, which leads to full cluster outage and requires manual intervention. Details in&#160;&lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-59409&quot; title=&quot;Race between reconfig replication and stepup can cause RSM to be stuck in reporting ReplicaSetNoPrimary&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-59409&quot;&gt;&lt;del&gt;SERVER-59409&lt;/del&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Drawback: if we need to make non-compatible protocol versions in future, which will make the electionId non monotonical, if will require an additional contingency plan.&lt;/p&gt;

&lt;p&gt;Tests: the SDAM updated in head to match new behavior: &lt;a href=&quot;https://github.com/mongodb/mongo/tree/master/src/mongo/client/sdam/json_tests/sdam_tests&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo/tree/master/src/mongo/client/sdam/json_tests/sdam_tests&lt;/a&gt;&#160;&lt;/p&gt;
&lt;h3&gt;&lt;a name=&quot;Motivation&quot;&gt;&lt;/a&gt;&lt;b&gt;Motivation&lt;/b&gt;&lt;/h3&gt;
&lt;h4&gt;&lt;a name=&quot;Whoistheaffectedenduser%3F&quot;&gt;&lt;/a&gt;Who is the affected end user?&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;Who are the stakeholders? Divers team, server teams.&lt;/em&gt;&lt;/p&gt;
&lt;h4&gt;&lt;a name=&quot;Howdoesthisaffecttheenduser%3F&quot;&gt;&lt;/a&gt;How does this affect the end user?&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;Full cluster outage is possible.&lt;/em&gt;&lt;/p&gt;
&lt;h4&gt;&lt;a name=&quot;Howlikelyisitthatthisproblemorusecasewilloccur%3F&quot;&gt;&lt;/a&gt;How likely is it that this problem or use case will occur?&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;It happens in tests all the time.&lt;/em&gt;&lt;/p&gt;
&lt;h4&gt;&lt;a name=&quot;Iftheproblemdoesoccur%2Cwhataretheconsequencesandhowseverearethey%3F&quot;&gt;&lt;/a&gt;If the problem does occur, what are the consequences and how severe are they?&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;Outage.&lt;/em&gt;&lt;/p&gt;
&lt;h4&gt;&lt;a name=&quot;Isthisissueurgent%3F&quot;&gt;&lt;/a&gt;Is this issue urgent?&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;Not urgent but high priority.&lt;/em&gt;&lt;/p&gt;
&lt;h4&gt;&lt;a name=&quot;Isthisticketrequiredbyadownstreamteam%3F&quot;&gt;&lt;/a&gt;Is this ticket required by a downstream team?&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;TBD, might be just normal upgrade path.&lt;/em&gt;&lt;/p&gt;
&lt;h4&gt;&lt;a name=&quot;Isthisticketonlyfortests%3F&quot;&gt;&lt;/a&gt;Is this ticket only for tests?&lt;/h4&gt;

&lt;p&gt;&lt;em&gt;No.&lt;/em&gt;&lt;/p&gt;
&lt;/div&gt;&lt;/div&gt;</description>
                <environment></environment>
        <key id="1898743">DRIVERS-1954</key>
            <summary>SDAM should give priority to electionId over setVersion when updating topology</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="3">Duplicate</resolution>
                                        <assignee username="neal.beeken@mongodb.com">Neal Beeken</assignee>
                                    <reporter username="andrew.shuvalov@mongodb.com">Andrew Shuvalov</reporter>
                        <labels>
                    </labels>
                <created>Thu, 14 Oct 2021 19:54:52 +0000</created>
                <updated>Fri, 7 Oct 2022 08:57:33 +0000</updated>
                            <resolved>Wed, 5 Oct 2022 14:14:36 +0000</resolved>
                                                        <component>SDAM</component>
                                        <votes>0</votes>
                                    <watches>10</watches>
                                                                                                                <comments>
                            <comment id="4823570" author="xgen-internal-githook" created="Tue, 13 Sep 2022 18:50:01 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Shane Harvey&apos;, &apos;email&apos;: &apos;shnhrv@gmail.com&apos;, &apos;username&apos;: &apos;ShaneHarvey&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/DRIVERS-1954&quot; title=&quot;SDAM should give priority to electionId over setVersion when updating topology&quot; class=&quot;issue-link&quot; data-issue-key=&quot;DRIVERS-1954&quot;&gt;&lt;del&gt;DRIVERS-1954&lt;/del&gt;&lt;/a&gt; Fix hello-&amp;gt;helloOk typo + regenerate all json tests (#1306)&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/specifications/commit/133bf0c47dd97f4ea8a748d62482b7371bcb3dc8&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/commit/133bf0c47dd97f4ea8a748d62482b7371bcb3dc8&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4450737" author="xgen-internal-githook" created="Fri, 1 Apr 2022 15:56:01 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Boris&apos;, &apos;email&apos;: &apos;boris.dogadov@mongodb.com&apos;, &apos;username&apos;: &apos;BorisDog&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/DRIVERS-1954&quot; title=&quot;SDAM should give priority to electionId over setVersion when updating topology&quot; class=&quot;issue-link&quot; data-issue-key=&quot;DRIVERS-1954&quot;&gt;&lt;del&gt;DRIVERS-1954&lt;/del&gt;&lt;/a&gt;: Minor fixes&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/specifications/commit/316c6501ea5870b54e2f932e65d2603cfe44e454&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/commit/316c6501ea5870b54e2f932e65d2603cfe44e454&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4396229" author="xgen-internal-githook" created="Mon, 7 Mar 2022 20:16:01 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Neal Beeken&apos;, &apos;email&apos;: &apos;neal.beeken@mongodb.com&apos;, &apos;username&apos;: &apos;nbbeeken&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/DRIVERS-1954&quot; title=&quot;SDAM should give priority to electionId over setVersion when updating topology&quot; class=&quot;issue-link&quot; data-issue-key=&quot;DRIVERS-1954&quot;&gt;&lt;del&gt;DRIVERS-1954&lt;/del&gt;&lt;/a&gt;: SDAM should give priority to electionId over setVersion when updating topology (#1122)&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/specifications/commit/5bd06a81d97850a1365d73f08bbb7dea562e72b9&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/commit/5bd06a81d97850a1365d73f08bbb7dea562e72b9&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4340831" author="shane.harvey" created="Mon, 7 Feb 2022 22:24:11 +0000"  >&lt;p&gt;PR: &lt;a href=&quot;https://github.com/mongodb/specifications/pull/1122&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/specifications/pull/1122&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                            <outwardlinks description="depends on">
                                        <issuelink>
            <issuekey id="1853564">SERVER-59409</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1979755">DRIVERS-2196</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                            <outwardlinks description="duplicates">
                                        <issuelink>
            <issuekey id="2111839">DRIVERS-2412</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10620">
                    <name>Issue split</name>
                                            <outwardlinks description="split to">
                                        <issuelink>
            <issuekey id="1908851">CDRIVER-4203</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908853">CSHARP-3934</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908852">CXX-2404</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908854">GODRIVER-2207</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908859">MOTOR-847</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908856">NODE-3712</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908857">PHPC-2068</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908858">PYTHON-2970</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908860">RUBY-2829</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908861">RUST-1081</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="1908855">JAVA-4375</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="2111839">DRIVERS-2412</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_10257" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Documentation Changes</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="11861"><![CDATA[Not Needed]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_17052" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Downstream Changes Summary</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>&lt;ul&gt;
	&lt;li&gt;Sync spec changes in &lt;a href=&quot;https://github.com/mongodb/specifications/commit/5bd06a81d97850a1365d73f08bbb7dea562e72b9&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;5bd06a8&lt;/a&gt;&lt;/li&gt;
	&lt;li&gt;Confirm tests fail with current &lt;tt&gt;updateRSFromPrimary&lt;/tt&gt; implementation&lt;/li&gt;
	&lt;li&gt;Update &lt;tt&gt;updateRSFromPrimary&lt;/tt&gt; to
	&lt;ul&gt;
		&lt;li&gt;Prioritize electionId before setVersion&lt;/li&gt;
		&lt;li&gt;Handle nullish values for both setVersion and electionId&lt;/li&gt;
		&lt;li&gt;always set maxElectionId and maxSetVersion together (they&apos;re a tuple value)&lt;/li&gt;
	&lt;/ul&gt;
	&lt;/li&gt;
	&lt;li&gt;Confirm tests pass with changes&lt;/li&gt;
	&lt;li&gt;Update April 1 2022: Minor fixes were made, notably the spec files were using hello, where it should have been helloOk, see commit: &lt;a href=&quot;https://github.com/mongodb/specifications/commit/316c6501ea5870b54e2f932e65d2603cfe44e454&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;316c650&lt;/a&gt; to pull in the latest.&lt;/li&gt;
&lt;/ul&gt;
</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10951" key="com.atlassian.jira.plugin.system.customfieldtypes:radiobuttons">
                        <customfieldname>Driver Changes</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10748"><![CDATA[Needed]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_23952" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Driver Compliance</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[<style type='text/css'>
         #scriptField, #scriptField *{
                border: 1px solid black;
            }

            #scriptField{
                border-collapse: collapse;
            }

            #scriptField td {
                text-align: center; /* Center-align text in table cells */
            }

            #scriptField td.key {
                text-align: left; /* Left-align text in the Key column */
            }

            #scriptField a {
                text-decoration: none; /* Remove underlines from links */
                border: none; /* Remove border from links */
            }
            
            /* Add green background color to cells with FixVersion */
            #scriptField td.hasFixVersion {
                background-color: #00FF00; /* Green color code */
            }

            /* Center-align the first row headers */
            #scriptField th {
                text-align: center;
            }
        </style>
<table id='scriptField'>
  <tr>
    <th>Key</th>
    <th>Status/Resolution</th>
    <th>FixVersion</th>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/CDRIVER-4203'>CDRIVER-4203</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/CXX-2404'>CXX-2404</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/CSHARP-3934'>CSHARP-3934</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/GODRIVER-2207'>GODRIVER-2207</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/JAVA-4375'>JAVA-4375</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/NODE-3712'>NODE-3712</a>
    </td>
    <td>Duplicate</td>
    <td class='hasFixVersion'>4.11.0</td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/PHPC-2068'>PHPC-2068</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/PYTHON-2970'>PYTHON-2970</a>
    </td>
    <td>Fixed</td>
    <td class='hasFixVersion'>4.3</td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/MOTOR-847'>MOTOR-847</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/RUBY-2829'>RUBY-2829</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/RUST-1081'>RUST-1081</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
  <tr>
    <td class='key'>
      <a href='https://jira.mongodb.org/browse/SWIFT-1400'>SWIFT-1400</a>
    </td>
    <td>Duplicate</td>
    <td class=''></td>
  </tr>
</table>]]></customfieldvalue>


                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_21553" key="com.atlassian.jira.plugin.system.customfieldtypes:labels">
                        <customfieldname>Quarter</customfieldname>
                        <customfieldvalues>
                                        <label>FY23Q3</label>
    
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i0khsc:</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>
                                                                                                                        <customfield id="customfield_11150" key="com.atlassian.jira.plugin.system.customfieldtypes:multiselect">
                        <customfieldname>SERVER fixVersion</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="21982"><![CDATA[5.2 Desired]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                    <customfield id="customfield_22279" key="com.atlassian.jira.plugin.system.customfieldtypes:labels">
                        <customfieldname>Server Compat</customfieldname>
                        <customfieldvalues>
                                        <label>4.4</label>
            <label>5.0</label>
            <label>5.1</label>
            <label>5.3</label>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_21457" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Upstream Changes Summary</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>&lt;p&gt;Filed &lt;a href=&quot;https://jira.mongodb.org/browse/DRIVERS-1954&quot; title=&quot;SDAM should give priority to electionId over setVersion when updating topology&quot; class=&quot;issue-link&quot; data-issue-key=&quot;DRIVERS-1954&quot;&gt;&lt;del&gt;DRIVERS-1954&lt;/del&gt;&lt;/a&gt; to track drivers change&lt;/p&gt;</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>